Resizing /home by deleting it and recreating it

etcetera

Active Member
Joined
Mar 10, 2024
Messages
154
Reaction score
35
Credits
1,843
Just installed RHEL 8.9
Went with the default filesystem size and LVM. Shouldn't have.
Out of the 4TB SSD, it allowed 3.6TB to /home. Exactly what I don't need and the / partition is 80GB. You got to be kidding me. I need at least 500GB in /var and a lot in /usr also.
And because the filesystem is xfs, there is no way to shrink /home. What a stupid move from Redhat. They detected a 4TB disk and allocated only 80GB to the root partition??
I see this reminds me why I always go with custom layout, except that I also wanted LUKS encryption and there was no option during the install to do LUKS and custom layout.

I am thinking how do to do this. Add a root-privileged user with its home directory in /var. Delete the /home Logical Volume. Recreate the /home LVOL much smaller, say 400GB. Now the root volume group rhel should have extra 3TB in it which I can use to expand /, am I missing anything, or will I have issues expanding the / LVOL?
 


What a stupid move from Redhat. They detected a 4TB disk and allocated only 80GB to the root partition??

When things like this happen I try to keep a few things in mind.

I'm using completely free apps designed by well qualified people who know what they are doing.

Crap happens, bugs happen, they are human. They don't get paid when everything goes off without a hitch.

Those people love what they do. They love it so much they want to share it with anyone who wants to use it at no cost.

They leave their creations open to improvement, personalization or customizations as I see fit. I don't have to pay for permission to make changes.

The Linux community, especially this one is hands down the friendliest group of people I have ever had the privilege of knowing.

Some of the people here could very well be one of those people you're saying do stupid things.

You may very well be asking for help from one of those people who do stupid things.

I am using apps someone else created for their own personal needs. Their needs are probably different than mine. Maybe the problems you're having serves some purpose they intentionally designed for themselves.
 
Last edited:
Redhat is a commercial, paid product. I am paying for this stuff. Look at Redhat's market capitalization share.
Ubuntu or some fly-by-night distro is one thing. This is the distro used in many commercial data centers. I will have to make it STIG-compliant, which is why I made it LUKS-encrypted. They want a very specific install.
I am not doing this install for myself if it's not clear. It runs on hardware which costs like a high-end SUV.

I don't get the reluctance to look at problems in a distro and always blame the end-user, or trivialize the bugs. They need to be aware of the bugs and user feedback. Yeah, I know there is a Redhat community. I am on there also.
Just fix it, that's it and there is no more discussion. Allocating almost all to /home does not reflect the needs of commercial data center stuff, how could they ever come up with that.
Their lack of foresight added some extra hours to my workload. I can't get into the system remotely, I have to be on site to debug this, which I should not have to do .
This is BTW a technical question, I need a technical solution not generalities.
 
Redhat is a commercial, paid product. I am paying for this stuff. Look at Redhat's market capitalization share.
Ubuntu or some fly-by-night distro is one thing. This is the distro used in many commercial data centers. I will have to make it STIG-compliant, which is why I made it LUKS-encrypted.
I am not doing this install for myself if it's not clear. It runs on hardware which cost like a high-end SUV.

I stand corrected. I apologize.

Thank you
 
I spent time yesterday, trying to get RHEL 8 to get tethered via phone. Since I don't have a wifi card. Finally got it to work at the glorious 50Mb/second. Now looking at the /home situation, since I don't have the space to install the software I need and it's hungry for space. I can install it anywhere but it consumes /var. I should not have to deal with problem and hosing the system is not an option so I am frustrated. I am pretty sure I can unmount /home and if I am not in it, if the user's directory is created elsewhere with the useradd command.
 
Just in case there's no resolution here, if you're paying for RHEL you're also paying for support. So, you can make use of that resource as well - at least you should be able to.
 
Are you using LVM? Standard partitons?
If you're using LVM, you can grow partitions, or you can
just make another logicalVolume and add the free disk space to it.
If you're using standard partitions, just add another partition.

80GB for / seems like a lot, and I have a hard time imaging what you would need 500GB in /var for.
But it is what it is. If you absolutely need files to go into these directories, you can always create another
partition and link it to a directory there.

I don't think I have a single system with over 30GB for / and 30GB for /var.

As for moving /home, I would create a second user account, and create their home directory somewhere else
Then login as that account while moving the original /home/user account.
 
