View previous topic :: View next topic |
Author |
Message |
2bdkid n00b
Joined: 26 Jul 2014 Posts: 14 Location: USA
|
Posted: Thu Jul 31, 2014 3:48 am Post subject: [Solved] Unable to mount ext4 partition read/write |
|
|
I just installed Gentoo on my laptop and while booting an error message comes up saying it is unable to mount my root ext4 partition read/write, I can read from it but I cannot write.
I looked through some older threads and they said to enable CONFIG_LBDAF in the kernel but this only applies to x86, not amd64 like my laptop. It does mount just fine in the installation media so it much me a missing kernel option.
I don't know what commands to use to solve this myself so any help would be appreciated. And also bear with me, it'll be hard getting stuff of computer with only CLI lol.
Last edited by 2bdkid on Thu Jul 31, 2014 7:34 pm; edited 1 time in total |
|
Back to top |
|
|
DONAHUE Watchman
Joined: 09 Dec 2006 Posts: 7651 Location: Goose Creek SC
|
Posted: Thu Jul 31, 2014 7:51 am Post subject: |
|
|
boot, run Code: | mount -o remount,rw / | not a fix but may restore capability while fixing. not having the following items has at times been reported as a cause of the reported problem.
Code: | grep -i "CONFIG_DEVTMPFS=y" /mnt/gentoo/usr/src/linux/.config |
Code: | grep -i "CONFIG_DEVTMPFS_MOUNT=y" /mnt/gentoo/usr/src/linux/.config |
Quote: | CONFIG_DEVTMPFS_MOUNT=y |
Code: | grep -i "CONFIG_FSNOTIFY=y" /mnt/gentoo/usr/src/linux/.config |
Code: | grep -i "CONFIG_DNOTIFY=y" /mnt/gentoo/usr/src/linux/.config |
Code: | grep -i "CONFIG_INOTIFY_USER=y" /mnt/gentoo/usr/src/linux/.config |
Quote: | CONFIG_INOTIFY_USER=y |
Code: | grep -i "CONFIG_NET=y" /mnt/gentoo/usr/src/linux/.config |
Code: | grep -i "CONFIG_PROC_FS=y" /mnt/gentoo/usr/src/linux/.config |
Code: | grep -i "CONFIG_SIGNALFD=y" /mnt/gentoo/usr/src/linux/.config |
Code: | grep -i "CONFIG_SYSFS=y" /mnt/gentoo/usr/src/linux/.config |
Code: | grep -i "CONFIG_SYSFS_DEPRECATED is not set" /mnt/gentoo/usr/src/linux/.config |
Quote: | # CONFIG_SYSFS_DEPRECATED is not set |
Code: | grep -i 'CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug"' /mnt/gentoo/usr/src/linux/.config |
Quote: | CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug" |
Code: | grep -i "CONFIG_BLK_DEV_BSG=y" /mnt/gentoo/usr/src/linux/.config |
Quote: | CONFIG_BLK_DEV_BSG=y |
Code: | grep -i "CONFIG_TMPFS=y" /mnt/gentoo/usr/src/linux/.config |
Code: | grep -i "CONFIG_TMPFS_POSIX_ACL=y" /mnt/gentoo/usr/src/linux/.config |
Quote: | CONFIG_TMPFS_POSIX_ACL=y |
Code: | grep -i "CONFIG_TMPFS_XATTR=y" /mnt/gentoo/usr/src/linux/.config |
Quote: | CONFIG_TMPFS_XATTR=y |
_________________ Defund the FCC. |
|
Back to top |
|
|
2bdkid n00b
Joined: 26 Jul 2014 Posts: 14 Location: USA
|
Posted: Thu Jul 31, 2014 1:32 pm Post subject: |
|
|
DONAHUE wrote: | boot, run Code: | mount -o remount,rw / | not a fix but may restore capability while fixing. not having the following items has at times been reported as a cause of the reported problem.
Code: | grep -i "CONFIG_DEVTMPFS=y" /mnt/gentoo/usr/src/linux/.config |
Code: | grep -i "CONFIG_DEVTMPFS_MOUNT=y" /mnt/gentoo/usr/src/linux/.config |
Quote: | CONFIG_DEVTMPFS_MOUNT=y |
Code: | grep -i "CONFIG_FSNOTIFY=y" /mnt/gentoo/usr/src/linux/.config |
Code: | grep -i "CONFIG_DNOTIFY=y" /mnt/gentoo/usr/src/linux/.config |
Code: | grep -i "CONFIG_INOTIFY_USER=y" /mnt/gentoo/usr/src/linux/.config |
Quote: | CONFIG_INOTIFY_USER=y |
Code: | grep -i "CONFIG_NET=y" /mnt/gentoo/usr/src/linux/.config |
Code: | grep -i "CONFIG_PROC_FS=y" /mnt/gentoo/usr/src/linux/.config |
Code: | grep -i "CONFIG_SIGNALFD=y" /mnt/gentoo/usr/src/linux/.config |
Code: | grep -i "CONFIG_SYSFS=y" /mnt/gentoo/usr/src/linux/.config |
Code: | grep -i "CONFIG_SYSFS_DEPRECATED is not set" /mnt/gentoo/usr/src/linux/.config |
Quote: | # CONFIG_SYSFS_DEPRECATED is not set |
Code: | grep -i 'CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug"' /mnt/gentoo/usr/src/linux/.config |
Quote: | CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug" |
Code: | grep -i "CONFIG_BLK_DEV_BSG=y" /mnt/gentoo/usr/src/linux/.config |
Quote: | CONFIG_BLK_DEV_BSG=y |
Code: | grep -i "CONFIG_TMPFS=y" /mnt/gentoo/usr/src/linux/.config |
Code: | grep -i "CONFIG_TMPFS_POSIX_ACL=y" /mnt/gentoo/usr/src/linux/.config |
Quote: | CONFIG_TMPFS_POSIX_ACL=y |
Code: | grep -i "CONFIG_TMPFS_XATTR=y" /mnt/gentoo/usr/src/linux/.config |
Quote: | CONFIG_TMPFS_XATTR=y |
|
Ok I tried enabling all of these and it didn't fix it. I also tried using rootfstype=ext4 in grub and it didn't work.
When booting it says "mount -t ext4 -o ro" Would this be a problem with my fstab?
For my root partition I just have <opts> set at default. |
|
Back to top |
|
|
2bdkid n00b
Joined: 26 Jul 2014 Posts: 14 Location: USA
|
Posted: Thu Jul 31, 2014 1:37 pm Post subject: |
|
|
Ok I just tried using default,noatime,rw in my fstab and that didn't fix anything. |
|
Back to top |
|
|
2bdkid n00b
Joined: 26 Jul 2014 Posts: 14 Location: USA
|
Posted: Thu Jul 31, 2014 1:42 pm Post subject: |
|
|
mount -o remount,rw / gives me "mount: / not mounted or bad option" |
|
Back to top |
|
|
NeddySeagoon Administrator
Joined: 05 Jul 2003 Posts: 54300 Location: 56N 3W
|
Posted: Thu Jul 31, 2014 4:15 pm Post subject: |
|
|
2bdkid,
Is your / listed in /dev
Does it shaw in the output of mount and df.
root is always mounted read only to start with so rootfsck can be run.
When that succeeds. root is remounted rw.
If it fails, you should see something in dmesg.
ext2 and ext3 can mount some ext4 fs, depending on the ext4 options in use.
In some cases, as read only. df and/or mount will show that.
As a throw away snippet, the root entry in fstab is not used to mount root.
That would be chicken and egg, since root has to be mounted to read /etc/fstab.
However, /etc/fstab is used to know the root filesystem type for rootfsck.
I suspect that rootfsck is failing for some reason, so root remains read only.
Is /etc/mtab a real file or a symlink?
For openrc, both work, systemd users must have the symlink. This is the table of mounted filesystems and will be consulted by -o remount _________________ Regards,
NeddySeagoon
Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail. |
|
Back to top |
|
|
2bdkid n00b
Joined: 26 Jul 2014 Posts: 14 Location: USA
|
Posted: Thu Jul 31, 2014 5:31 pm Post subject: |
|
|
NeddySeagoon wrote: | 2bdkid,
Is your / listed in /dev
Does it shaw in the output of mount and df.
root is always mounted read only to start with so rootfsck can be run.
When that succeeds. root is remounted rw.
If it fails, you should see something in dmesg.
ext2 and ext3 can mount some ext4 fs, depending on the ext4 options in use.
In some cases, as read only. df and/or mount will show that.
As a throw away snippet, the root entry in fstab is not used to mount root.
That would be chicken and egg, since root has to be mounted to read /etc/fstab.
However, /etc/fstab is used to know the root filesystem type for rootfsck.
I suspect that rootfsck is failing for some reason, so root remains read only.
Is /etc/mtab a real file or a symlink?
For openrc, both work, systemd users must have the symlink. This is the table of mounted filesystems and will be consulted by -o remount |
Yes I can see sda3 in /dev
df says it cannot read table of mounted file systems
/etc/mtab is just a file, I'm using openrc
Here is dmesg: https://dl.dropboxusercontent.com/u/74532228/dmesg.txt
Would it be best to reinstall and have a seperate boot partition? |
|
Back to top |
|
|
2bdkid n00b
Joined: 26 Jul 2014 Posts: 14 Location: USA
|
Posted: Thu Jul 31, 2014 5:48 pm Post subject: |
|
|
I have a feeling it's because I need a boot partition. I'm just going to reinstall, I wont lose anything. |
|
Back to top |
|
|
2bdkid n00b
Joined: 26 Jul 2014 Posts: 14 Location: USA
|
Posted: Thu Jul 31, 2014 7:33 pm Post subject: |
|
|
Well I just reinstalled and added a boot partition. Everything is working fine now. |
|
Back to top |
|
|
NeddySeagoon Administrator
Joined: 05 Jul 2003 Posts: 54300 Location: 56N 3W
|
Posted: Thu Jul 31, 2014 7:58 pm Post subject: |
|
|
2bdkid,
By reinstalling, you have lost a learning opportunity.
Your dmesg says Code: | [ 10.945769] EXT4-fs (sda3): Unrecognized mount option "default" or missing value | which tells that your /etc/fstab was incorrect. Reinstalling allowed you an opportunity to not make that mistake again. A /boot partition is needed only if
a) the BIOS cannot read the entire HDD.
b) root on raid/LVM/encrypted or other less common installs.
Your dmesg also says Code: | [10841.343765] FAT-fs (sdc1): Volume was not properly unmounted. Some data may be corrupt. Please run fsck. |
You probably removed tho volume without unmounting it first. Thats a very bad thing. _________________ Regards,
NeddySeagoon
Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail. |
|
Back to top |
|
|
DONAHUE Watchman
Joined: 09 Dec 2006 Posts: 7651 Location: Goose Creek SC
|
Posted: Thu Jul 31, 2014 8:01 pm Post subject: |
|
|
dmesg said Quote: | EXT4-fs (sda3): Unrecognized mount option "default" or missing value | correct spelling is defaults, apparently got corrected during the reinstall _________________ Defund the FCC. |
|
Back to top |
|
|
2bdkid n00b
Joined: 26 Jul 2014 Posts: 14 Location: USA
|
Posted: Fri Aug 01, 2014 12:53 am Post subject: |
|
|
I see what you mean. I guess I missed that in dmesg. |
|
Back to top |
|
|
|