7 Replies Latest reply on Mar 24, 2015 1:05 PM by MrGadget

    Pxe Representative Deployment Fails

    MrGadget Expert

      Running LD 9.5 SP3

      After upgrading from 9.5 SP2 to SP3 the Pxe Representative Deployment script that came with my original Landesk install would show success but never installed anything, it just uninstalled whatever files that were there.

       

      I called Landesk Support and was told this was known to happen for some people and not for others. It was suggested to copy Osdrep.msi to the Pxe Server and run it.

       

      Well that installs all the files except BCD which is needed to boot to Pxe. By the way the script calls for BCD.dat to be copyed and looking at a old pxe server install the file in the Boot fold is BCD not BCD.dat.  Also looking on the core in ldmain\landesk\vboot folder there is a BCD.dat which is older then the BCD file in there.

       

      I have over 26 Pxe Reps and don't want to remote in to each one and run osdrep and then copy the BCD file everytime I have to redeploy one.

      Anyone else had this problem?

       

      PS I have looked at permissions on the folders that contain the Pxe files on the core server and there have been no changes.

        • 1. Re: Pxe Representative Deployment Fails
          nick.evans SupportEmployee

          Hi MrGadget,

          Have you attempted to push a new 9.5 SP3 agent to the clients? I have seen problems after upgrade where a new PXE rep was attempted on an agent that had itself not been upgraded.

          If upgrading the agent does not correct the issue, what errors are you getting specifically?

          Looking at the PXE deployment script for 9.5 SP3, There are copy commands to move over BCD files and boot files:

           

          REMCOPY6=%DTMDIR%\landesk\vboot\bcd.dat, %LDMS_CLIENT_DIR%\bcd, TOREMOTE
          REMCOPY7=%DTMDIR%\landesk\vboot\bcd_x64.dat, %LDMS_CLIENT_DIR%\bcd_x64, TOREMOTE
          REMCOPY8=%DTMDIR%\landesk\vboot\bcd_ia32.dat, %LDMS_CLIENT_DIR%\bcd_ia32, TOREMOTE
          REMCOPY9=%DTMDIR%\landesk\vboot\boot.sdi, %LDMS_CLIENT_DIR%\boot.sdi, TOREMOTE
          REMCOPY10=%DTMDIR%\landesk\vboot\boot.wim, %LDMS_CLIENT_DIR%\boot.wim, TOREMOTE
          REMCOPY11=%DTMDIR%\landesk\vboot\boot_x64.wim, %LDMS_CLIENT_DIR%\boot_x64.wim, TOREMOTE
          REMCOPY12=%DTMDIR%\landesk\vboot\bootx64.efi, %LDMS_CLIENT_DIR%\bootx64.0, TOREMOTE
          REMCOPY13=%DTMDIR%\landesk\vboot\bootia32.efi, %LDMS_CLIENT_DIR%\bootia32.0, TOREMOTE
          REMCOPY14=%DTMDIR%\landesk\vboot\bootmgr.exe, %LDMS_CLIENT_DIR%\bootmgr.exe, TOREMOTE
          REMCOPY15=%DTMDIR%\landesk\vboot\pxeboot.0, %LDMS_CLIENT_DIR%\startrom.0, TOREMOTE
          

           

          Then it calls to execute osdrep.msi

           

          REMEXEC16=<qt/>%LDMS_CLIENT_DIR%\sdclient.exe<qt/> /p="http://%CUSTJOBHOSTIP%/landesk/files/osdrep.msi" /msi /N /An /Ac /g="{F238CE99-6614-4072-9D20-1D2FA7ED951A}" /disableclientqueue
          

           

          If you copied over and ran osdrep.msi only, it makes sense the bcd files might not be there.

          If you cannot get the script to work correctly, you could setup your own script to just copy over the residual files, and then do your osdrep.msi as a swd package.

          • 2. Re: Pxe Representative Deployment Fails
            Apprentice

            I've run into the same issue and I have 90+ PXE Reps.  Here is the powershell script that I use to deploy the PXE rep, I only have it downloading the WinPE files, but you could easily include the others if you need them.

             

            I hope that it helps

            Branden Ushio

            ----

             

            param (

              [string]$CoreServer = "NoneEntered"

            )

             

             

            If($CoreServer -eq "NoneEntered")

            {

            write-host Usage: .\Install_PXE.ps1 -CoreServer SERVERNAME

            [Environment]::Exit(5)

            Exit

            }

             

             

            $BasePath = "c:\Program Files (x86)\Landesk\PXE\System\Images"

             

            Write-Host Uninstalling PXE Rep Software

            Start-Process -FilePath "MsiExec.exe" -ArgumentList "/X `{F238CE99-6614-4072-9D20-1D2FA7ED951A`} /qn" -Wait -Passthru

            if(Test-Path $BasePath\Boot){

              write-host Boot Folder Exists }

            else {

              mkdir $BasePath\Boot

            }

             

             

            if(Test-Path $BasePath\x86pc\undi\winpe) {

              Write-Host WinPE Folder Exists}

            else {

              mkdir $BasePath\x86pc\undi\winpe

            }

            write-host Downloading Files from Core

            $client = New-Object System.Net.WebClient

            $client.DownloadFile("http://$CoreServer/landesk/files/osdrep.msi", "$BasePath\boot\osdrep.msi")

            $client.DownloadFile("http://$CoreServer/landesk/vboot/bcd.dat", "$BasePath\boot\bcd")

            $client.DownloadFile("http://$CoreServer/landesk/vboot/bcd_x64.dat", "$BasePath\boot\bcd_x64")

            $client.DownloadFile("http://$CoreServer/landesk/vboot/bcd_ia32.dat", "$BasePath\boot\bcd_ia32")

            $client.DownloadFile("http://$CoreServer/landesk/vboot/boot.sdi", "$BasePath\boot\boot.sdi")

            $client.DownloadFile("http://$CoreServer/landesk/vboot/boot.wim", "$BasePath\boot\boot.wim")

            $client.DownloadFile("http://$CoreServer/landesk/vboot/boot_x64.wim", "$BasePath\boot\boot_x64.wim")

            $client.DownloadFile("http://$CoreServer/landesk/vboot/bootx64.efi", "$BasePath\boot\bootx64.efi")

            $client.DownloadFile("http://$CoreServer/landesk/vboot/bootia32.efi", "$BasePath\\boot\bootia32.efi")

            $client.DownloadFile("http://$CoreServer/landesk/vboot/bootmgr.exe", "$BasePath\x86pc\undi\winpe\bootmgr.exe")

            $client.DownloadFile("http://$CoreServer/landesk/vboot/pxeboot.0", "$BasePath\x86pc\undi\winpe\startrom.0")

            write-host Installing Landesk PXE

            Start-Process -FilePath "MsiExec.exe" -ArgumentList "/i `"$BasePath\boot\osdrep.msi`" /passive" -Wait -Passthru

            • 3. Re: Pxe Representative Deployment Fails
              Apprentice

              When it launches that MSIExec process does it wait for it to be completed before moving onto the other lines of the script? Could it be possible that the PXE Rep doesn't uninstall until after the files are copied down? 

              • 4. Re: Pxe Representative Deployment Fails
                MrGadget Expert

                Nick,

                Thanks for your reply.  I will check and see if my agents are up to date on the Pxe servers and get back to you.

                today we have found another problem. Our pxe servers are in the process of being updated to Windows server 2012 R2. The first one they updated, now OSDREP.msi refuses to run at all.

                • 5. Re: Pxe Representative Deployment Fails
                  MrGadget Expert

                  Nick,

                  After checking that a up to date agent was on the Pxe Rep I uninstalled the existing Pxe services and files rebooted and ran the Pxe deployment script and it did nothing but the scheduled task showed success but no files were deployed or services started.

                  I then ran just the OSDREP.msi and everything installed.

                   

                  I also found why the BCD file was not being copied even from running the OSDREP.msi. Whoever made the script had 2 REMCOPY 6 commands, the second was for the BCD file, I changed all the numbers and now it copys the bcd file.

                  • 6. Re: Pxe Representative Deployment Fails
                    MrGadget Expert

                    I am not familiar with scripting. Do I copy what you have there and save as a .vbs ?  How do I run it?  Is there anything particular to my site that I have to substitute in any of the lines?

                     

                    Also have you ran this on Server 2012 R2 because after getting the Pxe to install by running OSDREP.msi on all my PXe's we have started upgrading to Server 2012 R2 and OSDREP.MSI will not run on any of those.?

                    • 7. Re: Pxe Representative Deployment Fails
                      MrGadget Expert

                      The Fix to my Pxe Rep Deployment failing is the original script that came with Landesk had 2 REMCOPY 6 commands and it ran the first command but the second REMCOPY 6 was copying the BCD file which never happened. After redoing the REMCOPY numbering that started working fine.

                       

                      My second problem with not being able to deploy a PXE Rep on a 20012 R2 server was due to the newest OSDREP.msi. I found another discussion on this forum that had to go back to a previous version that starts with revision 1248907B.which I got out of my old 9.5 install folder.