Koozali.org: home of the SME Server

Mapping Network Drive Issue

Offline scottieg99

  • *
  • 16
  • +0/-0
Mapping Network Drive Issue
« on: April 15, 2013, 02:42:59 AM »
Hi Guys.

I have recently setup a SMEServer 8. I have applied the reg patch and got my windows 7 PC attached to the domain. I have created some groups and also installed the logon script manager. Heres a portion of the code:

#ifg admins
REM Map iBay's for admin group:
NET USE P: \\sstone\accounting
NET USE O: \\sstone\archive
NET USE F: \\sstone\columbarium
NET USE G: \\sstone\general
NET USE I: \\sstone\laser
NET USE J: \\sstone\monumental
NET USE K: \\sstone\production
NET USE R: \\sstone\resources
NET USE L: \\sstone\scans
NET USE M: \\sstone\software
#endif

#ifg artists
REM Map iBay's for artists group:
NET USE O: \\sstone\archive
NET USE F: \\sstone\columbarium
NET USE G: \\sstone\general
NET USE I: \\sstone\laser
NET USE K: \\sstone\production
NET USE R: \\sstone\resources
NET USE L: \\sstone\scans
NET USE M: \\sstone\software
#endif

#ifg powerusers
REM Map iBay's for powerusers group:
NET USE O: \\sstone\archive
NET USE F: \\sstone\columbarium
NET USE G: \\sstone\general
NET USE I: \\sstone\laser
NET USE J: \\sstone\monumental
NET USE K: \\sstone\production
NET USE R: \\sstone\resources
NET USE L: \\sstone\scans
NET USE M: \\sstone\software
#endif

So if "UserA" that is part of the Admin group logs on it should map all of the drives, however it is not. I have to manually mount the home drive for the user, then in that home drive is as netlogon.bat file which I then double click and it mounts the other drives for me. This is a fine solution however I am worried that the drives might not persist after reboots or what not.

Is there something I am doing wrong? I want to make it pretty simple for the users so that when I create a new user - based on the group their in it will map the appropriate drives.

Thanks

Offline janet

  • *****
  • 4,812
  • +0/-0
Re: Mapping Network Drive Issue
« Reply #1 on: April 15, 2013, 04:51:49 AM »
scottieg99

add in
NET USE H: /home

after the above you may also want to add
NET USE /delete Z: /yes
Please search before asking, an answer may already exist.
The Search & other links to useful information are at top of Forum.

Offline scottieg99

  • *
  • 16
  • +0/-0
Re: Mapping Network Drive Issue
« Reply #2 on: April 15, 2013, 06:39:53 AM »
Just tried what you suggested and it doesn't appear to be working.
None of the drives are mapping - not even the H:\ drive which should be mapping by default.
Im wondering if something is causing this to mess up?

Offline brianr

  • *
  • 990
  • +2/-0
Re: Mapping Network Drive Issue
« Reply #3 on: April 15, 2013, 10:41:34 AM »
Are there any existing mapping (left over from manually setup ones)?  If so you need to delete (disconnect) them otherwise I don't think NET USE will overwrite.

I use this technique all the time, and it does work.
Brian j Read
(retired, for a second time, still got 2 installations though)
The instrument I am playing is my favourite Melodeon.
.........

Offline scottieg99

  • *
  • 16
  • +0/-0
Re: Mapping Network Drive Issue
« Reply #4 on: April 15, 2013, 04:07:28 PM »
There were some manual ones I setup for testing but I did disconnect them. Also for testing purposes I created a brand new user in the same group I am testing and no drives are mapping to this brand new user

Offline brianr

  • *
  • 990
  • +2/-0
Re: Mapping Network Drive Issue
« Reply #5 on: April 15, 2013, 05:27:18 PM »
Have you tried manually applying the NET USE commands from the command line when logged in as the user, to see if they work then?
Brian j Read
(retired, for a second time, still got 2 installations though)
The instrument I am playing is my favourite Melodeon.
.........

Offline scottieg99

  • *
  • 16
  • +0/-0
Re: Mapping Network Drive Issue
« Reply #6 on: April 15, 2013, 06:19:46 PM »
Yes that works fine - weirdly enough. However I want to make it as easy as possible for the users and have a login script to manually map the drives. I could technically put a batch file in the startup folder, but it wouldn't help associate the groupings that the user is in and map the drives accordingly. Is there another way?

Offline brianr

  • *
  • 990
  • +2/-0
