Running partimage from an Ubuntu LiveCD

Filed under: TechNotes, Data Recovery — lars @ 06:18:29 pm

After spending a lot of time setting up my new Vista x64 install just the way I like it, I decided it would be a good idea to make a backup image of the boot partition so I could restore it in case something goes horribly wrong in the future.

I didn't realise that, although partimage is not included as a pre-installed application on the Ubuntu 8.04 LiveCD, that you can install it whilst running the LiveCD without actually needing to install Ubuntu to your hard drive.

The steps are as follows:

  1. Boot from Ubuntu 8.04 LiveCD (I recommend 32-bit - partimage gave me segmentation fault errors using the 64-bit version)
  2. Run Synaptic Package Manager.  Go to Settings - > Repositories -> select 'Community-maintained Open Source software', then click Close, then Reload.
  3. Open a terminal (from the Accessories menu)
  4. Run the following:
    sudo apt-get update
    sudo apt-get install partimage
  5. At this point I recommend running the Partition Editor from the System -> Administration menu.  It's a good way of checking which partition it is that you want to back up.  eg: /dev/sda1
  6. Then I go to the Places menu and select from the list the partition I want to write the image to.  This will automatically mount this partition, as well as open it in a Nautilus window (which I close).  If you don't have space on your PC you might want to manually mount a samba share (or some other network storage) a this point (see steps in section below).
  7. If you then return to your terminal and run:
    cd /media
    ls -l
    you should see your destination partition mounted there.  Keep this in mind, as you will need to know this path later (eg: /media/mydisk)
  8. Then run
    sudo partimage
    from the terminal.  This will launch partimage's UI in the terminal window.  It should be pretty self explanatory from here how you back up or restore a partition - but if you want more help there's a decent guide here.


Update: Dec 06, 2008

Using partimage with SMB

Often you will want to use partimage to backup or restore your partition to an SMB/windows network share, as you don't always have space on your local PC on which to store your partition backup.  To do this, there are some additional steps to enable mounting of the share:

  1. From the terminal, run:
    sudo apt-get install smbfs
  2. Then to mount this network share so that it is part of the filesystem:
    cd /media
    sudo mkdir myNetworkShare
    sudo smbmount //192.168.0.2/shareName /media/myNetworkShare -o username=teddy,password=badbear
    You should now be able to access the files on your network share under /media/myNetworkShare, and can select a location under here to create/restore your partition backup.

Comments

No Comments for this post yet...

    Leave a comment

    Allowed XHTML tags: <p, ul, ol, li, dl, dt, dd, address, blockquote, ins, del, span, bdo, br, em, strong, dfn, code, samp, kdb, var, cite, abbr, acronym, q, sub, sup, tt, i, b, big, small>


    Options:
    (Line breaks become <br />)
    (Set cookies for name, email & url)




    powered by  b2evolution