Personal tools
You are here: Home ASEAN+3 Countries Myanmar Enterprise Linux Discussions (Myanmar) move usr & var dir to other harddrive
Document Actions

move usr & var dir to other harddrive

Hola.... Everyone Seems like everybody's busy to write a blog in this site. So, I'm the one who start this Blog and the one who start to write the article in this blog. :)

Last week, I got one problem with my Linux Box (Actually it's RHEL3 x86_64) 64bit Workstation. That Workstation act like a geographic applications and NFS server for past 4 years. Now that one's usr partition showing out of disk space. One thing is if we're using LVM2, that won't be a problem but ever since we're using that workstation we just used normal partition.

So, I'm just added new SCSI drive to that WS and do some changes. Here's the step by step changes that I've made-

  1. su - #password:
  2. #mkdir /usr1
  3. #e2label /dev/sdc1 /usr1 #mount /dev/sdc1 /usr1
  4. # cd /usr (old partition) # find . -depth -print0 | sudo cpio --null --sparse -pvd /usr1 above line's copy all the files and folder from old usr partition.
  5. # cd /etc # cp /etc/fstab /tmp
  6. # vi /etc/fstab #comment out the old /usr (mounting point)#

#LABEL=/usr /usr ext3 defaults 1 2

then save that fstab file and reboot .

  1. Then boot the system with RHEL3 disc 1, boot into rescue mode. # linux rescue

#system is mount in /mnt/sysimage/ #rm -rf /mnt/sysimage/usr #mv /mnt/sysimage/usr1 /mnt/sysimage/usr

Now /usr partition is under / . So, you can change on line in /etc/fstab

LABEL=/usr1 /usr ext3 defaults 1 2

Save the changes and reboot.

And that's it... you just moved the /usr partition to New Harddisk.

Friday, March 28, 2008  | Permalink |  Comments (0)
trackback URL:  http://www.iosn.net/asean-3/countries/myanmar/ELinux/usr/sbtrackback
del.icio.us   Digg   Yahoo   Google   Spurl
Enterprise Linux Discussions (Myanmar)
« May 2008 »
Su Mo Tu We Th Fr Sa
1 2 3
4 5 6 7 8 9 10
11 12 13 14 15 16 17
18 19 20 21 22 23 24
25 26 27 28 29 30 31
 

Powered by Plone Section 508 WCAG Valid CSS Usable in any browser IOSN

Copyright respective authors. Unless otherwise specified, content licensed under Creative Commons Attribution License.

Legal Disclaimer