Find the answer to your Linux question:
Results 1 to 8 of 8
have extended /usr partition and the size is around 300GB. I have used around 140GB. Now am planning to reduce the size of the usr partition by 100GB as i ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined!
    Join Date
    Jan 2013
    Posts
    32

    LVM reduce


    have extended /usr partition and the size is around 300GB. I have used around 140GB. Now am planning to reduce the size of the usr partition by 100GB as i require space for other partitions. Can anyone help me to fix this.

    I tried the following
    #umount /usr
    umount: /usr : device is busy

    how to proceed further.

  2. #2
    Linux Engineer docbop's Avatar
    Join Date
    Nov 2009
    Location
    Woodshed, CA
    Posts
    902
    Are you booting from a CD? /usr is a main directory for a Unix system applications.

    FYI: Many think /usr mean its a User directory, but usr stands for Unix System Resources.

  3. #3
    Linux Engineer
    Join Date
    Dec 2013
    Posts
    1,054
    You can also use init and reduce your run level to single user.

  4. #4
    Just Joined!
    Join Date
    Jan 2013
    Posts
    32
    I tried in single user mode it says the same device busy. I tried with rescue system it said the same after mounting chroot /mnt/sysimage.
    wheni gave lsof /usr it shows the following output.

    COMMAND PID USER FD TYPE DEVICE SIZE/OFF NODE NAME
    sshd 1060 root txt REG 253,7 526008 130683 /usr/sbin/sshd
    sshd 1060 root mem REG 253,7 175288 261415 /usr/lib64/libnssutil3.so
    sshd 1060 root mem REG 253,7 1284048 261715 /usr/lib64/libnss3.so
    sshd 1060 root mem REG 253,7 1662832 261773 /usr/lib64/libcrypto.so.1 .0.0
    master 1137 root txt REG 253,7 155976 51 /usr/libexec/postfix/mast er
    master 1137 root mem REG 253,7 175288 261415 /usr/lib64/libnssutil3.so
    master 1137 root mem REG 253,7 1284048 261715 /usr/lib64/libnss3.so
    master 1137 root mem REG 253,7 181168 261718 /usr/lib64/libsmime3.so
    master 1137 root mem REG 253,7 221568 261719 /usr/lib64/libssl3.so
    master 1137 root mem REG 253,7 1662832 261773 /usr/lib64/libcrypto.so.1 .0.0
    master 1137 root mem REG 253,7 372488 261775 /usr/lib64/libssl.so.1.0. 0
    master 1137 root mem REG 253,7 106160 261453 /usr/lib64/libsasl2.so.2. 0.23
    master 1137 root mem REG 253,7 1582952 261826 /usr/lib64/mysql/libmysql client.so.16.0.0
    crond 1145 root txt REG 253,7 59832 130680 /usr/sbin/crond
    crond 1145 root mem REG 253,7 99158576 654389 /usr/lib/locale/locale-ar chive
    pickup 1150 postfix txt REG 253,7 234440 54 /usr/libexec/postfix/pick up
    pickup 1150 postfix mem REG 253,7 175288 261415 /usr/lib64/libnssutil3.so
    pickup 1150 postfix mem REG 253,7 1284048 261715 /usr/lib64/libnss3.so
    pickup 1150 postfix mem REG 253,7 181168 261718 /usr/lib64/libsmime3.so
    pickup 1150 postfix mem REG 253,7 221568 261719 /usr/lib64/libssl3.so
    pickup 1150 postfix mem REG 253,7 1662832 261773 /usr/lib64/libcrypto.so.1 .0.0
    pickup 1150 postfix mem REG 253,7 372488 261775 /usr/lib64/libssl.so.1.0. 0
    pickup 1150 postfix mem REG 253,7 106160 261453 /usr/lib64/libsasl2.so.2. 0.23
    pickup 1150 postfix mem REG 253,7 1582952 261826 /usr/lib64/mysql/libmysql client.so.16.0.0
    qmgr 1151 postfix txt REG 253,7 308104 71 /usr/libexec/postfix/qmgr
    qmgr 1151 postfix mem REG 253,7 175288 261415 /usr/lib64/libnssutil3.so
    qmgr 1151 postfix mem REG 253,7 1284048 261715 /usr/lib64/libnss3.so
    qmgr 1151 postfix mem REG 253,7 181168 261718 /usr/lib64/libsmime3.so
    qmgr 1151 postfix mem REG 253,7 221568 261719 /usr/lib64/libssl3.so
    qmgr 1151 postfix mem REG 253,7 1662832 261773 /usr/lib64/libcrypto.so.1 .0.0
    qmgr 1151 postfix mem REG 253,7 372488 261775 /usr/lib64/libssl.so.1.0. 0
    qmgr 1151 postfix mem REG 253,7 106160 261453 /usr/lib64/libsasl2.so.2. 0.23
    qmgr 1151 postfix mem REG 253,7 1582952 261826 /usr/lib64/mysql/libmysql client.so.16.0.0
    login 1160 root mem REG 253,7 38712 261641 /usr/lib64/libcrack.so.2. 8.1
    bash 1174 root mem REG 253,7 99158576 654389 /usr/lib/locale/locale-ar chive
    bash 1174 root mem REG 253,7 26060 261397 /usr/lib64/gconv/gconv-mo dules.cache
    sshd 1188 root txt REG 253,7 526008 130683 /usr/sbin/sshd
    sshd 1188 root mem REG 253,7 38712 261641 /usr/lib64/libcrack.so.2. 8.1
    sshd 1188 root mem REG 253,7 175288 261415 /usr/lib64/libnssutil3.so
    sshd 1188 root mem REG 253,7 1284048 261715 /usr/lib64/libnss3.so
    sshd 1188 root mem REG 253,7 1662832 261773 /usr/lib64/libcrypto.so.1 .0.0
    bash 1190 root mem REG 253,7 99158576 654389 /usr/lib/locale/locale-ar chive
    bash 1190 root mem REG 253,7 26060 261397 /usr/lib64/gconv/gconv-mo dules.cache
    lsof 1214 root txt REG 253,7 141048 130692 /usr/sbin/lsof
    lsof 1214 root mem REG 253,7 99158576 654389 /usr/lib/locale/locale-ar chive
    lsof 1214 root mem REG 253,7 26060 261397 /usr/lib64/gconv/gconv-mo dules.cache
    lsof 1215 root txt REG 253,7 141048 130692 /usr/sbin/lsof
    lsof 1215 root mem REG 253,7 99158576 654389 /usr/lib/locale/locale-ar chive

    how to proceed from this. thanks in advance. My distro is centos 6.4. hardware is ibm x 3610 on RAID 1E.

  5. #5
    Linux Engineer
    Join Date
    Dec 2013
    Posts
    1,054
    Are you sure you were in single user and the terminal wasn't open to the /usr filesystem? You should be able to unmount /usr after init 1.

  6. #6
    Just Joined!
    Join Date
    Jan 2013
    Posts
    32
    PFA screenshot of /usr in single user mode.
    Attached Images Attached Images

  7. #7
    Linux Engineer
    Join Date
    Dec 2013
    Posts
    1,054
    It makes no sense to me I've heard some systems will leave existing ssh sessions up when a system is dropped to single user mode. You appear to have an ssh/bash session running. Did you leave a remote connection up?

  8. #8
    Linux Engineer
    Join Date
    Apr 2012
    Location
    Virginia, USA
    Posts
    882
    There is almost never a good reason to put /usr on it's own partition in the first place, despite what you may be told / read on the internet.

    Guess what's in /usr ? Your shared libraries. You cannot unmount /usr and still have a working system. You need to boot to a rescue cd and perform the operations offline.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •