- cfdisk /dev/sdb //建立partition
- mkfs.ext4 /dev/sdb1 //format為ext4格式
- mkdir /media/tmp
- mount /dev/sdb1 /media/tmp
- rsync -avx /home /media/tmp
- mount /dev/sdb1 /home
- ls -l /home //確認是否成功
- umount /home
- umount /media/tmp
- rm -r /media/tmp
- rm -rf /home/*
#blkid
/dev/sda1: UUID="bba98b54-13c4-49fc-bdb8-998d0d771844" TYPE="ext4"
/dev/sda5: UUID="0ef50f74-032e-4790-bd7b-8e19e770f7ea" TYPE="swap"
/dev/sdb1: UUID="e71eed4f-2188-4f33-a5e1-d76b7e6084f4" TYPE="ext4"
#leafpad /etc/fstab
增加
UUID=e71eed4f-2188-4f33-a5e1-d76b7e6084f4 /home ext4 defaults 0 2
沒有留言:
張貼留言