+ Post New Thread
Results 1 to 4 of 4
Windows Server 2008 R2 Thread, Mapping Drives - Script ? in Technical; I am trying to map a drive - We have a share on a Samba server (CentOS 5) I have ...
  1. #1
    cpjitservices's Avatar
    Join Date
    Jul 2010
    Location
    Hessle
    Posts
    2,419
    Thank Post
    507
    Thanked 282 Times in 258 Posts
    Rep Power
    81

    Mapping Drives - Script ?

    I am trying to map a drive - We have a share on a Samba server (CentOS 5) I have tried mapping it through GP Preferences but it doesn't show the drive although I have not selected "Hide this drive". The users have separate logins for the Samba share for example my Windows Domain Username might be "joebloggs" but on samba it might be "jb". What I'm after is a script or similar that will map to the drive but map it so that the user double clicks it and can then "enter the correct credentials" but I cant seem to map it unless I put in the credentials first.

    Through CMD I can map to it but only after I have specified the Login credentials for the share, but I don't want that I want the user to input it.


    I did make a script a while ago and everybody complained that the black box keeps asking for a password.... I got the drives mapped through a batch file but it asked for the password in a CMD window first, once the password was entered and the user pressed enter then the drive was mapped.

    Also: I have tried to get samba to work via SSO on my domain and failed miserably so thats out the window.


    Anybody any Ideas ?

    TIA.

  2. #2

    glennda's Avatar
    Join Date
    Jun 2009
    Location
    Sussex
    Posts
    7,786
    Thank Post
    272
    Thanked 1,130 Times in 1,026 Posts
    Rep Power
    348
    Why don't you setup the Samba Server to auth against AD? surely that makes it simplier?

    There is a good guide on the Wiki - but never tried it with Centos - with Ubuntu it works

    Alternatively you could setup the usernames the same on the samba server and use things like %username% etc in the batch files.

  3. Thanks to glennda from:

    cpjitservices (18th July 2012)

  4. #3
    cpjitservices's Avatar
    Join Date
    Jul 2010
    Location
    Hessle
    Posts
    2,419
    Thank Post
    507
    Thanked 282 Times in 258 Posts
    Rep Power
    81
    tried to setup my Samba server to authenticate against AD and couldn't get it to work!

    I might try and add accounts in AD the same as the ones in Samba.

  5. #4

    glennda's Avatar
    Join Date
    Jun 2009
    Location
    Sussex
    Posts
    7,786
    Thank Post
    272
    Thanked 1,130 Times in 1,026 Posts
    Rep Power
    348
    Quote Originally Posted by cpjitservices View Post
    tried to setup my Samba server to authenticate against AD and couldn't get it to work!

    I might try and add accounts in AD the same as the ones in Samba.
    Well depends on how secure you want to be but you could do something like with the password parameter as the username?

    net use P: \\server\share /user:%username% %username% (i can't remember where you put password in when scripting).

SHARE:
+ Post New Thread

Similar Threads

  1. Replies: 27
    Last Post: 28th January 2011, 09:56 AM
  2. Name mapped drives via script
    By Bluetooth in forum Scripts
    Replies: 5
    Last Post: 20th November 2009, 09:15 PM
  3. Script to map drive by OU
    By cookie_monster in forum Scripts
    Replies: 1
    Last Post: 12th October 2009, 09:02 PM
  4. Replies: 19
    Last Post: 18th April 2008, 07:49 AM
  5. Replies: 4
    Last Post: 7th December 2005, 08:09 PM

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •