Jump to content

Virtual machine additions?


Recommended Posts

I have been testing my CD/DVDs out on a virtual machine and just noticed that one of the first things i do after booting up is re-loading the virtual machine additions

Is there any way to put these onto my image? (i'm vaguely aware that there's some way of creating an iso from VM but have never tried it so it also begs the question - does VM work like ghost et al in this way? can it be used as a disk cloner?)

Now call me lazy because i could probably experiment and find out all of the above but i wondered if anyone could help so i dont have to re-invent the wheel

Thanks in advance

:thumbup

Link to comment
Share on other sites


This is an AutoIt script for VMWare additions based from RogueSpear's VBScript solution to detect whether inside VMWare and install the additions if it is. It uses WMI so should be executed as late as the RunOnce key just before logon. I keep an archive with the additions which the script can execute.

Global $objWMIService, $colBIOS, $objBIOS, $strComputer = ".", $exitcode
$objWMIService = ObjGet('winmgmts:{impersonationLevel=impersonate}!\\' & $strComputer & '\root\cimv2')
$colBIOS = $objWMIService.ExecQuery('Select * from Win32_BIOS')
If IsObj($colBIOS) Then
For $objBIOS In $colBIOS
If $objBIOS.SerialNumber Then
If StringLeft($objBIOS.SerialNumber, 6) = 'VMware' Then
If FileExists(@ScriptDir & '\VMWareTools.exe') Then
RunWait('"' & @ScriptDir & '\VMWareTools.exe"')
EndIf
EndIf
EndIf
Next
EndIf
RunWait('sc start VMTools', '', @SW_HIDE)

Kudo's to RogueSpear for the original VBSript.

I may expect VirtualPC maybe similar to script from reading the bios.

:)

Edited by MHz
Link to comment
Share on other sites

I have been testing my CD/DVDs out on a virtual machine and just noticed that one of the first things i do after booting up is re-loading the virtual machine additions

Is there any way to put these onto my image? (i'm vaguely aware that there's some way of creating an iso from VM but have never tried it so it also begs the question - does VM work like ghost et al in this way? can it be used as a disk cloner?)

Now call me lazy because i could probably experiment and find out all of the above but i wondered if anyone could help so i dont have to re-invent the wheel

Thanks in advance

:thumbup

If you want to use M$ Virtual PC instead of VMWare check out this thread...

http://www.msfn.org/board/index.php?showtopic=85061

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...