Re: Mapping Network Drive Issue
« Reply #7 on: April 15, 2013, 06:27:02 PM »
Are you sure it is not your "if" commands that are messing things up then?  Can't say I really understand what it is you are doing there.  Where do those groupnames come from?
Brian j Read
(retired, for a second time, still got 2 installations though)
The instrument I am playing is my favourite Melodeon.
.........

Offline scottieg99

  • *
  • 16
  • +0/-0
Re: Mapping Network Drive Issue
« Reply #8 on: April 15, 2013, 06:35:56 PM »
Let me explain:

I downloaded a "plugin" i guess you could call that essentially adds a box that allows you to apply login scripts for any and all users. They give you a template that you can follow and has stuff like #ifg (if group) #ifu (if user) etc that basically allow you to specifiy different mappings based on the group people are in.

So I have a login script that goes #ifg admins net use P: \\server\accounting
#endif

so that only if the user is in the admins group it will map the accounting drive. It looked pretty good but I have yet to set it up and I too am wondering if its becasue the command #ifg is not recognized.

If that is the case and its not recognized how do you currently map different network drives for different users based on groups?

Offline janet

  • *****
  • 4,812
  • +0/-0
Re: Mapping Network Drive Issue
« Reply #9 on: April 15, 2013, 06:52:47 PM »
scottieg99

Quote
I downloaded a "plugin"

Is it this ?
http://wiki.contribs.org/Smeserver-tw-logonscript

I am using the earlier smeserver-loginscript contrib on sme7.6 & it works OK with Win 2K, XP & Vista.

I wonder if your problem is Win7 related, or a setting in Win7.
Can you try logging in with a XP or Vista PC.
Please search before asking, an answer may already exist.
The Search & other links to useful information are at top of Forum.

Offline brianr

  • *
  • 990
  • +2/-0
Re: Mapping Network Drive Issue
« Reply #10 on: April 15, 2013, 06:53:53 PM »
If that is the case and its not recognized how do you currently map different network drives for different users based on groups?

I don't - have never used that facility.

Sounds as if the contrib is not working the way you expect!
Brian j Read
(retired, for a second time, still got 2 installations though)
The instrument I am playing is my favourite Melodeon.
.........

Offline idp_qbn

  • *****
  • 347
  • +0/-0
Re: Mapping Network Drive Issue
« Reply #11 on: April 16, 2013, 09:05:34 AM »
If your netlogon.bat tries to map the drives every time they logon, then you should release the drive when they logoff.

eg
NET USE P: \\sstone\accounting  /persistent:no

The /persistent:no means the drive is released (ie unmapped or disconnected) when the user logs off.

Hope you get it working.
Cheers
Ian

___________________
Sydney, NSW, Australia

Offline scottieg99

  • *
  • 16
  • +0/-0
Re: Mapping Network Drive Issue
« Reply #12 on: April 17, 2013, 04:01:16 AM »
ok so I just attached a windows xp pro bot to the domain and logged in with the same user and the drives mapped! Could this be a windows 7 thing?

Offline janet

  • *****
  • 4,812
  • +0/-0
Re: Mapping Network Drive Issue
« Reply #13 on: April 17, 2013, 05:16:30 AM »
scottieg99

[quoter]Could this be a windows 7 thing?
[/quote]

Possibly so.
Do some googling, as I do not have specific experience
Perhaps your Win7 is configured incorrectly.
Do you have other Win 7 machines logging in OK & mapping drives ?
Have you successfully used Windows 7 in the same way before ?

Refer to a bug report in bugzilla about Windows 8 {yes I mean Win 8} joining sme server domains. There was mention of registry settings applicable to both Windows 7 & 8 workstations. I do not know if those may be applicable to your situation.
Please search before asking, an answer may already exist.
The Search & other links to useful information are at top of Forum.

Offline scottieg99

  • *
  • 16
  • +0/-0
Re: Mapping Network Drive Issue
« Reply #14 on: April 17, 2013, 05:25:29 AM »
Worst thing is this is a fresh Windows 7 pro Iso on a VM that I just loaded up. Could it have anything to do with not being activated or some sort of trust relationship by default enabled in Windows 7?

Offline janet

  • *****
  • 4,812
  • +0/-0
Re: Mapping Network Drive Issue
« Reply #15 on: April 17, 2013, 05:35:33 AM »
scottieg99

I am purely guessing, or giving my reasoned "hunch'.
More likely it is to do with your VM configuration, as many unusual issues seem to be related to "incorrect" VM setup, possibly network card related.

