Archive

Posts Tagged ‘virtual’

How to convert a VMWare vmdk appliance to VirtualBox vdi

March 22nd, 2009

There are loads of ready-built appliances for VMWare in .vmdk format but I use VirtualBox and there is never a release in .vdi form to be found. I’ve heard that virtualbox will run the vmware images… but is that true?

Yes you can run vmware drives in virtualbox. Here’s how…

Start Headless vbox on windows

October 2nd, 2008

I keep forgetting this simple little line to start a virtualbox so that it behaves like a remote server (ie without any windows and crap cluttering my display)

start /b vboxheadless -s myjeos

“start” is the windows command to start a process
“/b” tells start not to create a window for the process
“vboxheadless” is the process to start
“-s” tells vboxheadless to start a machine
“myjeos” is the name of the machine to start

VMWare vs VirtualPC vs VirtualBox

April 14th, 2008

As you may know I’ve recently discovered Virtual Machines. It all started with a LAMP Appliance on the VMWare Player. But you can’t create a windows machine with the player, so VirtualPC got a look. But then I heard VirtualBox can handle arbitrary screen sizes, so now that’s got a go too. Might be worth comparing and consolidating. All of them are running on Windows XP host.

It might only be because it’s got the most recent start but I’m liking VirtualBox at the moment. Here’s a summary:

VMWare Player (2.0.2)

+ strong community of freely available appliances – not to be underestimated
+ excellent portability – just copy one file around and edit an xml – easy snapshots
- won’t minimize to the system tray so machines pile up and my clutter desktop
- requires a group of services to run in the background (eg. vmware-authd)
- can’t create my own vm’s (Their idea is you buy vm workstation)

VirtualPC (6.0)

+ pretty GUI
+ collapses onto desktop nicely
- no community or appliances

VirtualBox (1.5.6)

+ pretty GUI
+ portable, just one file and an xml (but you need to ‘clone’ that file so not quite as easy vmware)
+ snapshot feature which reduces overall portability but is pretty handy for reseting the machine
+ can resize the screen to whatever size you like
- small community (just some linux distros, no appliances. But somehow I got the idea that they’re working toward vmware compatibility)

VMWare Rocks

February 22nd, 2008

I think vmware is fantastic. It allows me to spend vastly less time on indirect tasks – like setting up new development and testing environments – and more time getting the actual things that need to be done, done. Time consumed in getting all set up to do a piece of work quickly becomes like driving all the way to Dubbo just to go to the bathroom. It’s hard to explain to a client. VMWare, however, is a teleport.

Most people, I know, are happy to take a leak in their backyard; but I have great difficulty making icky compromises because I know that, before long, they’re the ones complaining about the smell. I’m always working to do things ‘right’. It’s more work, but it doesn’t smell. So having got this funky new website thing happening, I am now compelled to create an offline version. A place to fiddle, play, try things out. A place which is not production.

So what’s this got to do with vmware? Well, rather than waste hours building-running-administering a separate LAMP machine I’m using this to run the whole lot on my Windows workstation. Very sweet is that I don’t have to pollute it with other projects. Different projects always have different needs; needs which too often conflict and interfere. An apache tweak, a specific version of php, an unusual set of permissions, an special library or program or filter or configuration; there’s always something.

Now, with VM’s, need to do a project on the side? No problem: just fire up another VM. Start with a neatly preconfigured point and get on directly with the job. Do it ‘right’ for that project without compromise. Want to try something out when midstream? No problem: copy the VM and play with it, if it doesn’t work out, bin it. Now projects can sit in their own little VM worlds without interfering with each other. For example I decided to try out Textpattern in case I might like to switch to that. I fired up a new Virtual Appliances LAMP VM, installed it, played with it, ditched it. Took about an hour. Didn’t interfere with anything I’ve already got.

I can’t wait to introduce VM Test Database’s at my next gig. One of the bigger pains in the neck at jobs is getting together a large sample of test data which is realistic, restorable, and distributable. With a VM we can build a test database and rerun tests ad infinitum without having to painstakingly restore the test database to the start position. Need to run a bunch of tests without interfering with someone else? No problem – everyone can fire up copies of the test database VM on their own workstation without wasting hours installing and configuring.

So I’m quite pleased to be writing this on a development environment. I can edit, tweak, publish till the cows come home without messing up production. To deploy code changes I can run lftp‘s ‘mirror’ command. I don’t get direct access to the production database however (only phpmyadmin) so I have to push database updates by uploading and executing sql scripts; fortunately the database is very small, so I can export the whole thing from dev, and import to prod via a sql script.

Doing this, the WordPress database does have a couple of gotcha’s. For some reason they store the root url path inthe wp_options table (as well as in the wp_config.php!). So I have to omit this from every import. I’m also expecting some issues with attachments to posts as I see the wp_postmeta table holds full physical paths – and the dev and prod paths are different. I have a couple of ideas and will deal with this in time. I’ll let you know.