I spent time yesterday, trying to get RHEL 8 to get tethered via phone. Finally got it to work at the glorious 50Mb/second.

This is a bit off topic, but related to your post. Maybe you'll find it useful so I'm sharing it here.

I use my phone hotspot and nothing else. I recently moved from a very rural area, 42 miles from the closest tower. My connection was nearly always fantastic. 2K videos were absolutely no problem, sometimes even 4K and I had little to zero freezing watching IPTV. I had the same VPN installed on both my PC and my phone. It had to be on both to get the speeds I was getting.

Almost everyone I've talked says that VPN's slow down the connection speed. My experience with my particular VPN increases my speed dramatically. Now that I'm using Linux, it doesn't seem to make that much difference. However, I haven't had enough time lately to figure out how to tweak settings to know for sure it won't help though.

BUT, without the VPN on my phone the connection isn't very fast.

I'm not in the business of plugging products or services, but if you want to know which one I use I'll be happy to share with you.

UPDATE

I forgot to mention that there was one particular time of day in late winter when the speed wasn't reliable. Other than that and if the settings were right, it was fantastic.
 
...am I missing anything...

Four (4) things at least that I can see:

1. Just in case of any misapprehension on your part, we are not an official arm nor organ of Linux, just scored the dot org name - we are manned by volunteer staff and helpers who share a love of Linux and have varying skills in various departments.

So

Just fix it, that's it and there is no more discussion.

...doesn't cut it, here.

2.

...how could they ever come up with that.

Have you asked your RHEL Support team?

3. In future, you could look at the list of subforums here and choose where to Post in a more discerning manner.

This does not constitute a General Linux Question, it should be in Red Hat and derivatives and I am moving it there when I complete this Post.

4. Manners and civility to the Members of this Forum.


The above points are not generalities, they should serve as a reminder and a warning.

Thank you

Chris Turner
wizardfromoz
 
Just in case there's no resolution here, if you're paying for RHEL you're also paying for support. So, you can make use of that resource as well - at least you should be able to.

that is a good point and I can engage that 2-hour response thing.
I think it's pretty basic and I can deal with it myself. Will escalate to them if I run into issues.
 
Four (4) things at least that I can see:

1. Just in case of any misapprehension on your part, we are not an official arm nor organ of Linux, just scored the dot org name - we are manned by volunteer staff and helpers who share a love of Linux and have varying skills in various departments.

So



...doesn't cut it, here.

2.



Have you asked your RHEL Support team?

3. In future, you could look at the list of subforums here and choose where to Post in a more discerning manner.

This does not constitute a General Linux Question, it should be in Red Hat and derivatives and I am moving it there when I complete this Post.

4. Manners and civility to the Members of this Forum.


The above points are not generalities, they should serve as a reminder and a warning.

Thank you

Chris Turner
wizardfromoz

It was more of a rhetorical statement, addressed to nobody in particular. Certainly to nobody on this forum.
I get that .org is a private community. I am thinking out loud.
You tend to do that when you are stuck in a data center at 8PM on Saturday night. I am forced to work with an OS I don't much care for. It has become kind of a religion. Too much of a deviation from mainstream Linux with its own peculiarities.
I did UNIX admin for a long time and Linux for the last ten.

But "you" I do not mean "you", or anyone else. It is a metaphor.

I assumed all that would be beyond self-evident. But I will clarify the obvious. You reading my statements like a command line argument. Highly technical people tend to do that, take things literally, linguistically precise.

I found bugs in RHEL, Kali Linux.. Xubuntu.. it's too much work submitting all the official bug reports, I am just tired of doing it. It is easier to rant about it on the forums instead of containing frustration inside oneself, even while being aware it is going nowhere. I thought this would be a community capable of both "listening", "hearing" and empathizing with one's plight. Because it's not about just the keyboard and command line switches. Otherwise I would find the man page sufficient without any human interaction.
 
Are you using LVM? Standard partitons?
If you're using LVM, you can grow partitions, or you can
just make another logicalVolume and add the free disk space to it.
If you're using standard partitions, just add another partition.

80GB for / seems like a lot, and I have a hard time imaging what you would need 500GB in /var for.
But it is what it is. If you absolutely need files to go into these directories, you can always create another
partition and link it to a directory there.

I don't think I have a single system with over 30GB for / and 30GB for /var.

