Wednesday, June 2, 2010

Koha Live CD to USB

We had no problem creating a bootable live USB stick from the Koha Live CD using the ubuntu make bootable usb disk option but a lot of the students were unable to get their bootable usb stick to boot - 'boot error' was the result.

I use standard no frills kingston datatraveller usb sticks as i have found them a reliable cross-platform device. It may be possible that some usb sticks are not bootable?

We decide to remove the ubuntu usb install as a factor - and to use unetbootin to create the bootable usb from the koha live CD ISO image.

We downland unetbootin-windows-442.exe and run it. Nice that it does not have to be installed.

  1. Select Diskimage radio button and browse for the koha live cd ISO on S:
  2. Select the USB Drive (F:)
  3. Click OK

It extracts the files from the iso and installs the bootloader. Very fast. I wonder if it worked on the test stick. We put the stick in another machine and reboot. No joy - didn't think so as this stick had the same behavior as the others that failed, when trying to re-format in windows it returned error of 'you do not have administrative rights, disk cannot be formatted'. This stick had been formatted as FAT on an osx machine like the other one that did not work.

We will wipe this stick and try unetbootin with some other ones.

Update: The key symptom of sticks that do not work is that when you put the stick in a Windows pc and try to format it, it says 'you do not have administrative rights....'. I am wondering if sticks formatted under Ubuntu or OSX have this issue. I can't remember if if formatted the 2 working sticks.

As a test we insert a non-working stick and format it as FAT under ubuntu. Once formatted we put it in a windows machine and try to format it again...

YES - that is the problem, if the stick is formatted on the Ubuntu box it then cannot be formatted on a windows box. And if it is formatted on Ubuntu it returns a boot error.

Ok - we go into the disk utility and delete the partition. Now we plug the stick into a windows machine. It is not formatted but we still get 'you do not have sufficient rights to perform this operation'

Back to Ubuntu - we create a FAT partition and format it as FAT but do not check the bootable checkbox. We run the USB startup disk creator and select the USB device (/dev/sdb1) and reserve 1gig for a persistence file. No joy - it must be bootable and cannot be formatted on Ubuntu.

The current theory is that sticks not formatted on Ubuntu should work...and sticks formatted on ubuntu may work on other machines but not in the GRC...arrgh

Update - confirmed. We created a kingston stick in the GRC using format and install to USB and it did not boot the GRC computer but booted my laptop fine. We don't have a solution to the problem except to remove the format part of the instructions and to see if that works. This means we need some more sticks...

Tuesday, June 1, 2010

iGoogle

I've been using iGoogle more and more and today made the decision to make it my home page. This meant making firefox on the macs the default web browser instead of safari, which is no problem as i've been using google toolbar which does not run on safari. This means no matter which desktop in the house i go to (windows, linux or mac) i have access to my calendar, to do list, google docs, rss feeds - all in the same place, and when i am mobile with either the mac pro laptop, the windows laptop or the linux laptop i still have access to the same stuff. Excellent!

USB to a Disk Image

Everyone talks about burning a disk image to a USB but i want to make a disk image OF a USB. My first attempt was winimage portable but no joy. Next we download the latest version of winimage and install it on the HP laptop. Here are the steps we took

  1. Select Disk, Use Removable Disk E: which is our usb stick.
  2. Select, Disk, Creating Virtual Disk Image from physical drive
  3. The dialog box displays Disk 1: 7,831,552 kb Kingston DataTraveller 2.0
  4. Select the Kingston USB entry and choose the create Fixed Sized Virtual Hard Disk
  5. Click OK
  6. We choose a save location and name it koha_usb

The question now is what format - there is .VHD (virtual hard disk) which is a windows format, of little interest to us, and .IMA which is a generic image format, and .VDMK which is a VMware image. Since the lab computers have VMWARE player installed the VDMK may be useful. We had problems trying to use VMplayer several terms ago but maybe we give it a second chance. I'd like to have a format that can then be burned to a USB stick. MagicISO can convert ima files to ISO so we decide to make 2 images, an IMA to be converted to ISO and a VDMK. We start the VDMK imaging process, it takes about 7 minutes. Would be useful if it had a virtualbox image option.

Now that we have images we need to:

- test with VMware player (copy images to 9762 on S: and see if can run)
- convert IMA to ISO and burn ISO to USB and test booting the USB

We install and run MagicISO -the free version is limited to 300mb images so this is no good. Let's test it out anyway - it finds the koha_usb.ima image ok. but can't open it - complaining it is not an image file.

Let's try vmware - we download from their site after filling in one of those annoying marketing forms for registration (we select the first choice on all the menus so the data is garbage anyway)

Ok we got the download - let's install. We then run VMware player and select Open a Virtual Machine but it wants a .VMX file and does not see the VDMK image. We can't create a machine as it wants an ISO file.

Ok the other option is to make an ISO out of the libliveCD and then run the ISO as a virtual machine. Ok so now we have kohalivecd.iso on the S: drive in the 9762 folder. Virtualbox (v 3.16) is installed so we:

  1. Select start, programs, Sun Virtualbox, Virtualbox
  2. Click NEW, NEXT
  3. Enter KohaLive in the Name textbox
  4. Select Linux as the Operating System and Ubuntu as the version
  5. Click Next
  6. Set the Memory Size slider to 1024
  7. Click NEXT
  8. Untick the Boot Hard Disk checkbox
  9. Click NEXT, CONTINUE and FINISH

Now we have to start up the empty VM and let it know to use our ISO file.

  1. Click START and then click OK
  2. Click Devices, CD/DVD Devices, More CD/DVD Images
  3. Click ADD
  4. Browse to S:\local\courses\mlis\9762
  5. Select the KOHAliveCD.iso file and click OPEN
  6. Click SELECT
  7. Select Machine, Reset
  8. Click on the window and click CAPTURE

This positions your mouse and keyboard into the guest virtual machine operating system. To return to the windows host operating system press the right CTRL key.

Success! The liveCD boots ok. To shut down click the Ubuntu power icon and select shutdown. When you exit virtualbox be sure to SAVE the Machine State so that changes are preserved.

We did the following:

  1. Select System, Admin, Software Sources
  2. Select other Software
  3. Select karmic partner
  4. Select System, Administration, Synaptic
  5. Search for Restricted
  6. Mark - Select for Installation
  7. Click Apply
It was good the VM picked up the network adapter and USB devices automatically. Virtualbox has come a long way since the early days.

Now we need to shut down the virtual machine and SAVE it's state and then restart to see if our changes are preserved.

More 2morO