Page 1 of 1
Access VM from different user accounts
Posted: 3. Jan 2018, 11:00
by PhilDeebob
Hi, how is it possible to access the same VM but from two different user accounts on the same MacBookPro?
I don't have so much disk space and so would like to access VM and Windows from two different accounts (one is my work account, the other my personal user account)
Thanks for useful info.
Re: Access VM from different user accounts
Posted: 3. Jan 2018, 13:06
by socratis
Doable, but not easily. The main problem is the permissions which are assigned as read-write for the owner, no access for anyone else. So you could be putting your VMs in "/Users/Shared/VMs" for example, but each and every time that you shut down the VM and you close VirtualBox you got to change the permissions to all-write most probable from the Terminal with "sudo chmod -R a+rw <VMfolder>". A pain, but doable...
Re: Access VM from different user accounts
Posted: 3. Jan 2018, 17:15
by PhilDeebob
Hi, thanks for the tip, I will see if it's worth it. Effectively at login /shutdown to the particular Mac user account I could get a script to run...ease the pain..
Re: Access VM from different user accounts
Posted: 3. Jan 2018, 21:51
by socratis
Just keep in mind that you can't run that script as a simple user. You have to be an Administrator, in order to be able to run "sudo", which is turning you into 'root'. Only 'root' can change the permissions of another user's files.
Re: Access VM from different user accounts
Posted: 3. Jan 2018, 22:02
by PhilDeebob
Just to be sure I understand this, before I next start the VM - with a different user to the last one using the VM - I have to ensure somehow, that the permissions for the VM folder are set to "all write"? Seems ok if that's all there is to it, especially as you provided the shell command to do this.
Second question, and excuses if it's been answered, if I move the curretn machine location from say "/Users/User1/VMs" to "/Users/Shared/VMs" are there any global variables or other settings I need to be changing?
Many thanks, most helpful

Philip
Re: Access VM from different user accounts
Posted: 3. Jan 2018, 22:07
by socratis
PhilDeebob wrote:I have to ensure somehow, that the permissions for the VM folder are set to "all write"?
Not "somehow", there's a pretty specific way to do it, and as I said, it involves being in the Administrators group (so that you can actually run 'sudo'). And not just the folder, but its sub-folders and files as well.
PhilDeebob wrote:I move the curretn machine location from say "/Users/User1/VMs" to "/Users/Shared/VMs" are there any global variables or other settings I need to be changing?
Depends. Read the FAQ "
Moving a VM" first. That's for already created VMs.
For future VMs, it's best if you change the "Default Machine Folder" in the VirtualBox preferences to point to the shared directory.
Re: Access VM from different user accounts
Posted: 3. Jan 2018, 22:08
by PhilDeebob
Perfect, thanks again