VBoxManage and VBOX_USER_HOME

Discussions related to using VirtualBox on Windows hosts.
Post Reply
jonha
Posts: 33
Joined: 31. Jul 2015, 19:09

VBoxManage and VBOX_USER_HOME

Post by jonha »

VBoxManage seems to ignore (ie not expand) environment variables given in the command line. For those who like to parametrise their setup, this is unhelpful.

(If I am missing sth obvious, please advise.)

Win7Pro x64, VBox 4.3.20 x64
mpack
Site Moderator
Posts: 39134
Joined: 4. Sep 2008, 17:09
Primary OS: MS Windows 10
VBox Version: VirtualBox+Oracle ExtPack
Guest OSses: Mostly XP

Re: VBoxManage and VBOX_USER_HOME

Post by mpack »

A concrete example of what you mean would be useful. What command you used, what you expected to happen, what actually happened.

VBOX_USER_HOME is where VirtualBox.xml is stored, and the VBoxSVC log file. I'm struggling to think of why you would care about either of those things in a script or batch file.

As far as I'm aware, macro expansion is something that the Windows batch file parser (or Cmd.exe applet) deals with. It has nothing to do with VirtualBox.
jonha
Posts: 33
Joined: 31. Jul 2015, 19:09

Re: VBoxManage and VBOX_USER_HOME

Post by jonha »

Environment variables are indeed expanded by the command processor (though I use Take Command not cmd.exe but tcc.exe does it as well); should've remembered that. Thanks for the reminder.

So, upon re-examining my original batch file, I found a stupid typo and after correcting that, everything is working.

As to why I need this... well, I have my virtual machines with all their files (.XMLs, .VDIs, snapshots etc.) under various directories all living inside VBOX_USER_HOME. And two of those VMs use custom SLIC tables which are loaded via VBoxManage.
mpack
Site Moderator
Posts: 39134
Joined: 4. Sep 2008, 17:09
Primary OS: MS Windows 10
VBox Version: VirtualBox+Oracle ExtPack
Guest OSses: Mostly XP

Re: VBoxManage and VBOX_USER_HOME

Post by mpack »

VirtualBox VMs have not used .xml files for several years, nor stored anything of importance in the VBOX_USER_HOME folder. Your v3 VMs folder structure must be ancient - you really ought to update this before support is dropped.
jonha
Posts: 33
Joined: 31. Jul 2015, 19:09

Re: VBoxManage and VBOX_USER_HOME

Post by jonha »

In the old days (WinXP) I had a semi-portable setup for VirtualBox 3, ie one rather big directory tree containing everything needed to run VBox and the VMs on this or a different machine. Just copying the tree meant that I could use the whole setup on another XP machine w/o having to install anything.

These days, VBox is properly installed in %ProgramFiles% but my directory layout for all the data is still the same. I see no reason to change that as it is (or should) wholly my business where I put my data.
Post Reply