Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations John Tel on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Mapping Drives

Status
Not open for further replies.

dparrott

MIS
Jul 26, 2004
201
US
Hey all,

I am a network admin for a medium sized company using AD in server 2003 Std. I am also free-lancing for a small company using SBS 2003. The small company has 4 drives being mapped somehow. I have checked the user's properties and there is a batch file that runs a program in the location \\server\clients\setup\setup.exe. I have checked the Group Policy and don't see an Administrative Template allowing for the mapping of drives. I also checked the Startup and Logon areas of the Group Policy to see if there was some other script running. I could not find any evidence of anything else.

The issue is that I created a new user, and they didn't get the drives mapped. Are there any other ways to map a drive in SBS 2003?

I checked the local machine, and did not find anything there (no script in the startup folder) that leads me to believe the drives are mapped by the local machine.

I currently have solved the issue by writing a batch file and placed it in the start up folder to run and map the drive. However, I obviously need to find the drive mapping so that I can fix the current issue and change the settings. The owner wants to change the way they store files (which is a good thing, they don't really have a system right now), and I will have to modify the mapping for that.

Thanks in advance for all the help.

Danny
 
It could be that the drives were mapped manually for each user when they were set up, and are now persistent. That's actually how I set up most of my smaller shops. There are usually a few things to do with a profile anyway, and it's easy to manually map a few drives.

To determine whether that's the case, disconnect the mapped drives on another client and then log the client off and on again. If the drives don't remap, you know that it was set up manually.

Also, to sort through the Group Policy stuff, did you use the Group Policy Results tool to see exactly what GP's handing out?


ShackDaddy
Shackelford Consulting
 
The only reason that caused me to think the drives were not manually mapped is that the user can log into any computer on the domain and the same drives are mapped. Would the drives follow the user like this mapped manually?

 
Checked the logon script

the entire contents, as mentioned above are
Code:
\\server\clients\setup\setup.exe
the server name is ommited for security, but not the share name. No drives are mapped using CLI commands in that. The setup.exe may map drives, but, if so, I have no way of knowing.

I know how to map drives using dos commands (and in fact have done so at the company I work for extensively), but I am trying to figure out how these are mapped in the SBS environment. I haven't been back out since I posted this, so I haven't had a chance to disconnect a drive and log back in to see if they are manual.

Can a manual drive mapping follow a user from computer to computer?

Thanks for the help.
 
Yes I did, and I forgot to mention it. That is where the script being run in the users' properties is located. That is the script that I quoted above.
 
What about other ways to map drives? I know you can put a adminstrative template into group policies that maps the drive without running a script. Are there any other ways without using a script?

Thanks for your help,

Danny
 
Actually, I would be surprised if the SBS_LOGIN_SCRIPT.bat contained the line:

Code:
\\server\clients\setup\setup.exe

It should be:

Code:
\\server\clients\setup\setup.exe /s server

I don't recommend that you use a complicated VB logon script on an SBS, since it's quite easy to use the example I linked above. This is because the setup.exe MUST run in order to ensure that client workstations get the any updated settings or configurations from the server.

On SBS there are default network shares which would follow each user wherever they log in... but those aren't mapped, they are just UNC shares which are linked automatically in My Network Places as %username%.lnk.

There also various tricks to remap a drive within a program shortcut (demonstrated here:




Jeffrey B. Kane
TechSoEasy
 
I don't recommend that you use a complicated VB logon script on an SBS

I have to respectfully disagree. VBScript is a very powerful tool that will allow your logon to take on action not possible in the manner you are describing.

My login script FAQ faq329-5798 features a login script I initially developed for SBS customers I was supporting. It is very happily used by hundreds of companies world wide that I am aware of in mixed environments ranging from SBS, Windows 2000-2003.

VBScript is only complicated if you don't understand it and the options available to you are numerous.

I hope you find this post helpful.

Regards,

Mark

Check out my scripting solutions at
 
markdmac said:
VBScript is only complicated if you don't understand it

Which is why I generally recommend against it. Especially if the numerous options aren't necessary.

You happen to be very comfortable with VB Script... most folks aren't.



Jeffrey B. Kane
TechSoEasy
 
TechSoEasy,

you are correct, the /s server is in the sbs_login_script.bat file. My mistake. I know several ways to do the mapping, and had not planned on using VB when simple batch files do the trick in one line for each drive. Since nothing else needs or is wanted to be done on the logon, VBscript is way too much.

But back to the problem posted (restated: What are the different ways that drives can be mapped in SBS?) The default network shares you are talking about you say are not mapped, meaning they don't have a drive letter? Just want to make sure I understand what you are saying, so please no one take this as evidence I am an idiot. As I mentioned, I run a medium sized network. However, because of that, we don't have oodles of money for things like exchange or huge file servers, and cannot use some of the more advanced products that SBS has.

I have looked through ALL the GPO's and none are running any logon/logoff or startup/shutdown scripts. The drives are not mapped manually (When I deleted and logged off and back on, I still had the drive mapped). There are no administrative templates added that allow for mapping drives in any of the GPO's (once again, I looked at ALL of them). Does anyone know any other way that the drives could be mapped?
 
I wouldn't judge anything you've said so far to think you're an idiot... especially since you just confirmed my supposition about the VB Script issue. :)

What I meant by the fact that they aren't mapped is exactly that they don't have a drive letter. If you don't see a link in My Network Places though, then I'd suspect that the workstations were never joined to the domain properly by using (this is exclusive to SBS networks).

If that wasn't done, then about 80% of the SBS features are not working properly. It should be fixed by following these steps:

At the client machine:
1. Log in with THAT machine's LOCAL administrator account.
2. Unjoin the domain into a WORKGROUP
3. Change the name of the computer (this is not an option, you must use a name that is unique and hasn't been used before on your SBS)
4. Delete or rename the following directory C:\Program Files\Microsoft Windows Small Business Server\Clients if it exists
5. Make sure that the network settings are configured to get an IP address automatically (DHCP enabled)
6. Reboot

Then on the server, from the Server Management Console:
1. Remove the client computers if it still shows in the Client Computer screen on the Server Management Console
2. Add the client with it's NEW name using the Add Computer wizard

Then, go back to the client machine, log back in with the local Administrator account and join the domain by opening Internet Explorer and navigating to
Rather than looking through the GPO's, open a command prompt on a workstation change to the C:\ directory and run this:

Code:
GPRESULT /Z >gpresult.txt

This will create a verbose output text file that will show you what GP's are being applied.

The other way that drives would be mapped would be with a NET USE command that's persistent. Which is the same as just mapping them manually.

So are you saying that these are being mapped dynamically? ie, differently for different users?




Jeffrey B. Kane
TechSoEasy
 
TechSoEasy,

I have already looked through all the GPO's (there were only 8 or 9 of them) because I didn't have physical access to the machines at the time (and there were RPC errors trying to run the Group policy results wizard on other computers), only remote desktop to the server. That issue has since been fixed. And yes, the drives are being mapped differently for different users. User A has F,G,K, and Q. User B has F,G, and K, and new users have none.

I don't know if adding to the domain correctly is the issue (which is something I had absolutely no clue about, by the way. Thanks for the tip about that) because the issue is computer independent. What I mean by that is User A can log onto any of the computer and get all four drives, and a new user can log onto any of the computers and get no drives. I cannot look for the links in the network places right, but I am going back on site tonight and will look at it then.

Thanks for the help,

Danny
 
TechSoEasy said:
Just FYI, the SBS Development Team considers drive mapping to be "old school" and recommends that common files be stored in SharePoint.

TechSoEasy,

Can you point me towards more information on this procedure?

Thanks

Tony
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top