You could try sme7 on a real box & see if it works OK, as far as I know sme 7 does work OK. I'll have to test my copy, but that is on a standalone machine which I have not yet connected to a sme domain.

I'm sure someone else can confirm & comment.
Please search before asking, an answer may already exist.
The Search & other links to useful information are at top of Forum.

Offline scottieg99

  • *
  • 16
  • +0/-0
Re: Mapping Network Drive Issue
« Reply #16 on: April 17, 2013, 05:37:20 AM »
My SME8 server is on a physical box, but my Win7 client is VM. I have it bridged to my network connection and the windows 7 box does not pick up the drives however the XP does.

Offline scottieg99

  • *
  • 16
  • +0/-0
Re: Mapping Network Drive Issue
« Reply #17 on: April 17, 2013, 06:24:35 AM »
One thing I wanted to add was that the logon script I tried to run was:

http://www.theforcefield.net/forums/index.php?topic=2416.0

because this one was not working:

http://wiki.contribs.org/Smeserver-tw-logonscript

Could that have anything to do with it? When I do a

yum --enablerepo=smecontribs install smeserver-tw-logonscript
signal-event workgroup-update

nothing works so I am wondering if I need to do a:

wget smeserver-tw-logonscript-1.3-15.el4.sme.noarch then do a yum install. Sorry I am not too familar with Linux

--------------------

Might I add: I just spun up a new SMESERVER 8 and tested the whole thing again with the logon script and its not mapping the home drive or the accounting drive. I think the issue has to do with this login script manager and maybe its an older version. Can anyone assist in getting a newer version working? Am I doing the command wrong?
« Last Edit: April 17, 2013, 06:28:34 AM by scottieg99 »

Offline TerryF

  • grumpy old man
  • *
  • 1,847
  • +6/-0
Re: Mapping Network Drive Issue
« Reply #18 on: April 17, 2013, 09:34:03 AM »
Well worth a read HERE
--
qui scribit bis legit

Offline brianr

  • *
  • 990
  • +2/-0
Re: Mapping Network Drive Issue
« Reply #19 on: April 17, 2013, 10:49:45 AM »
My SME8 server is on a physical box, but my Win7 client is VM. I have it bridged to my network connection and the windows 7 box does not pick up the drives however the XP does.

Are you sure your VM Network connection is "bridged" not "NATed", if the latter, then the WIn7 will get an Ip address not on the same subnet as the SMEServer.

Check the Ip address of the Win7 VM (ipconfig at command level).
Brian j Read
(retired, for a second time, still got 2 installations though)
The instrument I am playing is my favourite Melodeon.
.........

Offline scottieg99

  • *
  • 16
  • +0/-0
Re: Mapping Network Drive Issue
« Reply #20 on: April 18, 2013, 02:32:29 AM »
Just verified:

Windows 7 - Bridged
IP is on same subnet
Windows XP - Bridged
IP is on same subnet

XP works
Windows 7 isnt (Home drive nor accounting drive)

Offline brianr

  • *
  • 990
  • +2/-0
Re: Mapping Network Drive Issue
« Reply #21 on: April 18, 2013, 11:21:19 AM »
Just verified:

Windows 7 - Bridged
IP is on same subnet
Windows XP - Bridged
IP is on same subnet

XP works
Windows 7 isnt (Home drive nor accounting drive)

Well, I'm out of ideas, except to say that it looks like a Win7 problem (all my systems are still on XP).  Perhaps the script is run too early in the login procedure and the network is not properly established at that point.
Brian j Read
(retired, for a second time, still got 2 installations though)
The instrument I am playing is my favourite Melodeon.
.........

Offline TerryF

  • grumpy old man
  • *
  • 1,847
  • +6/-0
Re: Mapping Network Drive Issue
« Reply #22 on: April 18, 2013, 01:45:40 PM »
Did you try the Windows 7 registry tweak on the Windows 8 system?

See Here
--
qui scribit bis legit

Offline scottieg99

  • *
  • 16
  • +0/-0
Re: Mapping Network Drive Issue
« Reply #23 on: April 18, 2013, 03:31:25 PM »
Actually that registry tweak is a mandatory addition should you want a windows 7 client to connect to the domain. Yes I did apply that in the beginning as well I was successfully able to attach to the domain.

At this point I am thinking about starting fresh and mapping all drives for all users. Then based on group access only the appropriate users will be able to access some drives. I realize its not the best solution but it will have to do. My go live is Monday!

Thanks for all your help.