move /home to it’s own partition

Karena ada kebutuhan space yg lebih ‘lega’ untuk /home, mau gak mau harus menambah hdd untuk partisi /home sendiri.

root@files:/#mkdir /mnt/newhome
root@files:/#mount -t reiserfs /dev/sdb2 /mnt/newhome

Copy semua isi current /home ke /home yg baru

root@files:/#cd /home
root@files:/home#find . -depth -print0 | cpio –-null –-sparse -pvd /mnt/newhome

Pastikan source telah tercopy semua ke /home yg baru, selanjutnya unmount /home yg baru

root@files:/home#umount /mnt/newhome
root@files:/#mv /home /oldhome
root@files:/#mkdir /home
root@files:/#mount /dev/sdb2 /home

Tambahkan line berikut ke /etc/fstab untuk auto mount
/dev/sdb2 /home reiserfs nodev,nosuid 0 2

Hapus /oldhome
root@files:/#rm -rf /oldhome

Comments

This entry was posted in Linux. Bookmark the permalink.

Leave a Reply

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>