Creating an usb-stick of the current system

Discussion in 'Linux' started by Monkey, Jul 23, 2008.

  1. Monkey

    rbil

    Joined:
    Aug 14, 2008
    Messages:
    730
    Likes Received:
    0
    Location:
    The Wet Coast, Canada
    Howto: make the backup script load automatically when you boot up your flash key:

    With the flash key in your Aspire, go to the first partition on the flash key. That's the partition that contains all the Linux files.

    Using Mousepad, create a file called: autorun
    that contains:

    Code:
    #!/bin/bash
    
    echo Loading Backup script ...
    cd /mnt/cdrom
    ./backup
    
    Save the file to that Linux partition on the flash key. Using the file manager set this file as executable, by right clicking on it, clicking "Properties", "Permissions" tab, and then check "Allow this file to run as a program".

    When you boot the flash key in the future, the backup script will automatically run, so you just need to hit 1. to backup or 2. to restore. Couldn't be easier. :)

    Cheers.
     
    rbil, Oct 5, 2008
    #41
  2. Monkey

    Guest Guest

    I tried it and it did not work. I kept on getting Error -2, probably boot sector error. :-(
     
    Guest, Oct 6, 2008
    #42
  3. Monkey

    pjbarnoy

    Joined:
    Aug 26, 2008
    Messages:
    5
    Likes Received:
    0
    I'm trying to backup my SSD to a 4GB flash drive using Damn Small Linux running off of the same drive. It's been running for well over an hour and it's still not done. The partition I'm copying the disk to is ~3.7GB, formatted as ext3.

    This is basically what I did (after mounting the partition on my flash drive, creating directories, etc.):
    Code:
    dd if=/dev/hdc bs=4k | gzip > /media/sda2/Backup/hdimage.gz
    where /dev/hdc is my AAO's SSD, and /media/sda2 is where I mounted the flash drive.

    Any ideas as to what's taking so long? I disabled the GUI in DSL so I can't open up another terminal to check out what's going on (as far as I know).

    The blue light on my flash drive has been blinking most of the time. Maybe I should load DSL into RAM on boot, so nothing's conflicting. Can it read and write at the same time?

    EDIT: I had to cancel the backup for now. It was just taking too long... longer than I thought it should; and I had to go somewhere. But what should I do next time I try? I have an external hard drive I could try to back it up to.

    EDIT 2: I checked the hdimage.gz that I cancelled, and it was up to ~2GB. I don't know if that means it was almost done, or halfway done, or whatever. It still took much longer than everyone else has been reporting. Is there some way to accurately check the speed of my flash drive?
     
    pjbarnoy, Oct 7, 2008
    #43
  4. Monkey

    rbil

    Joined:
    Aug 14, 2008
    Messages:
    730
    Likes Received:
    0
    Location:
    The Wet Coast, Canada
    I don't think it's recommended to have a flash key be formatted ext3, as that is a journaled file system, causing it to write too frequently to the drive with the potential of wearing it out sooner. An ext2 format is a better idea, as it is not a journaled filesystem.

    Whether that is causing it to be so slow, I don't know? The backup system that I use uses a sysrescuecd image to run the backups. To backup my SSD drive, it takes around 20 minutes max. My system writes to a FAT32 partition on the flash drive. Then again, only 3.0G of the SSD drive is used in sda1 and the swap partition is the standard 1GB in size. The sysrescuecd is pretty stripped down and my backup script runs from the command prompt before startx is run.

    Cheers.
     
    rbil, Oct 7, 2008
    #44
  5. Monkey

    ste

    Joined:
    Oct 4, 2008
    Messages:
    19
    Likes Received:
    0
    Hello!
    I have a Kingston data traveler 2gb. I have read all post above but I my pen-drive is only 2gb. Is it possible create a bootable image of my actual system anyway?

    I try to do it with Mondorescue, specially with Mindi but I have got some problem, please see below, last post.
    viewtopic.php?f=23&t=4587


    Please help me!
     
    ste, Oct 7, 2008
    #45
  6. Monkey

    rbil

    Joined:
    Aug 14, 2008
    Messages:
    730
    Likes Received:
    0
    Location:
    The Wet Coast, Canada
    If you've followed this thread and are thinking that you want to have a bootable flash key for backing up your SSD drive to itself, then a 2GB flash key will not be large enough. You'll need as a minimum a 4GB flash key. Around here, they sell for under $10 (on sale), and is really low insurance to know you can easily backup and restore your AAO's main drive.

    Cheers.
     
    rbil, Oct 7, 2008
    #46
  7. Monkey

    pjbarnoy

    Joined:
    Aug 26, 2008
    Messages:
    5
    Likes Received:
    0
    Later I'll try formatting the flash drive as ext2 and maybe run DSL from a different drive.
     
    pjbarnoy, Oct 7, 2008
    #47
  8. Monkey

    callaghan

    Joined:
    Sep 27, 2008
    Messages:
    18
    Likes Received:
    0
    Re: A Script To Make Backup/Restores Easier on the 4GB Flash Key

    Hi forum!

    I purchased an AAO A110 (linpus version).
    As written in other topics, i have lost the linpus os due to an integral SSD drive format.

    I can't restore the linpus os using the original dvd (or restore usb key) because the restore process is looking for
    the MBR partition in order to complete.

    I think that this topic could help me.

    If i have understood correctly, having an SSD drive image backup, and following tre described process, i can try
    restore my AAO to the original version.

    Could you please provide me an SSD drive image backup?

    Could you please help me?

    Thank you very much.

    Cheers.
     
    callaghan, Oct 9, 2008
    #48
  9. Monkey

    rbil

    Joined:
    Aug 14, 2008
    Messages:
    730
    Likes Received:
    0
    Location:
    The Wet Coast, Canada
    Do you just require the MBR from a Linpus SSD disk?

    Cheers.
     
    rbil, Oct 9, 2008
    #49
  10. Monkey

    callaghan

    Joined:
    Sep 27, 2008
    Messages:
    18
    Likes Received:
    0
    Hi!

    I hope it!

    What's your advice?

    Thanks,
    A.
     
    callaghan, Oct 9, 2008
    #50
  11. Monkey

    rbil

    Joined:
    Aug 14, 2008
    Messages:
    730
    Likes Received:
    0
    Location:
    The Wet Coast, Canada
    If I was to provide you with an image of the MBR from my Linpus SSD disk, do you have the means to copy it over on to your SSD disk? You would need to boot some sort of Linux livecd from a flash key to do this.

    Cheers.
     
    rbil, Oct 9, 2008
    #51
  12. Monkey

    rbil

    Joined:
    Aug 14, 2008
    Messages:
    730
    Likes Received:
    0
    Location:
    The Wet Coast, Canada
    I've never used the DVD restore system that comes with the Aspire One, because I never wanted to have to get back to square one should problems arise. Hence the effort to create a backup solution. Are you suggesting that if the MBR is corrupted on the SSD, then Acer's recovery system won't work? I would have thought the recovery would write everything to the SSD - MBR, ext2 partition and the swap partition.

    Cheers.
     
    rbil, Oct 9, 2008
    #52
  13. Monkey

    callaghan

    Joined:
    Sep 27, 2008
    Messages:
    18
    Likes Received:
    0
    If I was to provide you with an image of the MBR from my Linpus SSD disk,
    do you have the means to copy it over on to your SSD disk?
    You would need to boot some sort of Linux livecd from a flash key to do this.

    Yes, this is i'd like to do.
    I can boot my AAO with kubuntu using an usb key. Using kubuntu i would like to restore the SSD disk!
    I think that could be enough to restore only the MBR partition, because after this i hope to restore the SSD using
    the original recovery DVD (via usk stick).

    It would be even better to have a complete image of the SSD. Have you an image not customised?

    Do you think that this works?

    Thanks in advance!
    A.
     
    callaghan, Oct 9, 2008
    #53
  14. Monkey

    callaghan

    Joined:
    Sep 27, 2008
    Messages:
    18
    Likes Received:
    0
    I've never used the DVD restore system that comes with the Aspire One,
    because I never wanted to have to get back to square one should problems arise.
    Hence the effort to create a backup solution. Are you suggesting that if the MBR is corrupted on the SSD,
    then Acer's recovery system won't work?

    I think it! It is the only explanation that i have thought...

    Cheers,
    C.
     
    callaghan, Oct 9, 2008
    #54
  15. Monkey

    rbil

    Joined:
    Aug 14, 2008
    Messages:
    730
    Likes Received:
    0
    Location:
    The Wet Coast, Canada
    It wouldn't make sense to me that Acer's recovery system wouldn't write the MBR. But, who knows with Acer? I don't know what to advise you. Maybe someone who has actually done a recovery can advise you.

    Cheers.
     
    rbil, Oct 9, 2008
    #55
  16. Monkey

    callaghan

    Joined:
    Sep 27, 2008
    Messages:
    18
    Likes Received:
    0
    I wold like to try...

    Could you please provide me a working image?

    Thanks,
    A.
     
    callaghan, Oct 9, 2008
    #56
  17. Monkey

    rbil

    Joined:
    Aug 14, 2008
    Messages:
    730
    Likes Received:
    0
    Location:
    The Wet Coast, Canada
    callaghan,

    If you go to my blog (see sig at bottom) you can download a copy of my MBR.

    Cheers.
     
    rbil, Oct 10, 2008
    #57
  18. Monkey

    callaghan

    Joined:
    Sep 27, 2008
    Messages:
    18
    Likes Received:
    0
    Thank you so much rbill!

    I'll try it!

    Using your backup script whick one option i need to use in order to restore your MBR partition?

    1) Backup
    6) SD_Card_Restore

    1) or 6) option?

    Thanks,
    A.
     
    callaghan, Oct 10, 2008
    #58
  19. Monkey

    rbil

    Joined:
    Aug 14, 2008
    Messages:
    730
    Likes Received:
    0
    Location:
    The Wet Coast, Canada
    Neither! Not unless you've backed up your SSD BEFORE you had problems. I'm getting the impression that you're really confused and until you get clarification, shouldn't proceed with anything.

    Cheers.
     
    rbil, Oct 10, 2008
    #59
  20. Monkey

    callaghan

    Joined:
    Sep 27, 2008
    Messages:
    18
    Likes Received:
    0
    Hi rbill,

    sure! I'm really confused... ;-)

    This is what i'd like to try in order to restore with Linpus my corrupted AAO:

    1) Check about my AAO partions. I need to have the same original partitions (MBR, ext2, swap).

    2) Boot my AAO using Kububtu on a usb key.

    3) Burn the 4gbrestoreimage.gz image in a 8gb usk key.

    4) Placing the Backup Script on the burned usb key.

    5) Boot from the external usb key running the Backup/Restore script.

    6a, first option) Restore the MBR partition (i can't do this using the script?) using the Backup/Restore script.

    7a) Restore the Linpus os using the original process (i think that having the correct MBR partition, this could work's fine).

    6, second option) Otherwise (not 6a), restore a bull backup using the Backup/Restore script.

    It makes sense?

    Cheers,
    C.
     
    callaghan, Oct 10, 2008
    #60
Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.