Chinaunix首页 | 论坛 | 博客
  • 博客访问: 5332482
  • 博文数量: 1144
  • 博客积分: 11974
  • 博客等级: 上将
  • 技术积分: 12312
  • 用 户 组: 普通用户
  • 注册时间: 2005-04-13 20:06
文章存档

2017年(2)

2016年(14)

2015年(10)

2014年(28)

2013年(23)

2012年(29)

2011年(53)

2010年(86)

2009年(83)

2008年(43)

2007年(153)

2006年(575)

2005年(45)

分类: LINUX

2006-05-24 15:09:49

Really, really new to Linux so sorry if this is obvious and I've missed it. I'm using SuSE 9 and I want to backup my home folder to tape which I've managed with

tar -cvf /dev/st0 /$HOME

This shows me all the files being backed up and my tape spins giving me the impression that its writing.

My Question: How do I get my files back? How can I verify the data is there?

Thanks in advance
 
You could try
tar -tvf /dev/st0
which should list the filenames (t = table of contents)
or tar -xvf /tmp/test /dev/st0
which should extract the files into /tmp/test if you want to compare sizes/checksums etc.
Make sure the tape is rewound first.
I've tended to use taper () as it has a nice (curses) based interface and is pretty stable. It's up to v7.
I suggest you try it out as it's free.
 
To get the files back just apply the tar to extract the files.
--> tar xvf /dev/st0

To access the tape, work with the command "mt". Look up the different commands available in the man pages ("man mt").
Some examples:
- mt /dev/nrst0 rewind --> rewind the tape
- mt dev/nrst0 fsf 1 --> to the next file on the tape
- mt dev/nrst0 fsf --> skip to files (go to next but one file)

If you're using the driver st0, the tape will rewind after each backup.
If you want to avoid these, e.g you want to put several backups on the tape one after one, use the driver nrst0. This driver won't automatically rewind the tape. The command mt should always be used with the nrst0 driver only.
Hi
The way to backuop anytthing keeping the permisions woulld be:

tar cvpf /dev/st0 , now, if you plan to backup on a daily basis y would suggest to put via cron:
00 23 * * * tar cvpf /dev/st0 /etc/httpd /var/www
this will allow you to backup automatically at 11pm everyday.

If you want to backup an entire system, I wond use another disk ass mirror and would type

dd if= bs=1024 of=

or you can send it to tape:

tar cvpf /dev/st0 / /etc /usr /var /tmp /opt /sbin (it depends how did you create your partitions and how big they are)
ok here is I would do the backup using tar with bz2 compression
use a dds-3 tape (12gb/24Gb capacity)

tar -cjvjpf /dev/st0 / /boot /etc /home /var /www


the way to recover from tape the entire system would be:

tar xvjpf /dev/st0

lyx0m
阅读(866) | 评论(0) | 转发(0) |
0

上一篇:随便过日子

下一篇:Mutt的设置- -

给主人留下些什么吧!~~