1

I've been trying to combine my SSD and HDD under one partition so my user data ends up on the HDD and everything else ends up on the SSD. However, I've been having the hardest time doing this. Here's what I've done so far:

  1. I started off just mounting the HDD to the /media directory and symbolic link the user data folders (that I put on my HDD) into the \home directory (that was still on my SSD) but this seemed to cause issues with snap apps (I found out that snap apps run in isolated environments that expect the folders to be directly in the /home directory, so symbolic linking isn't going to work)
  2. I completely wiped my Ubuntu installation and manually setup LVM on the SSD and made a non-LVM partition on my HDD that mounts directly to the /home directory, but the capacity of the HDD isn't showing up at all on Nautilus (but it does appear in the Disks app).

So now, I'm at a lost of what to do to make both drives' capacities appear in the file explorer (while keeping them all under the same partition so my snap apps work) all while using LVM (since I plan on upgrading the drives soon).

  • 1
    Making one partition out of an SSD and an HDD doesn't seem like a smart idea. What exactly do you expect of such a setup? – mikewhatever Mar 06 '20 at 14:59
  • I don't want my user data in the SSD, since my SSD is quite tiny compared to the HDD (the SSD is 256 while the HDD is 1TB). –  Mar 06 '20 at 15:00
  • So why then do you want to "combine my SSD and HDD under one partition"? If both are one partition, there is no way to make a separate home folder, which is probably what you need. – mikewhatever Mar 06 '20 at 15:04
  • I need to keep the /home folder under / because my snap apps all completely break and refuse to open because of permission issues (a limitation of snap apps is that it can't access anything outside of the root folder). That's why I want to combine them under the same partition so I don't have to any type of folder moving/symbolic linking. –  Mar 06 '20 at 15:06
  • As said above, you may want to try and set up /home as a separate partition on the HDD. /home is under / by definition, so that should be a problem. To make sure, let's wait for someone else to chime in. – mikewhatever Mar 06 '20 at 15:16
  • But I don't want to use a separate partition. As I said before, doing that actually breaks all of my apps (since they specifically look for \home and completely gets blocked by the system if the files are located anywhere else other than root due to a internal permissions error). From what I heard, LVM is suppose to be able to easily combine drives on the fly without having to mess around with RAIDs –  Mar 06 '20 at 15:29
  • You can uninstall snaps and install the .deb apps. First thing I do with a new install is remove all snaps. Only a few do I want and then install using synaptic or command line to get standard .deb version. – oldfred Mar 06 '20 at 17:35
  • @oldfred That helps me none at all, my primary snap app that I use only has snap installation and nothing else –  Mar 06 '20 at 17:39
  • That is fine, but just for curiosity what app is that? There are cases where an old app needs to be used in a new system or a very new app needs to be used in an old system and a snap resolves dependency issues. – oldfred Mar 06 '20 at 17:47
  • @oldfred The app's called BlueMail, they have no other options for installing the program on Linux. –  Mar 06 '20 at 18:11

1 Answers1

1
  • Make a backup of your important data
  • Create ext4 partition using the whole hdd disk for this in GParted.
  • Log off from desktop environment
  • Switch to tty3: Ctrl+Alt+F3
  • Log in as root
  • Mount your hdd to /mnt: sudo mount /dev/sdXX /mnt
  • Move everything from /home on ssd to your hdd in /mnt/: mv /home/* /mnt/
  • Umount hdd partition: umount /mnt and /home if it is present in fstab. Also comment out current mount point record for /home on SSD in fstab.
  • Add hdd /home mount point to /etc/fstab

    /dev/sdXX /home           ext4    defaults        0       2
    

    where sdXX - your hdd partition.

Gryu
  • 7,559
  • 9
  • 33
  • 52
  • How do you find the hard drive partition without the gui? –  Mar 06 '20 at 18:18
  • sudo fdisk -l | grep -v loop – Gryu Mar 06 '20 at 18:19
  • Annnd the entire installation is completely broken now.. It won't let me log in at all –  Mar 06 '20 at 18:25
  • check ownership of /home/user and if it changed do sudo chown -R user:user /home/user. Does your /home folder contains anything: ls -ailh /home/ – Gryu Mar 06 '20 at 18:27
  • I tried, but it won't do anything now. And I just realized what your answer says is almost exactly what I did the very first time, but except I mounted to the media partition instead of mnt –  Mar 06 '20 at 18:29
  • create new user and add it to sudo group, then try to login using it. adduser user && sudo usermod -aG sudo user. And what does ls -ailh /home/ command shows? – Gryu Mar 06 '20 at 18:30
  • I had to go and reinstall the OS, I did manage to get the drives combined with LVM following these instructions: https://askubuntu.com/a/923943/1051150 but I still have that issue where it doesn't show the HDD capacity in Nautilus (like how the SSD is being displayed as Computer) –  Mar 06 '20 at 23:12
  • Why do you use lvm? I rarely encounter this type of installations. One time when I was in my firiend's house two years ago, he complained that his ubuntu on ssd disk is too slow. He was using lvm partitioning. After I've reinstalled his ubuntu using traditional volumes, it started to work more efficiently. What other file managers you tried? Have you tried Dolphin to see if it shows capacity? What does df -h show? – Gryu Mar 06 '20 at 23:23
  • Sorry for the late reply! I'm using it specifically because it's suppose to be able to be easily resized compared to the traditional partition types. And im not using any other file manager other than Nautilus and running sudo df -h shows the drive total capacity and the amount used like it's suppose to. But it's Nautilus that doesn't seem to show it –  Mar 12 '20 at 14:56