Welcome
Welcome to refracta

You are currently viewing our boards as a guest, which gives you limited access to view most discussions and access our other features. By joining our free community, you will have access to post topics, communicate privately with other members (PM), respond to polls, upload content, and access many other special features. In addition, registered members also see less advertisements. Registration is fast, simple, and absolutely free, so please, join our community today!

Not formatting /home

Ask your questions here.

Not formatting /home

Postby Mark9 » Thu Feb 02, 2017 4:36 pm

I just created a remaster of Debian 8. I have created many but had not made one for about a year. It runs well as live DVD. All my customizations intact. On the same computer I then installed Ubuntu-Mate 16.04, but this time I created a separate /home partition. Ubuntu runs well on this HP Pavilion notebook computer except for a stall of everything every 6 seconds, for a split second. Annoying enough that I decided to install my Debian remaster again.
I have loaded a lot of information into my /home partition and was hoping to not have to loose this info or have to back it up. I was hoping when using the CLI refractainstaller to have the option of installing without reformatting this existing partition. Using the live remaster, as root, I changed the name of /home/??? so that my new install would leave the files alone if I used my name again for /home.
I found no option during the CLI install to not format /home.
Is there a way to do this?

I went to all the trouble of creating a remaster, but due to this one limitation I either have to move a lot of information, or have to reinstall Debian from scratch again. The Debian installer allows me to not format the /home partition. Then I simply move my files to the new /home folders.
Mark9
 
Posts: 22
Joined: Thu Feb 02, 2017 4:23 pm

Re: Not formatting /home

Postby fsmithred » Thu Feb 02, 2017 7:19 pm

The gui installer has a no_format option that you can choose in the expert install. If you use that option, none of the partitions will be formatted automatically. You can format them during the installation if you tell the installer to run gparted, or you can have them ready before running the installer.

The cli installer does not have that option. If you have a pre-existing /home partition that you want left alone, then don't choose a /home partition and install the whole system to a single partition. Then move things around manually afterward. If you need help with the details of that procedure, just say so.
User avatar
fsmithred
 
Posts: 2093
Joined: Wed Mar 09, 2011 9:13 pm

Re: Not formatting /home

Postby Mark9 » Thu Feb 02, 2017 8:41 pm

Thank you. I wondered if the GUI offered this option. I was avoiding the GUI, as I had in the past ran into issues when using it, that I did not have when creating a remaster with the CLI. If memory serves I was having issues with logins when remastering Debian with Mate. Perhaps the GUI will not have these issues any longer, as you have had at least a year of further work on this. Thank you for your help and your great work.

I have no issues with moving stuff around. I have this computer partitioned with a decent size spot for the OS and a very large home partition, and of course swap partition. It would not make sense in this case to install everything again to just the smaller OS partition, although you are correct, I would have access to all my files, by mounting the former /home partition. I simply would not be able to put my files into the new /home as this first partition is smaller than the amount of data. I do know how to resize partitions and have moved /home before, but it is a lot of bother.

Glad to know there is the option to not format, but use, a preexisting /home partition using the GUI expert install. Thanks again.
Mark9
 
Posts: 22
Joined: Thu Feb 02, 2017 4:23 pm

Re: Not formatting /home

Postby fsmithred » Thu Feb 02, 2017 11:31 pm

I don't know if this is going to do what you are expecting. If you use the no_format option, and you name an existing /home partition as your /home partition to use in the installer, the installer will try to copy all files from /home in the iso to /home on the hard drive. I'd have to check the rsync man page (not fun) to make sure it would not clobber any files on the hard drive. I think it goes by last modification date, so you may be safe, but be careful. Maybe test it on a non-critical system if you have space.

