The Ubuntu system is backed up to the mobile hard drive (tar) and restored to another computer.

Source: Internet
Author: User

System Version: Ubuntu 13.04 32-bit

1. Open your mobile hard disk in the desktop environment

View disk drive: df-ah

Df (DiskFree) a represents all, and h Represents characters that human can understand. For details, see command df -- help.
Www.bkjia.com @ linux:/dev $ df-ah
File System capacity used available % mount point
/Dev/sda9 93G 8.9G 79G 11%/
Proc 0 0 0-/proc
Sysfs 0 0 0-/sys
None 4.0 K 0 4.0 K 0%/sys/fs/cgroup
None 0 0 0-/sys/fs/fuse/connections
None 0 0 0-/sys/kernel/debug
None 0 0 0-/sys/kernel/security
Udev 1.9G 4.0 K 1.9G 1%/dev
Devpts 0 0 0-/dev/pts
Tmpfs 386 M 888 K 386 M 1%/run
None 5.0 M 0 5.0 M 0%/run/lock
None 1.9G 156 K 1.9G 1%/run/shm
None 100 M 36 K 100 M 1%/run/user
Gvfsd-fuse 0 0 0-/run/user/ly/gvfs
/Dev/sdb5 222G 126G 97G 57%/media/ly/LY2
/Dev/sdb1 245G 175G 70G 72%/media/ly/LY1

I want to put the backup file in ly1. So remember the device sdb1

2. Start in command mode (refer to the link)


Command:


Sudo gedit/etc/default/grub

Find this line


GRUB_CMDLINE_LINUX_DEFAULT = "quiet splash"

Change

GRUB_CMDLINE_LINUX_DEFAULT = "quiet splash text"

Enter the following command:
Sudo update-grub

After the device is started, it automatically enters tty1.

Mount after login:
Www.bkjia.com @ linux:/dev $ sudo mount sdb1/media/ly

3. Use tar backup (refer to the link)

1) become the root user: sudo su


1-1) Change grub to desktop startup

Sudo vi/etc/default/grub

Find this line


GRUB_CMDLINE_LINUX_DEFAULT = "quiet splash text"

Change

GRUB_CMDLINE_LINUX_DEFAULT = "quiet splash"

Enter the following command:
Sudo update-grub


2) go to the root directory: cd/

3) tar-cvpjf/media/ly/ubuntu1304_bkp.tar.bz2 -- exclude =/proc -- exclude =/lost + found -- exclude =/mnt -- exclude =/sys -- exclude =/media/

..........

Wait patiently.

The system has been backed up.

Note:

1) tar backup can also be used without starting in command mode (directly go to the console ctrl + alt + F1), but an error will be reported at the end, saying ".... preview failure ...... "You cannot remember. I do not know whether the backup file can be used after restoration. I have not tested it. Therefore, it is safer to start the service in command mode.

2) using Live CD (or Live USB) for backup is simpler and safer. (Reference: Click to open the link)

  • 1
  • 2
  • Next Page

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.