LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   Installing virtual machine on a usb stick to boot from because school computers suck (https://www.linuxquestions.org/questions/linux-software-2/installing-virtual-machine-on-a-usb-stick-to-boot-from-because-school-computers-suck-748213/)

zonemikel 08-17-2009 01:30 PM

Installing virtual machine on a usb stick to boot from because school computers suck
 
Hello everyone,

All of my school computers (that we always have to use) have vista installed when they could barley support XP. And on top of that they have tons of flaws that you can fix, but then every time you log out the settings are not saved, so you have to fix it every time you log in. Also some programs just constantly crash.

Its horribly annoying, especially when your stuck in a lab for 4 hours and compiling crashes the computer every time.

Anyway I'm pretty good with linux but most of the software i need is on windows (office, multisim, xilinx etc), is there anyway for me to use a virtual machine on a bootable usb drive to start xp on these computers and use my programs ?

I've actually installed windows on a bootable usb drive before, it only worked on the machine in which i installed it.

So this is my plan
usb drive -> boot linux -> load vm software (virtualbox) -> load virtualdrive with windows

Does anyone know if this would work ?

markush 08-17-2009 02:12 PM

Hello,

yes, this will work. But the computer must have enough of RAM (better more than 512MB).
Look at slax: http://www.slax.org/get_slax.php
Its a live-CD (with also usb-support) and as far as I know they have a module for vbox of sun.
You can install win xp on vbox and copy the virtual machine on a partition on the usb-drive.
Then you should be able to start vbox after booting with slax and opening the xp-machine.

Markus

repo 08-17-2009 02:23 PM

Quote:

but then every time you log out the settings are not saved, so you have to fix it every time you log in
This is set by the IT people, and has a reason
Quote:

Its horribly annoying, especially when your stuck in a lab for 4 hours and compiling crashes the computer every time.
Talk to IT for a solution.

zonemikel 08-17-2009 06:32 PM

Quote:

Originally Posted by repo (Post 3646993)
This is set by the IT people, and has a reason

Talk to IT for a solution.

Ya right, we have told them a million times, they dont care. Some of the problems are from the computers not being good enough to run vista, but most of the problems is bad IT.

Its simple things like you cant copy and paste in word because macros are disabled due to security things, also when you make programs in visual studio the working directory of cmd is not there so it cant spawn and show you your program. Yes these can both be fixed, but like i said you have to do it every time you log in/out.

Quote:

Hello,

yes, this will work. But the computer must have enough of RAM (better more than 512MB).
Look at slax: http://www.slax.org/get_slax.php
Its a live-CD (with also usb-support) and as far as I know they have a module for vbox of sun.
You can install win xp on vbox and copy the virtual machine on a partition on the usb-drive.
Then you should be able to start vbox after booting with slax and opening the xp-machine.

Markus
Thanks ill look into this, i've used slax before. I was hoping for something really simple and small with no gui then i could just have it run something in my startup scripts like "vbox xp.vdi" or something like that. If i have a whole OS running a gui then start another through virtual machine, all running on a usb it might be too slow ?

anyway thanks for the responses !

markush 08-18-2009 12:21 AM

Hi again,

I often use slax in windows-networks and I know that slax, even with the gui, often starts much faster than windows on the samce old PC. But since vista needs 2GB RAM or more there will be enough machines which are much to slow for vista but very good for slax, even with a virtual machine. My experience is that a virtual windows-xp PC with 256MB of RAM (only for the virtual machine) is good for normal working.

Markus

zonemikel 08-18-2009 11:05 AM

Quote:

Originally Posted by markush (Post 3647481)
Hi again,

I often use slax in windows-networks and I know that slax, even with the gui, often starts much faster than windows on the samce old PC. But since vista needs 2GB RAM or more there will be enough machines which are much to slow for vista but very good for slax, even with a virtual machine. My experience is that a virtual windows-xp PC with 256MB of RAM (only for the virtual machine) is good for normal working.

Markus

Ok thanks ! I'll get on it and let yall know how it goes. I wish i could just use linux, but multisim and xilinx wont work with linux.

zonemikel 08-21-2009 10:16 AM

Ok i got slax installed on a 4 gig usb. And i got my xp hard drive down to 2.7 gig so they both fit ok. The only thing is i cant start the virtual machine (or any) when i type "VBoxManage startvm "xp"" i get
Code:

root@slax:~# VBoxManage startvm XP
WARNING: The vboxdrv kernel module is not loaded. Either there is no module
        available for the current kernel (2.6.27.27) or it failed to
        load. Please recompile the kernel module and install it by

          sudo /etc/init.d/vboxdrv setup

        You will not be able to start VMs until this problem is fixed.
VirtualBox Command Line Management Interface Version 2.1.4_OSE
(C) 2005-2009 Sun Microsystems, Inc.
All rights reserved.

Waiting for the remote session to open...
[!] Full error info present: true , basic error info present: true
[!] Result Code = NS_ERROR_FAILURE (0x80004005) - Operation failed
[!] Text        = Virtual machine 'XP' has terminated unexpectedly during startup
[!] Component  = Machine, Interface: IMachine, {ea6fb7ea-1993-4642-b113-f29eb39e0df0}
[!] Callee      = <NULL>, {00000000-0000-0000-0000-000000000000}

so i go type /etc/init.d/rc.vboxdrv setup, it looks like everything went ok
Code:

root@slax:~# /etc/init.d/rc.vb
rc.vboxdrv    rc.vboxkermod
root@slax:~# /etc/init.d/rc.vboxdrv setup
groupadd: group vboxusers exists
Stopping VirtualBox kernel module ...done.
Removing old VirtualBox netflt kernel module ...done.
Removing old VirtualBox kernel module ...done.
Recompiling VirtualBox kernel module ...done.
Starting VirtualBox kernel module ...done.

but then i just get the same error w/o the kernel message
Code:

root@slax:~# VBoxManage startvm XP
VirtualBox Command Line Management Interface Version 2.1.4_OSE
(C) 2005-2009 Sun Microsystems, Inc.
All rights reserved.

Waiting for the remote session to open...
[!] Full error info present: true , basic error info present: true
[!] Result Code = NS_ERROR_FAILURE (0x80004005) - Operation failed
[!] Text        = Virtual machine 'XP' has terminated unexpectedly during startup
[!] Component  = Machine, Interface: IMachine, {ea6fb7ea-1993-4642-b113-f29eb39e0df0}
[!] Callee      = <NULL>, {00000000-0000-0000-0000-000000000000}

Sorry i didnt reply sooner, i had inet problems. Anyone know whats going on ? I'm kinda confused about the slax "modules" I think i might be missing one or something i installed the vbox ose one.

EDIT: I installed "Virtualbox 3.0.4 (s6.1.2)" module and now it works fine, even the gui. I did have to run the "/etc/init.d/rc.vboxdrv setup" again.
It all works ! its ok in the speed category, well its better than ok its fast, but i am running it on a pretty nice machine (mine). I'll try and speed it up.
I guess this is about as close as it gets to doing what i want to do, if it works at the school computers i'll have to get a bigger usb drive because some of the programs i need are like 4 gig by themselves.
I wonder if there is any way to run just a X gui like xcfe or something to use even less system resources.

Oh well thanks for the help !

markush 08-21-2009 11:50 AM

Hello zonemikel,

nice to read that it worked.

There is fluxbox available as a slax-module. Fluxbox uses much less of your system recources than kde does.

Markus

zonemikel 08-21-2009 11:30 PM

Quote:

Originally Posted by markush (Post 3652614)
Hello zonemikel,

nice to read that it worked.

There is fluxbox available as a slax-module. Fluxbox uses much less of your system recources than kde does.

Markus

Ya i ended up using xfce, i couldnt get fluxbox to work it kept saying something about how it could not find a window or something.

I actually got it to load slax into the memory and use xfce, then i can load my virtual machine. Windows is lightning fast ! I just edited the /boot/slax.cfg and copied the line for the "copy to ram" option, then i added "startxfce4" to the "autoexec" option. I also added the changes option so it saves changes in the "load to ram" part.

I just ordered a 16gig usb for about $15. Looks like it will work out pretty well.

I might have some trouble connecting to school printers but other than that it looks like it will work out just as i wanted it to.

thanks for all the help

markush 08-22-2009 12:00 AM

Quote:

Originally Posted by zonemikel (Post 3653202)
I might have some trouble connecting to school printers but other than that it looks like it will work out just as i wanted it to.

No, I don't think so. If youre school-network runs a DHCP-server and your virtual winxp machine uses connection-sharing it will get an ip-configuration in the network and becomes a normal Windowsclient in the network (in the scope of TCP/IP, but not a member of the domain in the microsoft-sense). If there are networkprinters you should be able to connect to them, maybe you'll have to authenticate with your logindata of the windows-network to connect to the printer.

Markus


All times are GMT -5. The time now is 02:51 PM.