Automatic PC reboot after VirtualBox installation
Automatic PC reboot after VirtualBox installation
I have a batch file installing VirtualBox in silent mode, using the --silent parameter, installing the extension pack and then doing other stuff.
The issue is that something, not everytime, the VirtualBox installation forces a computer reboot before my script finishes executing. I tried with VirtualBox 4.3.8 and 4.3.10, but they have the same behavior.
Why does the VirtualBox forces a computer reboot for a silent installation? If there a way to prevent that?
The issue is that something, not everytime, the VirtualBox installation forces a computer reboot before my script finishes executing. I tried with VirtualBox 4.3.8 and 4.3.10, but they have the same behavior.
Why does the VirtualBox forces a computer reboot for a silent installation? If there a way to prevent that?
-
Perryg
- Site Moderator
- Posts: 34369
- Joined: 6. Sep 2008, 22:55
- Primary OS: Linux other
- VBox Version: OSE self-compiled
- Guest OSses: *NIX
Re: Automatic PC reboot after VirtualBox installation
How do you know it is VirtualBox rebooting the guest? Speculation without diagnostics to back it up is not very useful.
Re: Automatic PC reboot after VirtualBox installation
My script logs each step in a text file. Here is what it logs when it reboot:
Normally, right after the VirtualBox Installation, I have an echo saying that the extension pack installation will begin. So I speculate that it's VirtualBox doing it since the step right after is not executed.************************************************************
"Visual Studio 2010 Redistributable SP1 installation"
"CALL C:\Users\admin\AppData\Local\Temp\is-PVNII.tmp\vcredist_x86.exe /q /norestart"
************************************************************
"Oracle VM VirtualBox installation"
"CALL C:\Users\admin\AppData\Local\Temp\is-PVNII.tmp\VirtualBox-4.3.10-93012-Win.exe --silent"
-
Perryg
- Site Moderator
- Posts: 34369
- Joined: 6. Sep 2008, 22:55
- Primary OS: Linux other
- VBox Version: OSE self-compiled
- Guest OSses: *NIX
Re: Automatic PC reboot after VirtualBox installation
OK so where in this text file does it say VirtualBox is the one that is requesting the reboot?
You see VirtualBox doesn't really have the means to do so on it's own and unless you can point me to a command that VirtualBox has issued I can't believe that it is VirtualBox that is doing so.
You see VirtualBox doesn't really have the means to do so on it's own and unless you can point me to a command that VirtualBox has issued I can't believe that it is VirtualBox that is doing so.
Re: Automatic PC reboot after VirtualBox installation
Perryg, the default behavior of Virtualbox is to prompt the user to reboot once it is installed. Internally Vbox uses the msiexec Windows installer functionality, which DOES have the power to restart, and the default embedded into the silent installer is likely to force a reboot.
If using the EXE installer you can pass --silent and then -msiparams /norestart to request the the MSI doesn't force a reboot, but using the EXE in my case it didn't force a reboot when I just used --silent and -msiparams ADDLOCAL=VBoxApplication,VBoxNetworkFlt,VBoxPython,VBoxNetworkAdp,VBoxNetwork (we don't want the USB in our case).
If using the EXE installer you can pass --silent and then -msiparams /norestart to request the the MSI doesn't force a reboot, but using the EXE in my case it didn't force a reboot when I just used --silent and -msiparams ADDLOCAL=VBoxApplication,VBoxNetworkFlt,VBoxPython,VBoxNetworkAdp,VBoxNetwork (we don't want the USB in our case).
-
Perryg
- Site Moderator
- Posts: 34369
- Joined: 6. Sep 2008, 22:55
- Primary OS: Linux other
- VBox Version: OSE self-compiled
- Guest OSses: *NIX
Re: Automatic PC reboot after VirtualBox installation
Dragon788,
Thanks for your explanation and this is all true but that has nothing to do with VirtualBox in that sense. This is a Microsoft installer and the use thereof would be dependant to Microsoft. So the random sometimes it works and sometimes it does not would still be an MSI issue. But I think I have hashed this enough and will move on to other issues.
Thanks for your explanation and this is all true but that has nothing to do with VirtualBox in that sense. This is a Microsoft installer and the use thereof would be dependant to Microsoft. So the random sometimes it works and sometimes it does not would still be an MSI issue. But I think I have hashed this enough and will move on to other issues.
-
scottgus1
- Site Moderator
- Posts: 20945
- Joined: 30. Dec 2009, 20:14
- Primary OS: MS Windows 10
- VBox Version: VirtualBox+Oracle ExtPack
- Guest OSses: Windows, Linux
Re: Automatic PC reboot after VirtualBox installation
Dragon, I think I get why you feel it's Virtualbox:
Perry is correct that the issue is with the MSI installer which Virtualbox distributes Microsoft MSI system that runs Virtualbox's installer. But it is easy to see why Virtualbox could be blamed. You're running "VirtualBox-4.3.10-93012-Win.exe" not "MSI.exe" or whatever it's called, right?
But "Virtualbox-4.3.10-93012-Win.exe" actually unpacks an MSI installation package out of itself, then asks the MSI system to install that package. The Virtualbox exe doesn't ask for the reboot, the MSI exe does. There is where you should look for why it is not respecting the no-reboot switch.
You don't get the "installing Extension Pack" message when you get a reboot request? If so that would sure seem to lay the "blame" for the reboot request at the feet of the Virtualbox installer.Normally, right after the VirtualBox Installation, I have an echo saying that the extension pack installation will begin. So I speculate that it's VirtualBox doing it since the step right after is not executed
Perry is correct that the issue is with the MSI installer which Virtualbox distributes Microsoft MSI system that runs Virtualbox's installer. But it is easy to see why Virtualbox could be blamed. You're running "VirtualBox-4.3.10-93012-Win.exe" not "MSI.exe" or whatever it's called, right?
But "Virtualbox-4.3.10-93012-Win.exe" actually unpacks an MSI installation package out of itself, then asks the MSI system to install that package. The Virtualbox exe doesn't ask for the reboot, the MSI exe does. There is where you should look for why it is not respecting the no-reboot switch.
Last edited by scottgus1 on 18. Jun 2015, 16:27, edited 1 time in total.
-
scottgus1
- Site Moderator
- Posts: 20945
- Joined: 30. Dec 2009, 20:14
- Primary OS: MS Windows 10
- VBox Version: VirtualBox+Oracle ExtPack
- Guest OSses: Windows, Linux
Re: Automatic PC reboot after VirtualBox installation
Alternatively, you could issue the commands in your script to manually unpack the MSI out of the Virtualbox exe and issue the no-reboot switch yourself in the next command to install the unpacked MSI.
-
Perryg
- Site Moderator
- Posts: 34369
- Joined: 6. Sep 2008, 22:55
- Primary OS: Linux other
- VBox Version: OSE self-compiled
- Guest OSses: *NIX
Re: Automatic PC reboot after VirtualBox installation
Thanks scott, but to clarify this AFAIK VirtualBox does not ship the MSI installer, it is already installed by Microsoft. It provides a script that the MSI installer uses.MSI installer which Virtualbox distributes
-
scottgus1
- Site Moderator
- Posts: 20945
- Joined: 30. Dec 2009, 20:14
- Primary OS: MS Windows 10
- VBox Version: VirtualBox+Oracle ExtPack
- Guest OSses: Windows, Linux
Re: Automatic PC reboot after VirtualBox installation
Woops, should have been "MSI package", I reckon. But even then the issue probably isn't even with the package, but somehow with Microsoft's MSI system. Badly worded sentence...
-
Perryg
- Site Moderator
- Posts: 34369
- Joined: 6. Sep 2008, 22:55
- Primary OS: Linux other
- VBox Version: OSE self-compiled
- Guest OSses: *NIX
Re: Automatic PC reboot after VirtualBox installation
Not faulting you scott. Just pointing it out since others would see the thread and think that VBox ships the installer.
-
scottgus1
- Site Moderator
- Posts: 20945
- Joined: 30. Dec 2009, 20:14
- Primary OS: MS Windows 10
- VBox Version: VirtualBox+Oracle ExtPack
- Guest OSses: Windows, Linux
Re: Automatic PC reboot after VirtualBox installation
Totally understand, Perry, not feeling faulted at all 