How do I auto mount my partition?

partition entry is not quite correct ( /home is in /dev/sda2 ? ) :

you wrote:

/dev/sda /home ext4 defaults 0 0

( if you write like that then you should replace /dev/sda with:

UUID=number-of-device

you can determine UUID-number with command: sudo blkid)

but it could look like this too ( in older Linux-Versions):

/dev/sda /mnt/ext4 defaults 0 0

or like this:

/dev/sda /media/ext4 defaults 0 0

more is explained here :

https://help.ubuntu.com/community/AutomaticallyMountPartitions

https://help.ubuntu.com/community/Fstab

https://help.ubuntu.com/community/UsingUUID


By /etc/fstabt I assume you meant /etc/fstab. The problem with your mount spec is probably that you want to mount a partition, where /dev/sda refers to the entire disk.

/dev/sda2 /home ext4 defaults 0 0

(as an example). List available partitions using sudo fdisk -l. As dschinn1001 mentions, a UUID is more desirable than a disk/partition number. The corresponding entry in my own fstab runs:

UUID=xxx /home ext4 defaults 0 2

Worth mentioning, /home is where your user accounts live. You have been running apparently with /home sourced from somewhere else. Once you get /home mounting properly from a new partition at boot time, the old home directory will be buried.