As for moving /home, I would create a second user account, and create their home directory somewhere else
Then login as that account while moving the original /home/user account.
Yes, LVM. I always pick LVM. Used for a long time, especially in environments with SAN/external storage and databases where there is always tons of space being allocated and resized.

I tried to shrink /home, errored out. Interesting idea you have. I can make second /home2, copy all the stuff from /home to it, then create a user with the dir in /home2, blow away /home, then extend /.
I am trying to avoid going into single user mode as the box I have reboots very slowly.

80GB is not much if you are running real apps. This is not my home computer, to be clear.
I am running docker and a bunch of containers. I am not going to do "spaghetti code" and links to another partition.. poor sysamin practice. Not that I am a perfectionist but this thing irritates me enough to blow it away and reinstall the OS with the custom parameters I wanted, but I think I can fix it. I am trying to get at the root cause of it where RH's thinking went so sideways that they allocate 80GB on a workhorse production system and 3.6TB for /home.
(80TB of RAID5 storage, 1TB of RAM, 8TB of RAID'ed boot SSDs and I am not even going to list the GPUs)
It was specifically custom-built for a performance project. I get that RH doesn't know anything about it but it's plug and play configuration is deficient, knowing that most users are admins in data centers. If you just mess with Linux on your private box, RHEL is not what you are going to install, rightly so. Any kind of a production system is going to heavily hit /var and /usr. Like /var/log and stuff you install in /usr/local/bin/ like Oracle, or maybe /opt, but I go for /usr/local. You know, old habits.
You certainly can't put Oracle in /home.

Anyway, thanks for your support, as always.
 
This is a bit off topic, but related to your post. Maybe you'll find it useful so I'm sharing it here.

I use my phone hotspot and nothing else. I recently moved from a very rural area, 42 miles from the closest tower. My connection was nearly always fantastic. 2K videos were absolutely no problem, sometimes even 4K and I had little to zero freezing watching IPTV. I had the same VPN installed on both my PC and my phone. It had to be on both to get the speeds I was getting.

Almost everyone I've talked says that VPN's slow down the connection speed. My experience with my particular VPN increases my speed dramatically. Now that I'm using Linux, it doesn't seem to make that much difference. However, I haven't had enough time lately to figure out how to tweak settings to know for sure it won't help though.

BUT, without the VPN on my phone the connection isn't very fast.

I'm not in the business of plugging products or services, but if you want to know which one I use I'll be happy to share with you.

UPDATE

I forgot to mention that there was one particular time of day in late winter when the speed wasn't reliable. Other than that and if the settings were right, it was fantastic.

I am running firewall on the RHEL install, I have to, because once I bring it up via my connection, there is nothing that stands between it. I am cognizant it slows me down.
When you plug it in, it just wasn't recognized.
I got it working but I had to go through some funky steps

restart neworkmanager
ifconfig <interface> up
unplug the existing ethernet cable as it was somehow interfering.

redhat wasn't very helpful. I got their account, looked it up in the knowledge base, they suggested:
systemctl stop ModemManager
which did not help.
Officially it is: Bug 1421400 - Unable to tether internet from Android phone via USB
 
I am running firewall on the RHEL install, I have to, because once I bring it up via my connection, there is nothing that stands between it. I am cognizant it slows me down.
When you plug it in, it just wasn't recognized.
I got it working but I had to go through some funky steps

restart neworkmanager
ifconfig <interface> up
unplug the existing ethernet cable as it was somehow interfering.

redhat wasn't very helpful. I got their account, looked it up in the knowledge base, they suggested:
systemctl stop ModemManager
which did not help.
Officially it is: Bug 1421400 - Unable to tether internet from Android

It's clear to me that your knowledge is vastly superior to mine concerning your issue!

Even with the things I do know very well, when I get frustrated sometimes I forget about the most elementary things. When I get like that, those simple things are often the cause of all of the trouble.

That said, did you enable 'Developer Options' on your Android and enable debugging? You've probably already done this, but if you're, like me it could be the problem. I've had to do this with every Android when I tether instead of use the hotspot.

Or maybe you need different drivers now. Of course that would mean downloading and installing them manually.

UPDATED RESPONSE.

Sometimes system updates on my phone reset changes I made in settings. I change a lot of them on my phone and this has been a problem for me.
 
Last edited:
I am running firewall on the RHEL install, I have to, because once I bring it up via my connection, there is nothing that stands between it. I am cognizant it slows me down.
When you plug it in, it just wasn't recognized.
I got it working but I had to go through some funky steps

restart neworkmanager
ifconfig <interface> up
unplug the existing ethernet cable as it was somehow interfering.

redhat wasn't very helpful. I got their account, looked it up in the knowledge base, they suggested:
systemctl stop ModemManager
which did not help.
Officially it is: Bug 1421400 - Unable to tether internet from Android phone via USB

I've found that when I ask for a refund because I can't figure out something and neither can the people who sold something to me, they suddenly become a lot more determined to fix my problem. And I get to learn more :D
 
Yep. I did all that. The phone would tether my notebook but not the Linux server.

Oh and I learned something new. Not all type-C to type-A cables can do data/tether. Most are just for charging. Most of my cables are. I spent an hour trying to get a non-data cable to tether until I tried another one and it instantly tethered my notebook. Then I spent another hour tethering the Redhat server.
Now I have to deal with the /home issue and hope I don't hose a production server. Well which needs to go into production and hosing it is just not an option.

I did hose a redhat machine recently. And it was due to something I read online. I will post about it in another thread.
 
I fixed it, surprisingly it worked well. Created a user with the home directory in /usr/local/bin, added to sudo.
Logged in as that user, lvremove /dev/rhel-home
lvcreate -L 400Gib /dev/rhel-home rhel
The usual resize2fs command failed on the xfs filesystem, had to do this:

xfs_growfs /mount/point -D size

Wonder what the advantages of the xfs filesystem are, thus far I am only seeing disadvantages. Can't dynamically resize.

lvextend -L 3.5TB /dev/rhel-root
xfs_growfs /dev/rhel-root

Now got 3.5TB in /var
 
Yes, LVM. I always pick LVM. Used for a long time, especially in environments with SAN/external storage and databases where there is always tons of space being allocated and resized.

I tried to shrink /home, errored out. Interesting idea you have. I can make second /home2, copy all the stuff from /home to it, then create a user with the dir in /home2, blow away /home, then extend /.
I am trying to avoid going into single user mode as the box I have reboots very slowly.

80GB is not much if you are running real apps. This is not my home computer, to be clear.
I am running docker and a bunch of containers. I am not going to do "spaghetti code" and links to another partition.. poor sysamin practice. Not that I am a perfectionist but this thing irritates me enough to blow it away and reinstall the OS with the custom parameters I wanted, but I think I can fix it. I am trying to get at the root cause of it where RH's thinking went so sideways that they allocate 80GB on a workhorse production system and 3.6TB for /home.
(80TB of RAID5 storage, 1TB of RAM, 8TB of RAID'ed boot SSDs and I am not even going to list the GPUs)
It was specifically custom-built for a performance project. I get that RH doesn't know anything about it but it's plug and play configuration is deficient, knowing that most users are admins in data centers. If you just mess with Linux on your private box, RHEL is not what you are going to install, rightly so. Any kind of a production system is going to heavily hit /var and /usr. Like /var/log and stuff you install in /usr/local/bin/ like Oracle, or maybe /opt, but I go for /usr/local. You know, old habits.
You certainly can't put Oracle in /home.

Anyway, thanks for your support, as always.
You have no choice, to resize the LVM you MUST be in single user mode or it can't work. Suck it up buttercup, you'll have to wait for the boot up and single user mode.
 
I'm curious why your root partition needs to be bigger than 80GB?

I understand 4TB is pretty massive, and I am not a server person like you (i just use linux distros for home and creative use). What goes in the root directory in that context?
 
As I explained, I did it all in multiuser mode. /home is simple, it's the var and stuff that would require single.

I don't need terabates in / it's just that it is a single partition - everything is under / except for /home (Redhat's weird partitioning scheme). Thus if I need 3TB in /var, I need to expand / to that size.

The other option I could have engaged is gparted, I've used it before and it's pretty good at shrinking / resizing partitions.
But in my case, deleting completely and recreating was safer. I am just kind of mildly irritated by lack of critical thinking and being proactive. Who needs 98% of space in the /home partition? On a production machine? That's what I always pick my own sizes, the one time that I don't, I have regrets.

I mean RHEL is a OS for production enterprise grade data centers, it is a very poor choice for a personal machine unless just must have it. What system layout would work in a data center? With storage perhaps measured in Terabytes if not Petabytes? Perhaps a bit different than a personal Buntu box with 500GB SSD.
 
Last edited:

Members online


Top