1 2 Previous Next 23 Replies Latest reply on Mar 17, 2013 6:44 PM by snapper

    Steps required after P2V - Dev Con, Device Mangler etc

    java_cat33 Master

       

      Hi - After a server is P2V'd, ALL server management agents removed, changed the HAL, installed VMware tools etc....

       

       

      VM performance is fine - does anyone perform any additional steps? I've seen posts about people removing hardware drivers etc, however I remove all un-necessary devices before powering on the VM. When turning on the hidden devices I do not see any hidden devices.

       

       

      Does anyone use Dev Con or Device Mangler etc??

       

       

      Also I've noticed you cannot change the HAL to a uniprocessor from a multi if the Windows box is W2K3 SP1 - however this is resolved if W2K3 SP2 is installed. Anyone know of any other work arounds?

       

       

      I did read on a MS site there was a hotfix - however it looks like this is no longer available as it is now part of W2K3 SP2.....

       

       

        • 1. Re: Steps required after P2V - Dev Con, Device Mangler etc
          OlivierTremolieres Hot Shot

           

          Hi,

           

           

          When I use P2V, I also change VM's configuration about local devices : Floppy, CDROM, Serial port, USB, etc... I always delete all local entry to improuve performance, except CDROM I only disconnect it.

           

          Olivier

           

           

          ###############

          If you found this information useful, please consider awarding points for "Correct" or "Helpful". Thanks!!!

           

           

          • 2. Re: Steps required after P2V - Dev Con, Device Mangler etc
            icontrolyourpower Enthusiast

            To see devices which no longer exist, you will need to set an environment variable named "devmgr_show_nonpresent_devices" to 1 and launch Device Manager from a shell in which that variable is active. After doing this, checking the show hidden devices option will function as expected.

             

            The HAL hotfix is available if you call Microsoft.

             

            Converter creates converted 2k3 servers with BusLogic adapters. I always change that to the recommended LSI adapter type. I do not know why Converter does this or if there are any negative consequences of changing it to LSI Logic. I have not seen any.

             

            I've noticed assigned shares are often incorrect for the resources allocated to the converted VM. Opening and re-OK'ing the dialog seems to resolve this behavior.

            1 person found this helpful
            • 3. Re: Steps required after P2V - Dev Con, Device Mangler etc
              java_cat33 Master

               

              Hi guys - yes I already do what you guys do also.

               

               

              Sounds like I've got it pretty covered

               

               

              I might give MS a call and get the hotfix (although we need to go to SP2 at some stage soon anyway).....

               

               

              • 4. Re: Steps required after P2V - Dev Con, Device Mangler etc
                OlivierTremolieres Hot Shot

                 

                Hi,

                I agree with you about BusLogic adapters and you're right changing it by LSI adapter. Converter uses BusLogic because you can have a specific adapter card on your physical server. So, by using BusLogic, your VM won't have trouble to start (BusLogic is a generic adapter). Changing adapter, you also have to convert disk. Notice that the convert doesn't work on Windows 2000 server because the boot step on W2k doesn't accept new card/disk. Windows 2003 haven't got problem, but you have to reboot after the first boot.

                LSI has got more performance than BusLogic, so it is a very good idea to change it.

                 

                 

                About devices, I uninstall and delete all locals devices : Floppy, serial, LPT, USB and all around. I have to uninstall in Windows too... I didn't know this variable : devmgr_show_nonpresent_devices. I take note

                 

                 

                Olivier

                 

                ###############

                If you found this information useful, please consider awarding points for "Correct" or "Helpful". Thanks!!!

                 

                 

                • 5. Re: Steps required after P2V - Dev Con, Device Mangler etc
                  sapirgolan Novice

                   

                  Hi Guys,

                   

                   

                  I ahve added the "devmgr_show_nonpresent_devices" variable and restarted the VM.

                   

                   

                  Now When I open the device manager I can see gray devices. Shell I remove them? If so, does the VM performance will be better?

                   

                   

                  (see attachment)

                   

                   

                  • 6. Re: Steps required after P2V - Dev Con, Device Mangler etc
                    snapper Enthusiast

                     

                    Our post - P2V process uses devcon for most of the automation.

                     

                     

                    1. For a defined set of classes (ie, run 'devcon classes'), find the difference between a devcon findall and devcon find. This finds a number of devices that are 'non present', and can be simply removed using devcon remove. This normally covers all the network cards, storage, drives and sound/video components. This does not work well with system device classes, so don't use them  unless you want strange behaviour in your VM.

                     

                     

                    2.You can easily modify the hal between UP and MP in Windows 2000 and 2003 without any hotfixes, and without being dodgy.  The process is basically telling the OS the valid options for the HAL.

                    ie, if you do a devcon hwids @root\*hal* and look at the 'hardware ID's', you will see the 'compatible' IDs. Use devcon to simply add another valid id and switch it to MP or UP as you wish.

                    to switch from MP to UP -  devcon  sethwid @root\*hal* :=+ACPIAPIC_MP

                    to switch from UP to MP - devcon sethwid @root\*hal* :=+ACPIAPIC_UP

                     

                     

                    then  devcon update "%windir%\inf\hal.inf" ACPIAPIC(UP|MP) will force the update, and reboot.

                     

                     

                    The third part of the post process is to remove known software. This is done by maintaing a list of known software titles (from add remove programs registry entries). This is usually HP openview, Dell software and anything else you come across. If there is a match, the script simply tells it to run the uninstall string listed in the registry. This works 90% of the time.

                     

                     

                    Anyone is more than welcome to the shell scripts for the above - I just don't have them with me atm

                     

                     

                    Cheers,

                     

                     

                    SP

                     

                     

                     

                     

                     

                    1 person found this helpful
                    • 7. Re: Steps required after P2V - Dev Con, Device Mangler etc
                      OlivierTremolieres Hot Shot

                       

                      Well, I'm not sure it will improve performance. But, for me, if you delete them, windows will have got less drivers to load, and so, more disponibility for other.

                       

                       

                      For security, make a snapshot before delete them... we never know...

                       

                       

                      Olivier

                       

                      ###############

                      If you found this information useful, please consider awarding points for "Correct" or "Helpful". Thanks!!!

                       

                       

                      • 8. Re: Steps required after P2V - Dev Con, Device Mangler etc
                        java_cat33 Master

                         

                        Hi Snapper - I can see all the hidden devices (HP NIC drivers etc) - is there a way I can just use devcon to remove everything that is hidden / greyed out? Or do I just run "devcon remove"?

                         

                         

                        I'm new to Dev Con.... and it sounds like you aren't

                         

                         

                        • 9. Re: Steps required after P2V - Dev Con, Device Mangler etc
                          snapper Enthusiast


                                1. 25 June 08 - Updated **





                          Last update, I promise.



                          I made some additional chages to this hardware removal script and tested it over the past couple of months with conversions. It now removes (for my Win 2000/2003) machines all non-present devices except those listed under 'non plug and play drivers'. This is the location of vendor specific devices and still needs to be cleaned manually. Other than that, the script should remove all other non-present devices.



                          Cheers,

                          SP


                           

                          Someone pointed out that the script attached here doesn't actually work! The actual line that did the removal was configured to just echo the command .. oops. This has been fixed now










                          Devcon is not able to detect ghosted devices. You can do a devcon find and a devcon findall which shows the difference between present and non-present devices.





                          The way described in my previous email will remove the important non-present devices such as media, networking, sound/video etc, but you can define this by which class you use. Some of the devices (especially system devices) come up as non present, inparticular was the terminal services redirector, so removing all devices (difference between find|findall) removed some of these, and hence why we are using devices in just a few classes.





                          I search for devices in the following classes:

                          net cdrom diskdrive display fdc hdc keyboard media monitor scsiadapter unknown floppydisk processor volume





                          If you want to do a complete automated ghosted hardware removal, the best way would be to run devcon on the physical hardware prior to imaging (devcon find), and compare this with an output run on the virtual machine (devcon findall). The difference between them will be the devices that were presented on the physical and no longer present on the virtual and remove them. Personally, I still think this cause cause troubles because of the software devices present.











                          I have attached the mentioned scripts to this post. The zip file contains 4 batch files:

                          1_runonvm.cmd - run on virtual machine to remove most of the non-present hardware

                          2_rundevmgr.cmd - run on virtual machine, sets the environment variable and launches devcon

                          downgrade_UP.cmd - automated script to change the current HAL to a uniprocessor (2000/2003)

                          upgrade_MP.cmd - automated script to change current HAL to multiprocessor (2000/2003)





                          The folder should be fully self-contained, contains binaries and is path-independant, so can run from network share (1_runonvm.cmd requires writing to the folder though).





                          If you use and make any improvements, feel free to let me know. Use at your own risk, obviously.





                          -SP

                          • 10. Re: Steps required after P2V - Dev Con, Device Mangler etc
                            java_cat33 Master

                            Thanks for all your help Snapper

                            • 11. Re: Steps required after P2V - Dev Con, Device Mangler etc
                              Merages Novice

                               

                              Hi Guys,

                               

                               

                               

                               

                               

                              After a P2V, download devcon

                               

                               

                              create a script with :

                               

                               

                               

                              devcon sethwid @ROOT\PCI_HAL\0000 := !E_ISA_UP !ACPIPIC_UP !ACPIAPIC_UP !ACPIAPIC_MP !MPS_UP !MPS_MP !SGI_MPS_MP !SYSPRO_MP !SGI_MPS_MP  > nul

                              devcon sethwid @ROOT\ACPI_HAL\0000 := !E_ISA_UP !ACPIPIC_UP !ACPIAPIC_UP !ACPIAPIC_MP !MPS_UP !MPS_MP !SGI_MPS_MP !SYSPRO_MP !SGI_MPS_MP > nul

                              devcon sethwid @ROOT\PCI_HAL\0000 := +ACPIAPIC_MP > nul

                              devcon sethwid @ROOT\ACPI_HAL\0000 := +ACPIAPIC_MP > nul

                              devcon update %windir%\inf\hal.inf ACPIAPIC_MP  > nul

                               

                               

                              run the script (on the same place that devcon.exe)

                               

                               

                              and reboot.

                               

                               

                               

                               

                               

                              PS : the first reboot could not run right, so you may need to do a power off then power on

                               

                               

                              ++

                               

                               

                              • 12. Re: Steps required after P2V - Dev Con, Device Mangler etc
                                snapper Enthusiast

                                 

                                Merages,

                                 

                                 

                                You'll notice that in my previous post (above), the scripts listed (downgrade_mp.cmd and upgrade_up.cmd) already do precisely this. ie, add the correct hardware IDs (hwids) to the HAL device. I believe your version will add the hwids of all listed HAL types from the hal.inf file, which is fine it just means it will allow Windows to detect it based on the best hwid match. The scripts provided will detect the current type of HAL (ie, acpiapic or acpipic etc) and modify it to be the same type but either the multiprocessor, or uniprocessor version of the same.

                                 

                                 

                                Adding all the known hwids is probably more appropriate if you are making a hardware independant image for deployment (which is very doable, by the way).

                                 

                                 

                                Cheers,

                                 

                                 

                                Simon

                                 

                                 

                                • 13. Re: Steps required after P2V - Dev Con, Device Mangler etc
                                  Jeffrey.Wall Lurker

                                   

                                  Love this tool and use it daily however am running into trouble on x64 platforms.  Any ideas / tips / tricks to get it to run on 2003 x64?

                                   

                                   

                                  Thank you.

                                   

                                   

                                  ~ Jeffrey

                                   

                                   

                                  • 14. Re: Steps required after P2V - Dev Con, Device Mangler etc
                                    rnotaro Novice

                                    I found a 64 bit devcon but havent been able to find a 64 bit lmod if one even exists.  Anyone else got this working on 64 bit WIndows 2003?

                                    1 2 Previous Next