当前位置:首页 > 服务器类 > Linux服务器 > > Linux攻略 用Ghost备份Linux系统的方法

Linux攻略 用Ghost备份Linux系统的方法

点击次数:29 次 发布日期:2008-11-21 23:31:15 作者:源代码网
源代码网推荐

工具:ghost.exe image file ( 最小而完整的系统所作出来的image文件 ).

  Ghost linux主要几个步骤:

  1、 boot from cd

  2、 restore redhat image into hard disk

  3、 define major hard disk space as reiserfs partition

  4、 update /etc/lilo.conf and execute lilo v update the /etc/fstab

  5、 cp all / files into /reiser ( the mount partition reiserfs partition )

  6、 reboot ,,ok!!!

  每步的详细操作:

  一、 boot from cd

  二、 restore with ghost

  select destination drive and make sure the new and old sizes are the same.

  (we want to use the free space for reiserfs later )

  ghost过程应该很快,然后reboot,别忘了取出光盘。

  按提示config系统查找到的硬件。

  三、 define new partition with fdisk

  # fdisk /dev/had

  command ( m for help) : p 查看分区情况。

  Command ( m for help ) : n define a new partition .

  1 , 2 分区都已经用了,我们选 3 ,

  first cylinder and last cylinder 都按 default , 也就是用了其它的剩余空间。

  确认他的ID 是83 ,,83对应的是liunx,ID 等于的5对应为extend , 82对应为linux swap 。

在按p查看一下分区表的情况。这时应该添加了/dev/hda3 了。

  之后 # sync;sync;sync;reboot

  然后 # mkreiserfs / dev / hda3

  系统会提示attention : all data will be lost on ‘ / dev/ hda3 ’ !(y /n ) 选 y 继续

  initializing journa 10% ……20 % ………100%

  syncing …….

  四、update /etc/lilo.conf and execute lilo v update the /etc/fstab

  修改lilo.conf

  #vi /etc/lilo.conf

  change “root=/dev/hda1 ” to “ root= /dev/hda3 ”

  # lilo -v -v

  修改 fstab

  # vi /etc/fstab

  把第一行注释掉,然后加入

  “ /dev/hda3 / reiserfs default 1 1 ”

  保存退出。

  五、cp all / files into /reiser ( the mount partition reiserfs partition )

  # mkdir /reiser

  # mount t reiserfs /devhda3 /reiser

  # cp -a -x / /reiser

  这步需要点时间,可以出去抽两根烟在回来。

  Cp 完成后

  # sync ; sync ; sync ; reboot

  这样系统的ghost就算大功告成了。

 

源代码网供稿.
网友评论 (0)
会员中心
服务器类
本站推荐
服务器类之精华