LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Desktop
User Name
Password
Linux - Desktop This forum is for the discussion of all Linux Software used in a desktop context.

Notices


Reply
  Search this Thread
Old 06-06-2015, 12:55 PM   #1
rl23455
LQ Newbie
 
Registered: Dec 2007
Posts: 6

Rep: Reputation: 0
how to Run Virtualbox gui as root


how to Run Virtualbox gui as root?

My windows motherboard failed so I used instructions on how to use a physical hard drive with Virtualbox Vm. I moved the hard drive to my linux box. I already made backups of the win7 hard drive.

So the problem seems to be Virtualbox doesn't have r/w permissions on the hard drive. Another forum said they ran Vbox as root and it worked for them. But I can't figure out how to run Vbox as root. I usually log in as a regular user, not root user. I know how to use sudo, but don't know how to start the vbox gui from command line(searched for that and couldn't find an answer either)

I should be able to change fstab the uid and guid on the hard drive to allow vboxusers group, but my patience has run out, been working on this for a week.

Using Linux mint 17.1 cinnamon
 
Old 06-06-2015, 01:11 PM   #2
Teufel
Member
 
Registered: Apr 2012
Distribution: Gentoo
Posts: 616

Rep: Reputation: 142Reputation: 142
gksu for gui apps.
 
Old 06-06-2015, 02:50 PM   #3
jefro
Moderator
 
Registered: Mar 2008
Posts: 21,980

Rep: Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624
You don't need to run virtualbox as root as far as I know. You need to create a virtual machine where the virtual hard drive is attached as the physical drive.

The problem is that your windows 7 will complain about this massive hardware change. You might be able to correct the hal.

A web page about attaching the physical drive. http://www.serverwatch.com/server-tu...ualbox-vm.html
 
Old 06-06-2015, 02:59 PM   #4
rl23455
LQ Newbie
 
Registered: Dec 2007
Posts: 6

Original Poster
Rep: Reputation: 0
from what I've read gksu shouldn't be used, hasn't been updated since 2009
 
Old 06-06-2015, 05:33 PM   #5
rl23455
LQ Newbie
 
Registered: Dec 2007
Posts: 6

Original Poster
Rep: Reputation: 0
this is what I was following and it doesn't work because Virtualbox says it doesn't have permissions to the physical hard drive(or at least that is how I interpret it)

Quote:
Originally Posted by jefro View Post
You don't need to run virtualbox as root as far as I know. You need to create a virtual machine where the virtual hard drive is attached as the physical drive.

The problem is that your windows 7 will complain about this massive hardware change. You might be able to correct the hal.

A web page about attaching the physical drive. http://www.serverwatch.com/server-tu...ualbox-vm.html
 
Old 06-07-2015, 12:38 AM   #6
mralk3
Slackware Contributor
 
Registered: May 2015
Distribution: Slackware
Posts: 1,900

Rep: Reputation: 1050Reputation: 1050Reputation: 1050Reputation: 1050Reputation: 1050Reputation: 1050Reputation: 1050Reputation: 1050
how to Run Virtualbox gui as root

Mount the disk as rw, change the owner/group to a user such as root:root then attach the drive to VirtualBox and boot it up?

You SHOULD NOT run VirtualBox as root, or ever have need to for any reason.

Why exactly is this disk being mounted as read only? Is it possible it has errors in the file system and Linux is mounting it read only to prevent further damage to the disk?

I think focusing on why the disk is being mounted read only rather than why you can't use it in VirtualBox will lead you to a solution.
 
Old 06-07-2015, 11:03 AM   #7
rl23455
LQ Newbie
 
Registered: Dec 2007
Posts: 6

Original Poster
Rep: Reputation: 0
I'm having trouble figuring out how to edit fstab by command line. googling how to's...
 
Old 06-07-2015, 08:30 PM   #8
replica9000
Senior Member
 
Registered: Jul 2006
Distribution: Debian Unstable
Posts: 1,126
Blog Entries: 2

Rep: Reputation: 260Reputation: 260Reputation: 260
If you run VBox as root, your existing VMs won't appear, as root will have a different VBox profile than your normal account.
 
Old 06-08-2015, 08:39 AM   #9
mralk3
Slackware Contributor
 
Registered: May 2015
Distribution: Slackware
Posts: 1,900

Rep: Reputation: 1050Reputation: 1050Reputation: 1050Reputation: 1050Reputation: 1050Reputation: 1050Reputation: 1050Reputation: 1050
Quote:
Originally Posted by replica9000 View Post
If you run VBox as root, your existing VMs won't appear, as root will have a different VBox profile than your normal account.
Not only that but please see this for a more important reason that every *nix user should know.
 
Old 06-08-2015, 08:41 AM   #10
mralk3
Slackware Contributor
 
Registered: May 2015
Distribution: Slackware
Posts: 1,900

Rep: Reputation: 1050Reputation: 1050Reputation: 1050Reputation: 1050Reputation: 1050Reputation: 1050Reputation: 1050Reputation: 1050
Quote:
Originally Posted by rl23455 View Post
I'm having trouble figuring out how to edit fstab by command line. googling how to's...
You should check out the man page by typing:

Code:
man fstab

Most of the time it's not necessary to google Linux related issues if you just read the man pages. Being completely reliant on google for answers regarding your operating system leave you crippled when you have no internet connection...
 
Old 06-08-2015, 03:08 PM   #11
replica9000
Senior Member
 
Registered: Jul 2006
Distribution: Debian Unstable
Posts: 1,126
Blog Entries: 2

Rep: Reputation: 260Reputation: 260Reputation: 260
If you're not able to access a physical drive with VBox, you could convert a disk-image/clone of your Windows install to a .vdi file that VBox can use:

Code:
VBoxManage convertfromraw --format VDI [filename].img [filename].vdi

Last edited by replica9000; 06-08-2015 at 03:53 PM. Reason: typo
 
Old 06-08-2015, 04:58 PM   #12
jefro
Moderator
 
Registered: Mar 2008
Posts: 21,980

Rep: Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624
Did you get the tips in this link? http://www.serverwatch.com/server-tu...ualbox-vm.html
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
How do I run a gui program as root? paveway Linux - Newbie 14 06-19-2012 01:21 AM
VirtualBox GUI will not start for non-root user astrogeek Slackware 21 12-23-2008 12:12 PM
How to run GUI program as root shadkong Slackware 8 09-20-2005 02:24 PM
Unable to run a GUI app as root using su? vharishankar Linux - General 7 05-25-2005 08:08 AM
Can't run gui applications as root vdogvictor Linux - General 26 08-19-2004 08:24 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Desktop

All times are GMT -5. The time now is 11:52 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration