7 Replies Latest reply on Nov 13, 2009 1:22 PM by Mach6

    Mapping drive not working in provisioning.


      I have a strange problem that I have not been able to figure out.


      I have a provisioning task that has half a dozen includes.


      Each includes is independant and can be run on it's own.  i.e. Each one will connect the the server and download the needed files, etc.

      The problem comes when I string the includes together.  The first mapped drive or connect to resource will work but any after that will not.  The task will say that the map to drive was successful.  But when a program that is set to be is run after the file copy it errors out because nothing was copied.


      Has any one had this problem before?

        • 1. Re: Mapping drive not working in provisioning.

          At the end of each self contained template do you have it unmap the drive?  I believe that if the drive letter is already in use the drive map command will fail.  It doesn't have any "memory" that it already mapped the same drive, so it simply knows that it needs to map a drive, but can't because the letter isn't free.


          If you haven't done it already try unmapping the drive at the end of each self contained template.


          Let me know how that goes.

          1 of 1 people found this helpful
          • 2. Re: Mapping drive not working in provisioning.

            Well, unmapping seems to help on one of them mapping commands.

            However, there is still one left that will not map correctly.

            I went through and broke the entire provisioning componet down and figured out that the process will not map correctly after a reboot.  If I take the reboot command out it then maps correctly and copies the files.

            I have tried adding a wait command and restarting the "Server" service, etc. but nothing will make it map correctly.

            • 3. Re: Mapping drive not working in provisioning.

              I'm trying to see if I can replicate this problem.  Just as a test do you mind trying to map to a different drive letter after the reboot?


              I'll let you know how my testing goes also.



              • 4. Re: Mapping drive not working in provisioning.

                Sorry, I forgot to state that part.

                When you originally told me to put in a unmap command for each one I put one in for every one, even the one with the scripted install (I just set it to not stop script if it fails).

                I also changed each mapping so that it has a unique drive letter as a just in case.  I was not sure if the LANDesk agent was "remembering" that the letter was mapped, so I figured that would help rule it out.


                Current process' in the include that is giving me trouble is:


                1. Registry Edit, import file:

                This is so it will autologon with the local admin user name.  Computer is not on the domain at this point.  I doubt that this is the issue as The exact same reg hit is is used eight other times in the script.


                Windows Registry Editor Version 5.00

                [HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon]


                2. Reboot


                3. Delete folder c:\updates with delete subdirectories checked.

                This is mostly just a make sure set for testing.  When I run the provisioning part I just want to make sure that the folder is deleted before it copies anything.


                4. Map drive.

                uncpath: \\<landesk server>\Provisioning\Updates

                drive letter: u:

                username %domainadmin%

                password %domainadminpassword%


                5. create directory c:\updates


                6. copy files from U: to C:\updates


                7. wait for file C:\updates\zzz.txt

                Just a trouble shooting step as this is the last file copied, (it is a text file with some junk comments in it).


                8. unmap drive U:


                9: Run C:\updates\autopatcher.bat


                When I take out the reboot everything works fine.  Except for the fact that I (probably) need to put a reboot in there for the software.

                • 5. Re: Mapping drive not working in provisioning.

                  OK, looks like I was able to get it to map and unmap after a reboot.  When you look at Provisioning History on the device what internal exit code and external exit code do you get?

                  • 6. Re: Mapping drive not working in provisioning.

                    I just ran the task again and I get a "Success" on the map but when I try to copy the files it does not work.


                    When I look at the u: drive in my computer it says "disconnected."  I am not sure if this is an issue because it works for the other processes.


                    Would it help if I posted the ldProvisioning.log file from the client?

                    • 7. Re: Mapping drive not working in provisioning.

                      It would be very helpful you could tell me what the provisioning history for that device (in the LANDesk Console) shows as the exit code for that task.  That, along with the log file you mentioned, would provide a lot of additional insight.