Announcement

Collapse
No announcement yet.

is it safe to isolate the usr directory for this reason during install?

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

    [SOLVED] is it safe to isolate the usr directory for this reason during install?

    I'm about to reinstall kubuntu 19.10 due to various problems after install. My question is fairly simple...

    Is it safe to isolate the /usr directory on it's own partition/drive, so that there is less work after a reinstall to get back to where I was as far as installed applications? I already have home isolated in this way.

    #2
    I believe most on this forum back-up /home by default.
    However there are many who always do a totally fresh install every upgrade to ensure a pristine system.

    Comment


      #3
      There is no use in isolating just /usr, as there are many other places important files are stored.

      https://www.linux.com/tutorials/linu...tem-explained/

      You can back up and recover the list of installed packages and added repos using tools like aptik-gtk and apt-clone, or others..
      These tools are good for recovering the same OS version, not useful for fresh installs of new OS versions as package names and version numbers do change.

      Comment


        #4
        The /usr directory does not need to be, and should not be isolated, for any kind of install even on a re-install. On a normal install, a clean install, and a re-install, the installer will always install something into /usr, even with a minimal install option. If you doing a re-install because something went sideways, it could be one or more program files that went sideways, so you would WANT to reinstall programs. Of course, on a reinstall - and a reinstall only - you might want to have and use a recovery list of current program file versions, if you are certain that nothing is bad.

        Just suck it up and let the installer do its thing, and then come along behind and reinstall anything additional, or remove anything unwanted - post-install. None of those actions takes all that much time, but provides greater certainty that you will have a proper and stable platform - post install. It's more important to go right, than to go fast.

        I go by a very old saying "The hurrier I go, the behinder I get."
        The next brick house on the left
        Intel i7 11th Gen | 16GB | 1TB | KDE Plasma 5.27.11​| Kubuntu 24.04 | 6.8.0-31-generic



        Comment


          #5
          @jglen490
          that's great feedback! Do you recommend anything, other than /home, that should be isolated, if anything?

          Comment


            #6
            Personally,
            I find isolating (or backing up and restoring, or simply copying over) /home takes care of most things.

            For some particularly recalcitrant software, I have a little list of python modules/libraries/odds&ends that are especially obnoxious to install (need workarounds, have to install versions not available for distro - with tweaks - etc.)
            The really good thing about restoring /home, the settings don't have to be for installed stuff, but you still get them after you install it.

            Comment


              #7
              Originally posted by jasoncollege24 View Post
              @jglen490
              that's great feedback! Do you recommend anything, other than /home, that should be isolated, if anything?
              Happy to help. All I ever do aside from having separate partitioning for / and /home, is to do regular /home backups including a backup before clean installing. All I ever have used for the past 5 or so years is the LTS version for Kubuntu, so clean installs only happen every couple of years, unless I need to replace hardware!
              The next brick house on the left
              Intel i7 11th Gen | 16GB | 1TB | KDE Plasma 5.27.11​| Kubuntu 24.04 | 6.8.0-31-generic



              Comment


                #8
                One more question from the Linux noob... Can I just drag & drop > copy to backup my home dir, for restoration later, or is there something special I need to do for backup, and restore of /home?

                Comment


                  #9
                  Personally, I use rsync (command line). There are several GUI assisted applications (i.e., Grsync) that sit on top of rsync to help the user do a proper sync. Yes, you can drag and drop, which is essentially a copy from one place to another. There are some subtle differences between a sync (i.e., rsync) and a copy (i.e., drag/drop, cp), mainly in the way that dates may be handled, so I choose to sync with rsync. It's a choice!

                  I always send whatever I backup to a USB connected target drive. USB, so that I can attach and detach as needed. My backup is never permanently attached to the system and is never a drive referenced in /etc/fstab. I actually have a few backup drives that I rotate on a schedule. It's paranoia, until something actually goes wrong
                  The next brick house on the left
                  Intel i7 11th Gen | 16GB | 1TB | KDE Plasma 5.27.11​| Kubuntu 24.04 | 6.8.0-31-generic



                  Comment


                    #10
                    I will look into rsync for future backup/restores, as I did use that to move my home dir to another place, after initial install.

                    In this case, I think I'm going to do the drag and drop, followed by a clean/fresh install from scratch, so that I can get it right the first time this round... then grab only the data that I need from old home, and discard the rest. This also helps me decide how best to partition my system. Thanks so much for everyone's help!

                    Comment


                      #11
                      The issues with "drag and drop" include;
                      1) some things like cache files may cause breakage during the copy function
                      2) if you drag from the wrong place you may miss a hidden files
                      3) moving or copying files about may unintentionally change file ownership or permissions depending on how they're accessed in the future

                      rsync and other utilities are more robust than plain old copy and less likely to fail for these reasons. I would never consider a manual copy a backup. rsync has a very large set of options that will protect you from all these pitfalls assuming you use it properly.

                      On the other hand, if you're just copying your personal files (Documents, Music, et. al.) a plain file copy is fine.

                      Please Read Me

                      Comment


                        #12
                        1. After reinstall, old cache, configs, and the like won't be kept (only in this case), so not worried about breaking them.
                        2. I would be dragging /home/my-home to another location, hoping to get everything inside.
                        3. ownership, and permissions are not an issue, since I can fix those, before grabbing anything, and username will be the same.

                        What I do want to make sure I get are custom items such as ~/.bash_aliases which is a hidden file, and I have a unhidden folder of custom scripts.

                        can a normal drag & drop have the hidden files/folders pitfall with these conditions? If so, I will look into rsync as a fallback option.

                        Comment


                          #13
                          Normal drag&drop is fine. When restoring, I find it's better if the OS you're restoring to is not in use.
                          I usually do this by copying from the old installation to the new one, but it can be done with a live system, with another OS altogether...

                          Rsync, if you can't be bothered with the text options, sudo apt install grsync will give you a GUI for it.
                          It's a bit GTK (but if you're set up to use decent fonts with GTK apps, it's not really ;·) and it's all of 136 kB to download, no libraries, no sweat.

                          Comment


                            #14
                            Originally posted by Don B. Cilly View Post
                            Rsync, if you can't be bothered with the text options, sudo apt install grsync will give you a GUI for it.
                            It's a bit GTK (but if you're set up to use decent fonts with GTK apps, it's not really ;·) and it's all of 136 kB to download, no libraries, no sweat.
                            Thank you! grsync is the answer! Though I'm getting more comfortable with the Linux Command line, I'll use a GUI for ease, whenever possible. I'm using this to backup my home directory as we speak, but still going with the fresh install option, because I'm not entirely sure what is broken. Grsync will definitely be added to my list of must-have apps! Another great piece of feedback!

                            Comment


                              #15
                              Good stuff! Glad this is working out for you.
                              The next brick house on the left
                              Intel i7 11th Gen | 16GB | 1TB | KDE Plasma 5.27.11​| Kubuntu 24.04 | 6.8.0-31-generic



                              Comment

                              Working...
                              X