Another approach would be to either comment out the rsync line that copies /home or add /home/* to the excludes file, if all your files are already on that partition.

Also, if your home was in an ubuntu system and you're changing to debian, your desktop configs may be different. You should probably move the old configs out of the way.

Also note that there's a separate excludes file if you have a separate /home or /boot. See /usr/lib/refractainstaller/home_boot_exclude.list
User avatar
fsmithred
 
Posts: 2093
Joined: Wed Mar 09, 2011 9:13 pm

Re: Not formatting /home

Postby vsido » Fri Feb 03, 2017 4:24 am

Yet another option could be to use the services of /etc/skel... If you are using the installer and if you are using a login to the new install the first time

You would simply copy anything of your current home now to /etc/skel and when the install is over and you login the first time, your home would be intact for you just as it is now and just as you wanted it to be even if you did use the format option

Have you looked at any log files to try to determine what the delay might be every 6 seconds? With the consistent pattern that it is showing, it might be east to spot and even easier to correct
User avatar
vsido
 
Posts: 90
Joined: Fri Jan 30, 2015 3:38 pm

Re: Not formatting /home

Postby Mark9 » Fri Feb 03, 2017 5:13 pm

Visido
I am not sure if your instruction makes sense.

I had installed Debian-Mate, customized it, then created a remastered DVD. I had the issue with XDG occur then recur. I wiped the hard drive and installed Ubuntu-Mate LTS, instead. There is a weird intermittent flickering or pausing of everything. It mysteriously starts and mysteriously disappears, so I thought I should install the remastered Debian-Mate. Good to test the install anyway.

I had added a lot of files to the computer, transferred from several old backup hard drives. It took quite awhile to move all this data so I made sure with this OS install(Ubuntu) to create a separate /home partition, for the very reason that I wanted to be able to keep my files on the computer if I had to reinstall or decided to reinstall.

My plan was to boot up the live remastered DVD, access the hard drives /home/* partition as root, rename /home/* to say /backup/*, delete all the hidden config files from /home/*, then install my remaster. I have done this before doing a standard type install without formatting the large /home partition. A new /home folder was created, and all my files were left alone. Once booted into the newly installed OS, I transferred my "backup" to the new /home folders, quick and easy.

I honestly do not know where to look(logs) to identify what is causing the computer(with Ubuntu) to pause everything every 5 seconds. The problem comes and goes. I just installed the AMD microcode package. Perhaps that will be the fix for this machine. I have never seen this error on any of my older computers.

The errors with XDG have occurred on at least 5 computers now, running different DTE's. No clue what causes this and it may be unrelated to the fact that on all of them I have created remasters. In fact it may also have occurred on a 32bit notebook that I did not remaster. I will have to check that computer and see.

This XDG error could be due to the way I set up my computers, though I know other people have had the same renaming or linking of /home/??? to /home/desktop.

Would be nice to learn what causes this and how to prevent it, as I sometimes install my remasters to other peoples computers, and I do not know if the error is passed on.

I plan to do another remaster of Debian-Mate 32bit on another computer. I will try the GUI refractasnapshot on that one to see if it successfully creates a live DVD remaster, like the CLI does.

If this intermittent issue continues on this 64 bit HP laptop, I will boot up my Debian-Mate remaster, install live, the GUI of refractainstaller, and see if I can leave my data alone on the large partition of the hard drive.
Mark9
 
Posts: 22
Joined: Thu Feb 02, 2017 4:23 pm

Re: Not formatting /home

Postby fsmithred » Fri Feb 03, 2017 6:09 pm

You probably know this and just said it wrong (or maybe I read it wrong), but you don't want to rename /home, you want to rename whatever username directory is under /home, and that is the directory that's in the root of that partition. The /home directory is a mountpoint on the root partition.

So for example, if both your existing installation and the DVD have /home/mark, then you would rename mark to backup, and the installer would make a new mark directory with all the files that are in it on the DVD. I guess you would then have duplicates of a lot of files (depending on how similar the contents of the DVD are to what's on your hard drive.)

I recommend excluding all your personal files from the snapshot if they're on a separate partition, and then you can install a new OS on a single partition, adjust fstab to mount the large partition at /home, and copy any new configs over. You avoid the problem of not enough space on the root partition, and you avoid the problem of exceeding the size limit of the iso. (around 4GB)

I think that what you want to do will work. What you definitely should NOT do is decide to install the OS to the big partition that has your files on it. The rsync command for copying the system contains --delete options, so any files that are on the hard drive but not on the live media will be deleted from the hard drive. If you tell the installer you want a separate /home, then it uses a different rsync command for copying /home that doesn't have any --delete options.
User avatar
fsmithred
 
Posts: 2093
Joined: Wed Mar 09, 2011 9:13 pm

Re: Not formatting /home

Postby Mark9 » Fri Feb 03, 2017 11:10 pm

My bad. Correct, I was renaming /home/mark to /home/backup or /home/mark1

I was not saving these files to the remastered DVD. There is at least 100Gb of files. My remaster I created retained all my customizations very well. Except one. A plug-in I used in Firefox called "Betterprivacy" requires a folder to be named for temporary storage of the cookies it removes. Have to make sure to use a /home folder for this that will always be created; or I simply have to do this one thing after installing the remaster: start Firefox, stop Firefox, and Betterprivacy will ask where to save the files. not really much of an issue.
Mark9
 
Posts: 22
Joined: Thu Feb 02, 2017 4:23 pm

Re: Not formatting /home

Postby Mark9 » Sat Feb 04, 2017 2:00 am

If I understand correctly, the simplest thing to do is to install my remaster of Debian-Mate to the first partition where the current Ubuntu is installed. It is about 30Gb.

Then I boot into the new install and edit???, as root, the fstab file, with the goal of mounting the folder "mark" which is preserved on the large partition, to the /home folder on the OS's partition.

Before rebooting with the edited fstab file, I must remove any hidden config files in /mark that are with my backed up files, then transfer over these hidden config files from the new install on the first partition.

I should be able to figure this out as I did something similar years ago when I ran out of space, added another hard drive, and added that space to /home along with the space on the first hard drive.

What happens to the newly created /home/mark folder on the first partition?
Mark9
 
Posts: 22
Joined: Thu Feb 02, 2017 4:23 pm

Re: Not formatting /home

Postby fsmithred » Sat Feb 04, 2017 2:57 am

Yes, that's right. I usually drop to console, log in directly as root, kill the display manager to ensure that the user isn't logged in, rename /home to /home.old, make a new /home folder, edit fstab, mount the big home partition somewhere to copy the necessary configs to /mark, and reboot. I think that's all. And I usually let /home.old sit around until I'm sure I don't need anything else from it.

Add a line to fstab that looks something like this. (with the right device for your home partition)
Code: Select all
/dev/whatever   /home   ext4   defaults,noatime   0   1
User avatar
fsmithred
 
Posts: 2093
Joined: Wed Mar 09, 2011 9:13 pm

Next

Return to Help

Who is online

Users browsing this forum: No registered users and 1 guest

cron
suspicion-preferred