Loading ...
Sorry, an error occurred while loading the content.

Re: How to move/combine /usr /var /home to / partition ?

Expand Messages
  • Daniel
    Sorry for the top post this is going to be a long answer. The other moderators have tried to change me but I fail. First you back each of the partitions up (to
    Message 1 of 3 , Dec 19, 2012
    View Source
    • 0 Attachment
      Sorry for the top post this is going to be a long answer. The other moderators have tried to change me but I fail.

      First you back each of the partitions up (to a thumb drive), using tar is a good idea.
      First off, you home drive migth be the problem. If you are root, then just put /home on another partition or drive that has room.
      If you left way too much room on "/" then you might consider reinstalling.

      If NON UNIX guy tells you to put everything under home, he is IMO screwing you under. Some morons decided disk drives got bigger so we dont need other partitions anymore. Fill up root once and you will learn the fallacy of this thinking.

      But I would never put /home on / as users do really stupid things and fill up /
      /etc should NOT be giving you any problems. see if someone put a /gzip file in there. /etc does not really grow.
      /usr a better way is to make a /usr/local mountpoint and move the stuff to there.
      And do NOT mess with /tmp, your swap file unless you know what the F you are doing.

      you really should do this in single user mode, to prevent changes but wont happen if you are only user.

      You want to make sure you have a boot disk ready.
      I am assuming you are not using a volume manager

      copy /etc/fstab to /etc/fstab.old and to /root/fstab.orig
      comment out "#" the mountpoint from the fstab file /etc/fstab

      Tar up the partitions and put the tar files (one at a time) on the root partition,
      cd /; tar -cvf etc.tar /etc/
      then unmount the partition,
      umount /etc
      then untar the file to the former mountpoint.
      cp etc.tar /etc/
      tar -xvf etc.tar

      mount # see if /etc is mounted
      cd /etc # see if there is the stuff you expect to see.
      reboot
      if the system starts ok, go to the other filesystems

      I did this off the top of my head, so see if you can find a similar example on the web, and check my syntax, and make sure you have a backup disk.





      --- In redhat@yahoogroups.com, Jim Thisdale <n1jmm1@...> wrote:
      >
      > Fedora 14
      > hp laptop
      > small 80GB drive
      >
      > When I did this install years ago, I was advised to make separate
      > partitions for things. Now I've run out of space on some of them.
      >
      > I'd like to move the data/functionality of the /var, /usr, /home
      > partitions back to the / partition. Then I can delete those partitions
      > and resize the / partition, thus gaining some useable space for now.
      >
      > Using gparted is not a problem.
      >
      > I need to know what I need to do so the existing fc14 knows that:
      >
      > /etc will be on say: sda1/etc instead of sda5
      > /usr will be on say: sda1/usr instead of sda4
      > /home will be on say: sda1/home instead of sda6
      > /tmp will be on say: sda/tmp instead of sda3
      >
      > Those might not be the actual current assignments, but you get the idea.
      >
      > Thanks
      > -Jim-
      > Visit my Pi running ircddb, dvrptr, Apache2 web-server & other things:
      > http://n1jmm.no-ip.org
      > http://n1jmm.no-ip.org/index.php
      >
    • Dan
      ... This is more of a fun exercize, then something that must be done.... As I mentioned, use df -k and tell us which filesystems you want to resize and why.
      Message 2 of 3 , Dec 19, 2012
      View Source
      • 0 Attachment
        On 12/19/2012 4:53 PM, Jim Thisdale wrote:
        >
        > Fedora 14
        > hp laptop
        > small 80GB drive
        >
        > When I did this install years ago, I was advised to make separate
        > partitions for things. Now I've run out of space on some of them.
        >
        > I'd like to move the data/functionality of the /var, /usr, /home
        > partitions back to the / partition. Then I can delete those partitions
        > and resize the / partition, thus gaining some useable space for now.
        >

        This is more of a fun exercize, then something that must be done....
        As I mentioned, use df -k and tell us which filesystems you want to
        resize and why.
        you must have enough room on sda to hold the whole filesystem you want
        to move.

        again, taring up the filesystems one at a time, tar -cvf home.tar /home
        unmount the filesystem
        copy the /etc/fstab to a safe place /root/fstab.orig , edit /etc/fstab
        comment oout the mounted fs
        copy the tar file to the mount point (make sure you are untaring
        correctly so you dont muck it up)
        tar -xvf home.tar
        ls -l /home (look for files in the directory and subdirectories

        reboot and see if it worked correctly. Now you can recover the sd6 space

        I would not repeat this for /etc, unless you gave it 10gb and you need
        to recover it. This and /usr can break your os if you muck it up.
        >
        >
        > Using gparted is not a problem.
        >
        > I need to know what I need to do so the existing fc14 knows that:
        >
        > /etc will be on say: sda1/etc instead of sda5
        > /usr will be on say: sda1/usr instead of sda4
        > /home will be on say: sda1/home instead of sda6
        > /tmp will be on say: sda/tmp instead of sda3
        >
        > Those might not be the actual current assignments, but you get the idea.
        >
        > Thanks
        >
        >
        > <http://groups.yahoo.com/group/redhat/post;_ylc=X3oDMTJjanVvNGxrBF9TAzk3MzU5NzE0BGdycElkAzMxNDEzBGdycHNwSWQDMTcwNTAwNjU4MARzZWMDZnRyBHNsawNudHBjBHN0aW1lAzEzNTU5NTgwMjA->
        > Messages in this topic
        > <http://groups.yahoo.com/group/redhat/message/19759;_ylc=X3oDMTM0cjFhNTI4BF9TAzk3MzU5NzE0BGdycElkAzMxNDEzBGdycHNwSWQDMTcwNTAwNjU4MARtc2dJZAMxOTc1OQRzZWMDZnRyBHNsawN2dHBjBHN0aW1lAzEzNTU5NTgwMjAEdHBjSWQDMTk3NTk->
        > (1)
        >
        > Recent Activity:
        >
        > * New Members
        > <http://groups.yahoo.com/group/redhat/members;_ylc=X3oDMTJkMTFmOWY1BF9TAzk3MzU5NzE0BGdycElkAzMxNDEzBGdycHNwSWQDMTcwNTAwNjU4MARzZWMDdnRsBHNsawN2bWJycwRzdGltZQMxMzU1OTU4MDIw?o=6>
        > 1
        >
        > Visit Your Group
        > <http://groups.yahoo.com/group/redhat;_ylc=X3oDMTJjMGRnY2JlBF9TAzk3MzU5NzE0BGdycElkAzMxNDEzBGdycHNwSWQDMTcwNTAwNjU4MARzZWMDdnRsBHNsawN2Z2hwBHN0aW1lAzEzNTU5NTgwMjA->
        >
        > Yahoo! Groups
        > <http://groups.yahoo.com/;_ylc=X3oDMTJiNDMyMmlyBF9TAzk3MzU5NzE0BGdycElkAzMxNDEzBGdycHNwSWQDMTcwNTAwNjU4MARzZWMDZnRyBHNsawNnZnAEc3RpbWUDMTM1NTk1ODAyMA-->
        >
        > Switch to: Text-Only
        > <mailto:redhat-traditional@yahoogroups.com?subject=Change%20Delivery%20Format:%20Traditional>,
        > Daily Digest
        > <mailto:redhat-digest@yahoogroups.com?subject=Email%20Delivery:%20Digest>
        > . Unsubscribe
        > <mailto:redhat-unsubscribe@yahoogroups.com?subject=Unsubscribe> .
        > Terms of Use <http://docs.yahoo.com/info/terms/> . Send us Feedback
        > <mailto:ygroupsnotifications@yahoogroups.com?subject=Feedback%20on%20the%20redesigned%20individual%20mail%20v1>
        > .
        >
        >



        [Non-text portions of this message have been removed]
      Your message has been successfully submitted and would be delivered to recipients shortly.