Announcement

Collapse
No announcement yet.

How to clean up system partition ?

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    #16
    Originally posted by ronshor View Post
    I used Bleachbit and it cleaned up a few more GB, so now I have 15GB free.
    Is that going to be enough for an upgrade to 16.04?
    Probably. That's more than needed for a new install

    Something probably went wrong when I installed Ubuntu 12.04 years ago and my home folder was left on my system folder. Since there's now easy way to fix this (GUI...) I left it that way and it never bothered me. My other partition and other disk are on /media and I have control over them from the GUI.

    If you know of an easy way to move the Home folder than I'm open to hear about it.
    I'll write a how-to for this. The easy way is not from the GUI, but I'll consider it. I'll include how to do it at install time too since you're probably going to be doing a new install.

    I moved to Kubuntu from Ubuntu and installed it from the terminal so I have both of them on my machine (not that I need or ever went back to Ubuntu ) so maybe that's the reason for the mess I have on my root user and /etc
    That might explain it.

    The reason I'm not that thrilled about doing a new install is beacause I don't have enough time now to download all my programs again and then configure them to my needs. I know that with Firefox I can save my profile but with other programs I will probably have to do a lot of work .
    Maybe I'll do it in the future when I have more time.
    You're assuming that you won't have to re-configure most of your programs anyway. 3-4 years is a very long time. I doubt there are many programs that haven't changed since 2014.

    And you are right. I'm interested in 16.04 for the the stability.
    I read about the KDEneon you recommended and it sounds interesting. When I have time to do a new install I'll consider this but I'm also considering Linux Mint KDE. What do you think will be better for me ?
    I don't know a thing about Mint other than it's often suggested as a good distro for beginners. KDEneon has it's pluses and minuses. If you want a stable core but the newest Plasma 5, KDEneon a good way to go - it's 16.04 with new Plasma 5. If you don't care about having the latest and greatest Plasma 5, then stick with Kubuntu.

    My final advice:
    1) Decide if you're upgrading now or willing to wait for 18.04. If you upgrade to 16.04, you'll be doing upgrading again in 3 years. If you wait for 18.04, you won't have to upgrade again for 5 years. I'd wait until June-July if you waiting for 18.04. Let the early bugs get worked out.
    2) When you do the new install, start out with a new clean home folder separate from your install. This makes backups easier and keeps your personal files safer.
    3) Regardless of which you choose, do a new install. Upgrading a 12.04 Ubuntu to 14.04 Kubuntu and then again to whichever you choose is kicking the can down the road IMO. The number of issues you're likely to have (or continue to have) just isn't worth the short-term time savings, not to mention all the cruft left over. Time to stop patching those old jeans and go buy a new pair. Reserve an entire weekend, make a list of the applications you need, do the new install, add all the applications from your list, configure everything until it's to your liking, enjoy your new OS.

    EDIT: Another advantage to doing a new install - Your old install will be untouched. That means if something goes wrong with your new install, you'll still have a working backup install to boot to.

    Please Read Me

    Comment


      #17
      Originally posted by oshunluvr View Post
      Probably. That's more than needed for a new install

      I'll write a how-to for this. The easy way is not from the GUI, but I'll consider it. I'll include how to do it at install time too since you're probably going to be doing a new install.

      That might explain it.

      You're assuming that you won't have to re-configure most of your programs anyway. 3-4 years is a very long time. I doubt there are many programs that haven't changed since 2014.

      I don't know a thing about Mint other than it's often suggested as a good distro for beginners. KDEneon has it's pluses and minuses. If you want a stable core but the newest Plasma 5, KDEneon a good way to go - it's 16.04 with new Plasma 5. If you don't care about having the latest and greatest Plasma 5, then stick with Kubuntu.

      My final advice:
      1) Decide if you're upgrading now or willing to wait for 18.04. If you upgrade to 16.04, you'll be doing upgrading again in 3 years. If you wait for 18.04, you won't have to upgrade again for 5 years. I'd wait until June-July if you waiting for 18.04. Let the early bugs get worked out.
      2) When you do the new install, start out with a new clean home folder separate from your install. This makes backups easier and keeps your personal files safer.
      3) Regardless of which you choose, do a new install. Upgrading a 12.04 Ubuntu to 14.04 Kubuntu and then again to whichever you choose is kicking the can down the road IMO. The number of issues you're likely to have (or continue to have) just isn't worth the short-term time savings, not to mention all the cruft left over. Time to stop patching those old jeans and go buy a new pair. Reserve an entire weekend, make a list of the applications you need, do the new install, add all the applications from your list, configure everything until it's to your liking, enjoy your new OS.

      EDIT: Another advantage to doing a new install - Your old install will be untouched. That means if something goes wrong with your new install, you'll still have a working backup install to boot to.
      A few more questions :

      1. When doing a new install, at least when it comes to firefox and chrome we can save the profile and than get all of our add ons and configuration on the new system.
      If all programs save their configurations on the Home folder, why can't we get their configurations on the new system the way we can get it with firefox and chrome ?

      2. If I move my Home folder to another partition, what happens if I want to replace one of my disks or add another one in the future ?
      Right now, when it's on /media it's done automatically by the system.

      And even more importantly, when I'm doing an upgrade or a new install. How do I make sure I don't erase all my personal files by mistake ?

      3.
      Another advantage to doing a new install - Your old install will be untouched. That means if something goes wrong with your new install, you'll still have a working backup install to boot to.
      I don't understand this. The system keeps the old install on the disk ?
      Isn't it taking too much storage space ?
      Wouldn't it be better to format the partition first ?

      Comment


        #18
        Originally posted by Snowhog View Post
        And on blog.linuxmint.com: https://blog.linuxmint.com/?p=3418
        I read the blog and they say that it would be possible to install KDE on linux mint 19.
        What is the difference then between the two options ?

        Comment


          #19
          Sorry, I was on vacation...

          Originally posted by ronshor View Post
          A few more questions :
          1. When doing a new install, at least when it comes to firefox and chrome we can save the profile and than get all of our add ons and configuration on the new system.
          If all programs save their configurations on the Home folder, why can't we get their configurations on the new system the way we can get it with firefox and chrome ?
          You can use all your old configs by simply using the old home, but IMO some applications change their configs from time-to-time. Bookmarks in a browser aren't the same thing as settings a program might be using. You can try it, but don'r be too surprised if one or a few applications break. Others do this without complaint, so I guess it depends on your installed software.

          Originally posted by ronshor View Post
          2. If I move my Home folder to another partition, what happens if I want to replace one of my disks or add another one in the future ?
          Right now, when it's on /media it's done automatically by the system.
          /media has nothing to do with a home partition. It's used for temporary mounts like thumb drives or partitions you don't mount at boot. A home partition would be a separate partition mounted at boot. root and home partitions are mounted by /etc/fstab not udev, which mounts removable devices like USB drives.

          Adding a second drive doesn't change what's on your current drive. If you need to replace a drive, you'll have to move your home to the new drive whether it's on a separate partition or not, so why would that be different?

          Originally posted by ronshor View Post
          And even more importantly, when I'm doing an upgrade or a new install. How do I make sure I don't erase all my personal files by mistake ?
          Ummm, by not selecting the home partition as the root partition when installing? How do you prevent wiping any partition accidentally - be careful.

          Originally posted by ronshor View Post
          3. I don't understand this. The system keeps the old install on the disk ?
          Isn't it taking too much storage space ?
          Wouldn't it be better to format the partition first ?
          I was suggesting that you could keep the old install as a backup in case the new one doesn't install correctly. If you upgrade and it fails, what are you going to do then? Have you made backup of your home folder? If not and it's one the same partition as the root install, you'll have to wipe it.

          If your hard drive is too small to have two Kubuntu installs (about 40GB total), maybe it's time to upgrade your drive.

          If you need to free more disk space, then don't.

          Please Read Me

          Comment


            #20
            Originally posted by oshunluvr View Post
            /media has nothing to do with a home partition. It's used for temporary mounts like thumb drives or partitions you don't mount at boot. A home partition would be a separate partition mounted at boot. root and home partitions are mounted by /etc/fstab not udev, which mounts removable devices like USB drives.
            Adding a second drive doesn't change what's on your current drive. If you need to replace a drive, you'll have to move your home to the new drive whether it's on a separate partition or not, so why would that be different?
            I have 2 disks on my machine.
            Disk 1 with 2 partitions. One for the system (now with Home on it as well) and the other with personal files on /media mounted at start up
            Disk 2 with personal files on /media mounted at start up.

            If I move Home to the second partition on disk 1 and attach my personal files from Disk 2 to it.
            What should I do when I need to replace disk 2 one day ?
            Will I have to create a mount point again ?

            Anyway, this all mount points/Home folder thing is way too complicated for me as a GUI user.
            I'm gonna stick to the /media mount at start up. It served me well in the past 5 years and I really don't see any good reason to change it.
            What I am interested though, is to move my Home folder to the second partition on disk 1 and this is what I need your help for.

            By the way, I visited Kubuntu's download page and saw this message :
            "Upgrade from the 14.04 LTS is still problematic. Please install a fresh copy of 16.04.4 after running a backup of all your data. "

            So i guess I have no other choice but to do do a new install.
            I decided to wait till 9-10/2018 and then to install 18.04

            Since I want to keep my old Home folder for the new install and there's no way to move it from the GUI I need your help. Can you help me with this ?

            Comment


              #21
              Yes, you would have to redo the mount if you replaced the disk or move the partition - that's always required. It's the only way the system knows where stuff is. This assumes you're using UUIDs to mount. The UUID changes every time you create a new filesystem.

              I agree waiting to 18.04 is the best idea. I just installed it this week and it's rock solid so far. You should have a good experience with it - hopefully.

              Moving your home to another disk is actually pretty easy. Post a copy of your /etc/fstab file so I can give the exact commands to you. You can write them down or print them and just follow along. I will also need a list of your mounts. The best list of those will be the output of the sudo blkid command from a terminal. Open konsole and type that in and post the results.

              Please Read Me

              Comment


                #22
                Originally posted by oshunluvr View Post
                Yes, you would have to redo the mount if you replaced the disk or move the partition - that's always required. It's the only way the system knows where stuff is. This assumes you're using UUIDs to mount. The UUID changes every time you create a new filesystem.

                I agree waiting to 18.04 is the best idea. I just installed it this week and it's rock solid so far. You should have a good experience with it - hopefully.

                Moving your home to another disk is actually pretty easy. Post a copy of your /etc/fstab file so I can give the exact commands to you. You can write them down or print them and just follow along. I will also need a list of your mounts. The best list of those will be the output of the sudo blkid command from a terminal. Open konsole and type that in and post the results.
                Code:
                ron@ron-Vostro-270:~$ sudo blkid
                [sudo] password for ron: 
                /dev/sda1: LABEL="DELLUTILITY" UUID="A891-142C" TYPE="vfat" 
                /dev/sda2: LABEL="OS" UUID="512C-32FB" TYPE="vfat" 
                /dev/sda3: UUID="94796831-9dfd-4182-9079-eb7036b5aa24" TYPE="ext4" 
                /dev/sda5: UUID="e1b01124-64ae-48d5-989b-69ea15867ecb" TYPE="ext4" 
                /dev/sda6: UUID="7c9a88d3-0491-4ace-abd1-94ac16298db6" TYPE="swap" 
                /dev/sdb: LABEL="New Volume" UUID="fb8cfed6-7310-4b18-8b64-e68fd2d9a545" TYPE="ext4" 
                ron@ron-Vostro-270:~$
                [#]# /etc/fstab: static file system information.
                #
                # Use 'blkid' to print the universally unique identifier for a
                # device; this may be used with UUID= as a more robust way to name devices
                # that works even if disks are added and removed. See fstab(5).
                #
                # <file system> <mount point> <type> <options> <dump> <pass>
                proc /proc proc nodev,noexec,nosuid 0 0
                # / was on /dev/sda3 during installation
                UUID=94796831-9dfd-4182-9079-eb7036b5aa24 / ext4 errors=remount-ro 0 1
                # swap was on /dev/sda6 during installation
                UUID=7c9a88d3-0491-4ace-abd1-94ac16298db6 none swap sw 0 0
                [/#]

                sda5 is the partition I want to move Home to ( 60GB free ). sda3 is the system partition.
                BTW, When Home is going to be on sda5, will I have to move all the personal files I have there inside Home or can I just leave them in a separate folder next to Home ?

                Comment


                  #23
                  BTW, When Home is going to be on sda5, will I have to move all the personal files I have there inside Home or can I just leave them in a separate folder next to Home ?
                  This, as in almost all things Linux, is your choice. There are several solutions.

                  The typical setup involves mounting a file system at /home, meaning when you click on /home, you'll see one folder for each user. Assuming sda5 contains 100 files and folders, if you left it that way you would see all the files and your user folder. Access becomes the issue in this case because the /home mount itself doesn't allow user level write access to whats contained in it. To explain further; /home is owned by root, but /home/ron would be owned by you. You would be able to see the files in /home, but not edit or delete them. All the files in /home/ron you would be able to edit and delete. It is this way for user security as Linux was designed as a multi-user system.

                  One way to "fix" this is to mount /sda5 with your user owning the mount, then bind mount your home folder to /home/ron so other applications could find where to put configs and other stuff in your home. This would not work well if you have other users because you would have to create separate mount points and bind mounts for each user. If you are the only user of the system, it's no big deal.

                  By far, the easiest to manage and most sensible way to handle this is to move all the files and folders currently on sda5 either into your new home folder or into a single folder that you own, but you certainly don't have to. If you are saying that all the files are already in a single folder on sda5, then you can leave them there as-is and you can decide how you want to access them.

                  My thought is; right now when you click on sda5 in Dolphin, udev mounts the file system into a folder under /media/ron. So it appears to you as all the files are currently in a folder when actually they reside on the root level of the file system. This is the situation you would want to avoid. Conversely, if now when you click on sda5 in Dolphin you see a single folder and then have to click on that folder to get to your files, then you're OK to leave it like that and proceed with moving your home to the same file system.

                  Let me know which way you are currently set up and how you would like to proceed.

                  Please Read Me

                  Comment


                    #24
                    Originally posted by oshunluvr View Post
                    This, as in almost all things Linux, is your choice. There are several solutions.

                    The typical setup involves mounting a file system at /home, meaning when you click on /home, you'll see one folder for each user. Assuming sda5 contains 100 files and folders, if you left it that way you would see all the files and your user folder. Access becomes the issue in this case because the /home mount itself doesn't allow user level write access to whats contained in it. To explain further; /home is owned by root, but /home/ron would be owned by you. You would be able to see the files in /home, but not edit or delete them. All the files in /home/ron you would be able to edit and delete. It is this way for user security as Linux was designed as a multi-user system.

                    One way to "fix" this is to mount /sda5 with your user owning the mount, then bind mount your home folder to /home/ron so other applications could find where to put configs and other stuff in your home. This would not work well if you have other users because you would have to create separate mount points and bind mounts for each user. If you are the only user of the system, it's no big deal.

                    By far, the easiest to manage and most sensible way to handle this is to move all the files and folders currently on sda5 either into your new home folder or into a single folder that you own, but you certainly don't have to. If you are saying that all the files are already in a single folder on sda5, then you can leave them there as-is and you can decide how you want to access them.

                    My thought is; right now when you click on sda5 in Dolphin, udev mounts the file system into a folder under /media/ron. So it appears to you as all the files are currently in a folder when actually they reside on the root level of the file system. This is the situation you would want to avoid. Conversely, if now when you click on sda5 in Dolphin you see a single folder and then have to click on that folder to get to your files, then you're OK to leave it like that and proceed with moving your home to the same file system.

                    Let me know which way you are currently set up and how you would like to proceed.
                    When I click on sda5 in dolphin I see two folders: one folder called "lost + found" that I can't get into (probably something for system needs)
                    and another folder which is my personal folder called "folders" where I keep all my personal files/folders. So I guess it's all right.

                    I have two users on my system. The second user is for guests who need to use a PC from tome to time.

                    BTW on /media/ron I have both sda5 and sdb which is my second drive.
                    Last edited by ronshor; Mar 18, 2018, 01:33 AM.

                    Comment


                      #25
                      Ok, this will be easy.

                      Boot up but don't log in. Instead, hit CRTL-ALT-F1 and then log into the terminal.

                      Commands:
                      sudo -i
                      mv /home /home_old
                      mkdir /home
                      mount /dev/sda5 /home
                      rsync -a /home_old/ /home


                      When the rsync command completes, you will have a copy of /home/ron and any other folders previously in /home in the new /home. Now type CTRL-ALT-F7 and log in.

                      At this point you should be logged in using your new home location. To make the change permanent you need to edit /etc/fstab and add this line:

                      UUID=e1b01124-64ae-48d5-989b-69ea15867ecb /home ext4 defaults 0 2

                      and save. One thing to note, be sure to leave a blank line at the end of fstab. There is one there now, but when you go to add this entry, make sure you hit Enter to start a new line (just below the line that mounts / is the typical place) don't just add this to the bottom of the file unless you hit Enter again after the line. At next reboot you should be automatically using the new home.

                      Two things left to do;

                      1. Your "folders" on sda5 won't show up in Dolphin like they did before under /media/ron because sda5 is now mounted as /home. The easiest fix would be to just copy "folders" into your home folder but there are other ways to do this if you would like - you could permanently mount folders under /media/ron or symlink to folders from somewhere else. Decide where you want "folders" to appear and post back.

                      2. Your old home is still on sda3 under /home_old and taking up space. When you're comfortable that everything works and all the files are copied, delete it. One way to verify all the files are copied is to open a terminal and type:

                      diff -r /home/ron /home_old/ron

                      You shouldn't get any files or folders listed.

                      Please Read Me

                      Comment


                        #26
                        Originally posted by oshunluvr View Post

                        Two things left to do;

                        1. Your "folders" on sda5 won't show up in Dolphin like they did before under /media/ron because sda5 is now mounted as /home. The easiest fix would be to just copy "folders" into your home folder but there are other ways to do this if you would like - you could permanently mount folders under /media/ron or symlink to folders from somewhere else. Decide where you want "folders" to appear and post back.
                        I followed your instructions and everything seems all right
                        There's no problem with "folders" in Dolphin, because I can still see the drive on dolphin's left panel (Places ) and when I click on it I see what's in it (including "folders , /home/ron and /home second user ). There's also a possibility to create direct shortcut from Dolphin Places to "folders" so I guess everything is alright here.

                        2. Your old home is still on sda3 under /home_old and taking up space. When you're comfortable that everything works and all the files are copied, delete it. One way to verify all the files are copied is to open a terminal and type:

                        diff -r /home/ron /home_old/ron

                        You shouldn't get any files or folders listed.
                        This command brought up a lot of stuff... mostly from firefox and a folder called /home/ron/. cache
                        maybe because I opened firefox before I ran it.
                        Is there a way to fix this ?

                        Comment


                          #27
                          Anything under .cache is temporary anyway. Just delete the old one without worries.

                          Please Read Me

                          Comment

                          Working...
                          X