Page 60 of 138 FirstFirst ... 1050585960616270110 ... LastLast
Results 591 to 600 of 1375

Thread: Howto: Backup and restore your system!

  1. #591
    Join Date
    Mar 2006
    Beans
    379
    Distro
    Ubuntu 9.04 Jaunty Jackalope

    Re: Howto: Backup and restore your system!

    Would this be the ideal procedure to use if I wanted to switch from Hardy over to Gutsy (or another version of Ubuntu or Linux)?

  2. #592
    Join Date
    Jun 2008
    Beans
    3
    Distro
    Kubuntu 8.04 Hardy Heron

    Re: Howto: Backup and restore your system!

    Sorry, when I wrote "earlier version" I meant an earlier version of my own installation. If I foul something up on my system now, I don't know enough to sort things out then clean up again. My way round it is to back the system up before any serious experiment, then restore it if I goof big time.

    If you want to try some other distro on your machine as well as Hardy, dual installation / boot menu is probably the way to do it. That way you have both on your machine and choose which one to run during boot up. That isn't a backup-restore procedure though, it's a fresh install of the second system. I'm a beginner here but I'm sure that there will be another thread in this forum dealing with this technique.

    If you are going to try this though, it's another good reason to keep your personal stuff (photos, music, mail, videos etc.) on a separate partition, to make it easier to get at from either distro. Also you won't have a synchronisation problem (ending up with say, your music downloads in two different places).

    Some applications will even let you put the configuration files on your data disk. Thunderbird mail client for instance will let you put your whole profile on it (mail files, address book, accounts, server settings etc.). Then, if you just do a basic install on your new distro you can point it to your central profile using its profilemanager service.

    Finally, there is less chance of losing separate data if the dual boot goes wrong and you have difficulty starting your original Hardy installation.

  3. #593
    Join Date
    Jun 2007
    Location
    In Hungary
    Beans
    62
    Distro
    Ubuntu 8.04 Hardy Heron

    Re: Howto: Backup and restore your system!

    Quote Originally Posted by Heliode View Post
    Ok, there's a lot of questions in there, I'll try to answer them one by one.

    1: The howto on the first page is what I use and what works for me. I've used it to backup several systems and it worked every time for me
    2: If you want to have a backup of /home, just cd to / and run the correct command. In your case probably something like this:
    Code:
    # cd /
    # sudo tar cvpfz homebak.tgz /home
    If you want to backup /, just cd to /home and run the regular backup command, but this time exclude /home since it is on a seperate partition. This would make the commands look something like this:
    Code:
    # cd /home
    # tar cvpfz backup.tgz / --exclude=/proc --exclude=/lost+found --exclude=/backup.tgz --exclude=/mnt --exclude=/sys --exclude=/home
    If you want to restore just the backup of the homedir, you would need something like this:
    Code:
    # cd /
    # tar xvpfz backup.tgz -C /home
    Be careful though: If you have a backup of / in your home-dir, it'll be overwritten when you restore your home-dir. (unless, of course, it is included in the archive but that wouldn't be very space-efficient )

    The best would be to store the backup of /home on the / partition, and store the backup of the / partition on another machine or burn it to DVD or whatever.

    As far as I know, it is possible to restore / on a running system. I've never tried it before but since it is also possible to erase everything in / on a running system, I figure why not! I'm gonna need some confermation here though.
    Of course you could always just use a live-cd. Usually when you have to restore /, you don't have an option anyway!

    Hope this helps!
    Yes it did, many thanks Heliode for this and previous.

  4. #594
    Join Date
    Jan 2008
    Location
    Davison, Michigan, U.S.A.
    Beans
    1,037

    Re: Howto: Backup and restore your system!

    I did the backup using the instructions in post #1. At the end of the process I did get the error 'tar: Error exit delayed from previous errors' which is said to be nothing to worry about.

    Now I did the restore. This was my output:

    Code:
    daryl@ubuntu:~$ sudo su
    root@ubuntu:/home/daryl# cd /
    root@ubuntu:/# tar xvpfz backup.tgz -C /
    
    gzip: stdin: not in gzip format
    tar: Child returned status 1
    tar: Error exit delayed from previous errors
    What happened?


    EDIT::

    So I decided to try restoring with a livecd since, like someone said, "Theres a good chance you won't be able to boot anyway, if you are needing to restore your system". I was unsuccessful here also because you can not access your file system with a live cd, just the file system on the cd.

    Or am I missing something?
    Last edited by sofasurfer; June 23rd, 2008 at 09:38 AM.

  5. #595
    Join Date
    May 2006
    Location
    Switzerland
    Beans
    2,541
    Distro
    Ubuntu 12.04 Precise Pangolin

    Re: Howto: Backup and restore your system!

    Quote Originally Posted by sofasurfer View Post
    root@ubuntu:/# tar xvpfz backup.tgz -C /

    gzip: stdin: not in gzip format
    tar: Child returned status 1
    tar: Error exit delayed from previous errors[/code]
    Please execute the "file" command on that file! e.g.
    Code:
    file /path/to/backup.tgz
    ... I'd like to see what this file is. Chances are you used different parameters when you created the file and the file might indeed not be gzip packed.

    Example from here:
    Code:
    > file vodafone.tar.gz 
    vodafone.tar.gz: gzip compressed data, from Unix, last modified: Mon Jun 23 13:35:26 2008
    Can you do that please? It would be interesting to know what kind of file we're dealing with.

    Quote Originally Posted by sofasurfer View Post
    I was unsuccessful here also because you can not access your file system with a live cd, just the file system on the cd.
    You are misinformed. Unless your harddisks require some really exotic driver (e.g. fibre channel storage driver??) it should be possible to access them from a live CD too. People have been doing this for ages now.

    Once you're in a live CD environment, please issue this command:
    Code:
    sudo fdisk -l
    ... this should list all harddisk partitions that were detected, live CD or not. Example from here:
    Code:
    # fdisk -l
    
    Disk /dev/sda: 146.6 GB, 146684248064 bytes
    255 heads, 63 sectors/track, 17833 cylinders
    Units = cylinders of 16065 * 512 = 8225280 bytes
    Disk identifier: 0xdaa138b9
    
       Device Boot      Start         End      Blocks   Id  System
    /dev/sda1   *           1          16      128488+  83  Linux
    /dev/sda2              17       17833   143115052+   5  Extended
    /dev/sda5              17         259     1951866   83  Linux
    /dev/sda6             260         988     5855661   83  Linux
    /dev/sda7             989        1231     1951866   83  Linux
    /dev/sda8            1232        9012    62500851   83  Linux
    /dev/sda9            9013       16793    62500851   83  Linux
    /dev/sda10          16794       17036     1951866   83  Linux
    /dev/sda11          17037       17833     6401871   83  Linux
    
    Disk /dev/sdb: 64.4 GB, 64424509440 bytes
    64 heads, 32 sectors/track, 61440 cylinders
    Units = cylinders of 2048 * 512 = 1048576 bytes
    Disk identifier: 0x00000000
    
       Device Boot      Start         End      Blocks   Id  System
    /dev/sdb1   *           1       61440    62914544   83  Linux
    
    Disk /dev/sdc: 32.2 GB, 32212254720 bytes
    64 heads, 32 sectors/track, 30720 cylinders
    Units = cylinders of 2048 * 512 = 1048576 bytes
    Disk identifier: 0x00000000
    
       Device Boot      Start         End      Blocks   Id  System
    /dev/sdc1               1       30720    31457264   83  Linux
    
    Disk /dev/sdd: 32.2 GB, 32212254720 bytes
    64 heads, 32 sectors/track, 30720 cylinders
    Units = cylinders of 2048 * 512 = 1048576 bytes
    Disk identifier: 0x00000000
    
       Device Boot      Start         End      Blocks   Id  System
    /dev/sdd1               1       30720    31457264   83  Linux
    
    Disk /dev/sde: 53.6 GB, 53687091200 bytes
    64 heads, 32 sectors/track, 51200 cylinders
    Units = cylinders of 2048 * 512 = 1048576 bytes
    Disk identifier: 0x00000000
    
       Device Boot      Start         End      Blocks   Id  System
    /dev/sde1               1       51200    52428784   83  Linux
    Also take a look at the output of this command:
    Code:
    dmesg
    ... The output of that one will be very long and it will mention all kind of things. It should also mention what harddisks have been detected during system boot. Example from here (edited: many lines removed):
    Code:
    [  151.192646] scsi3 : ata_piix
    [  151.192782] scsi4 : ata_piix
    [  151.193725] ata1: PATA max UDMA/100 cmd 0x1f0 ctl 0x3f6 bmdma 0xfff0 irq 14
    [  151.193811] ata2: PATA max UDMA/100 cmd 0x170 ctl 0x376 bmdma 0xfff8 irq 15
    [  151.531027] ata_piix 0000:00:1f.2: MAP [ P0 P2 P1 P3 ]
    [  151.531298] ACPI: PCI Interrupt 0000:00:1f.2[B] -> GSI 21 (level, low) -> IRQ 21
    [  151.531473] PCI: Setting latency timer of device 0000:00:1f.2 to 64
    [  151.531531] scsi5 : ata_piix
    [  151.531651] scsi6 : ata_piix
    [  151.531759] ata3: SATA max UDMA/133 cmd 0xec00 ctl 0xe800 bmdma 0xdc00 irq 21
    [  151.531845] ata4: SATA max UDMA/133 cmd 0xe400 ctl 0xe000 bmdma 0xdc08 irq 21
    [  152.095564] scsi 2:0:0:0: Direct-Access     SUN      LCSM100_F        0670 PQ: 1 ANSI: 5
    [  152.102526] scsi 2:0:0:10: Direct-Access     SUN      LCSM100_F        0670 PQ: 0 ANSI: 5
    [  152.103152] scsi 2:0:0:11: Direct-Access     SUN      LCSM100_F        0670 PQ: 0 ANSI: 5
    [  152.103756] scsi 2:0:0:12: Direct-Access     SUN      LCSM100_F        0670 PQ: 0 ANSI: 5
    [  152.104324] scsi 2:0:0:13: Direct-Access     SUN      LCSM100_F        0670 PQ: 0 ANSI: 5
    [  154.654363] XFS mounting filesystem sda9
    [  154.791516] Ending clean XFS mount for filesystem: sda9
    [  154.848755] XFS mounting filesystem sda7
    [  154.882792] Ending clean XFS mount for filesystem: sda7
    [  154.939226] XFS mounting filesystem sda8
    [  154.998981] Ending clean XFS mount for filesystem: sda8
    [  155.067625] XFS mounting filesystem sda11
    [  155.141243] Ending clean XFS mount for filesystem: sda11
    [  155.196037] XFS mounting filesystem sda6
    [  155.271758] Ending clean XFS mount for filesystem: sda6
    [  155.330263] XFS mounting filesystem sda10
    [  155.395941] Ending clean XFS mount for filesystem: sda10
    [  156.748189] scsi 2:0:0:0: Attached scsi generic sg4 type 0
    [  156.749640] sd 2:0:0:10: [sdb] 125829120 512-byte hardware sectors (64425 MB)
    [  156.749792] sd 2:0:0:10: [sdb] Write Protect is off
    [  156.749794] sd 2:0:0:10: [sdb] Mode Sense: 77 00 10 08
    [  156.750070] sd 2:0:0:10: [sdb] Write cache: enabled, read cache: enabled, supports DPO and FUA
    [  156.750905] sd 2:0:0:10: [sdb] 125829120 512-byte hardware sectors (64425 MB)
    [  156.751053] sd 2:0:0:10: [sdb] Write Protect is off
    [  156.751056] sd 2:0:0:10: [sdb] Mode Sense: 77 00 10 08
    [  156.751320] sd 2:0:0:10: [sdb] Write cache: enabled, read cache: enabled, supports DPO and FUA
    [  156.751325]  sdb: sdb1
    [  156.755580] sd 2:0:0:10: [sdb] Attached SCSI disk
    [  156.755626] sd 2:0:0:10: Attached scsi generic sg5 type 0
    [  156.756994] sd 2:0:0:11: [sdc] 62914560 512-byte hardware sectors (32212 MB)
    [  156.757140] sd 2:0:0:11: [sdc] Write Protect is off
    [  156.757142] sd 2:0:0:11: [sdc] Mode Sense: 77 00 10 08
    [  156.757403] sd 2:0:0:11: [sdc] Write cache: enabled, read cache: enabled, supports DPO and FUA
    [  156.758237] sd 2:0:0:11: [sdc] 62914560 512-byte hardware sectors (32212 MB)
    [  156.758388] sd 2:0:0:11: [sdc] Write Protect is off
    [  156.758390] sd 2:0:0:11: [sdc] Mode Sense: 77 00 10 08
    [  156.758651] sd 2:0:0:11: [sdc] Write cache: enabled, read cache: enabled, supports DPO and FUA
    [  156.758654]  sdc: sdc1
    [  156.765636] sd 2:0:0:11: [sdc] Attached SCSI disk
    [  156.765680] sd 2:0:0:11: Attached scsi generic sg6 type 0
    [  156.767734] sd 2:0:0:12: [sdd] 62914560 512-byte hardware sectors (32212 MB)
    [  156.767890] sd 2:0:0:12: [sdd] Write Protect is off
    [  156.767892] sd 2:0:0:12: [sdd] Mode Sense: 77 00 10 08
    [  156.768160] sd 2:0:0:12: [sdd] Write cache: enabled, read cache: enabled, supports DPO and FUA
    [  156.769150] sd 2:0:0:12: [sdd] 62914560 512-byte hardware sectors (32212 MB)
    [  156.769292] sd 2:0:0:12: [sdd] Write Protect is off
    [  156.769294] sd 2:0:0:12: [sdd] Mode Sense: 77 00 10 08
    [  156.769552] sd 2:0:0:12: [sdd] Write cache: enabled, read cache: enabled, supports DPO and FUA
    [  156.769555]  sdd: sdd1
    [  156.772804] sd 2:0:0:12: [sdd] Attached SCSI disk
    [  156.772838] sd 2:0:0:12: Attached scsi generic sg7 type 0
    [  156.774114] sd 2:0:0:13: [sde] 104857600 512-byte hardware sectors (53687 MB)
    [  156.774263] sd 2:0:0:13: [sde] Write Protect is off
    [  156.774264] sd 2:0:0:13: [sde] Mode Sense: 77 00 10 08
    [  156.774526] sd 2:0:0:13: [sde] Write cache: enabled, read cache: enabled, supports DPO and FUA
    [  156.775233] sd 2:0:0:13: [sde] 104857600 512-byte hardware sectors (53687 MB)
    [  156.775372] sd 2:0:0:13: [sde] Write Protect is off
    [  156.775374] sd 2:0:0:13: [sde] Mode Sense: 77 00 10 08
    [  156.775636] sd 2:0:0:13: [sde] Write cache: enabled, read cache: enabled, supports DPO and FUA
    [  156.775639]  sde: sde1
    [  156.782151] sd 2:0:0:13: [sde] Attached SCSI disk
    [  156.782183] sd 2:0:0:13: Attached scsi generic sg8 type 0
    Please check what "dmesg" has to say about your system. The harddisks should definitely be listed there, live CD or not.

  6. #596
    Join Date
    Jan 2008
    Location
    Davison, Michigan, U.S.A.
    Beans
    1,037

    Re: Howto: Backup and restore your system!

    Well, I ran to backup and restore commands one more time and it appears that it worked. But I am NOT able to access my file system with a live cd. I did a 'fdisk -l' while running the livecd and my drive was listed as /dev/sdb. It is actually /sda, and sdb is really my second drive. So I disconnected my second drive and then 'fdisk -l' showed my drive as /sda.

    It appeared that 'fdisk -l' showed my file system because the partition sizes looked the same. But I will go verify that in a minute by comparing the exact sizes.

    When I used the browser to access the file system under livecd I was only able to access the file system on the livecd. I know it was not my file system because there was a /home/ubuntu directory which my file system doed not have. And there was none of my info in the files.

    dmesg is a little hard for me to decipher but I will go and try again.

  7. #597
    Join Date
    Jun 2008
    Location
    Chicago, IL
    Beans
    301
    Distro
    Ubuntu 12.04 Precise Pangolin

    Smile Re: Howto: Backup and restore your system!

    Easiest way to backup and restore is to install sbackup. You can schedule, decide what to include and exclude, and even backup to an external device. It works great for doing full and or incremental backups.
    Mint 14 | 64bit | DT ACER VN281G | Intel® Atom™ CPU D425 @ 1.80GHz × 2 | Registered Linux User#458200

  8. #598
    Join Date
    Jan 2008
    Location
    Davison, Michigan, U.S.A.
    Beans
    1,037

    Re: Howto: Backup and restore your system!

    I ran dmesg under livecd and my hard drive IS listed as being 250 gig. But I did not see much more info than that. I then went to terminal and tried with NO LUCK to cd into my /home/daryl directory.

    Am I supposed to used a certain kind of livecd? I am using Ubuntu 8.04 livecd.

    EDIT::

    linux6694.
    sbackup is a good thing and I have tried it. But I and striving to learn how to do a disk image backup.

  9. #599
    Join Date
    May 2006
    Location
    Switzerland
    Beans
    2,541
    Distro
    Ubuntu 12.04 Precise Pangolin

    Re: Howto: Backup and restore your system!

    Quote Originally Posted by sofasurfer View Post
    But I am NOT able to access my file system with a live cd.
    You could maybe explain a little more about your system then, e.g. which drive is what, and then maybe post the output of the live CD's "fdisk -l" here? (assuming that you get an Internet connection with the live CD).

    Quote Originally Posted by sofasurfer View Post
    I did a 'fdisk -l' while running the livecd and my drive was listed as /dev/sdb.
    This doesn't have to mean much. Sometimes drives and their names get moved around, e.g. what you see as /dev/sdb might then be seen as /dev/sda in a Live CD session and vice versa.

    Quote Originally Posted by sofasurfer View Post
    When I used the browser to access the file system under livecd I was only able to access the file system on the livecd.
    I assume you didn't get any icons on the Live CD desktop showing your harddisk drives ....? Did you try to mount them manually?

    Quote Originally Posted by sofasurfer View Post
    dmesg is a little hard for me to decipher but I will go and try again.
    Just post it here

  10. #600
    Join Date
    Jan 2008
    Location
    Davison, Michigan, U.S.A.
    Beans
    1,037

    Re: Howto: Backup and restore your system!

    Can't do much now, as I'm at work.
    "Mount them manually"!! AHA!! I bet thats the answer. I will try that before I complain any more. Thanks.

Page 60 of 138 FirstFirst ... 1050585960616270110 ... LastLast

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •