Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Root is read only
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Installing Gentoo
View previous topic :: View next topic  
Author Message
Needgentoohelppls
n00b
n00b


Joined: 11 Sep 2024
Posts: 5

PostPosted: Wed Sep 11, 2024 3:34 pm    Post subject: Root is read only Reply with quote

I am new to Linux and was following a tutorial for installing gentoo and I managed to get it installed but now all of root is read only. I believe this is because I copied the tutorials fstab instead of the handbook. My root in fstab is
/dev/sda3 / ext4 ssd,defaults 1 0
The problem is /etc/fstab is unwritable. I don’t know enough and can’t find any quick fix to get this back to what the handbook recommends. Any help would be greatly appreciated
Back to top
View user's profile Send private message
Zucca
Moderator
Moderator


Joined: 14 Jun 2007
Posts: 3695
Location: Rasi, Finland

PostPosted: Wed Sep 11, 2024 3:47 pm    Post subject: Reply with quote

You can try to
Code:
mount -o remount,rw /
to make your root partition writable.

... and welcome to Gentoo. ;)
_________________
..: Zucca :..

My gentoo installs:
init=/sbin/openrc-init
-systemd -logind -elogind seatd

Quote:
I am NaN! I am a man!
Back to top
View user's profile Send private message
Needgentoohelppls
n00b
n00b


Joined: 11 Sep 2024
Posts: 5

PostPosted: Wed Sep 11, 2024 4:17 pm    Post subject: Reply with quote

I tried that and it said “mount point not mounted or bad option.”
Back to top
View user's profile Send private message
Zucca
Moderator
Moderator


Joined: 14 Jun 2007
Posts: 3695
Location: Rasi, Finland

PostPosted: Wed Sep 11, 2024 4:35 pm    Post subject: Reply with quote

Please post the output of the following commands:
    Code:
    mount
    and
    Code:
    lsblk -f


Use wgetpaste if you cannot simply copy & paste.
_________________
..: Zucca :..

My gentoo installs:
init=/sbin/openrc-init
-systemd -logind -elogind seatd

Quote:
I am NaN! I am a man!
Back to top
View user's profile Send private message
szatox
Advocate
Advocate


Joined: 27 Aug 2013
Posts: 3430

PostPosted: Wed Sep 11, 2024 5:32 pm    Post subject: Reply with quote

The line from fstab looks fine.
Did you have a power outage by any chance? Fsck usually is able to fix damaged filesystem. You can try to repair a mounted filesystem as long as it's mounted read-only, so that checks out for you.

Also, you might check dmesg for disk-related errors.
_________________
Make Computing Fun Again
Back to top
View user's profile Send private message
Needgentoohelppls
n00b
n00b


Joined: 11 Sep 2024
Posts: 5

PostPosted: Wed Sep 11, 2024 10:24 pm    Post subject: Reply with quote

For mount I got:
Code:
proc on /proc type proc (rw,nosuid,noexec,relatime)
sysfs on /sys type sysfs  (rw,nosuid,noexec,relatime)
devtmpfs on /dev type devtmpfs (rw,nosuid,noexec,size=10240k,nr_inodes=992020,mode=755,inode64)
devpts on /dev/pts type devpts (rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmode=000)
tmpfs on /dev/shm type tmpfs  (rw,nosuid,nodev,noexec,inode64)
tmpfs on /run type tmpfs (rw,nosuid,nodev,noexec,mode=755,inode64)
/dev/sda3 on / type ext4 (ro,relatime)
securityfs on /sys/kernel/security type securityfs (rw,nosuid,nodev,noexec,relatime)
debugfs on /sys/kernel/debug type debugfs (rw,nosuid,nodev,noexec,relatime)
configfs on /sys/kernel/config type configfs (rw,nosuid,nodev,noexec,relatime)
pstore on /sys/fs/pstore type pstore (rw,nosuid,nodev,noexec,relatime)
efivarfs on /sys/firmware/efi/efivars type efivarfs (rw,nosuid,nodev,noexec,relatime)
none on /sys/fs/cgroup type cgroup2 (rw,nosuid,nodev,noexec,relatime,nsdelegate)
mqueue on /dev/mqueue type mqueue (rw,nosuid,nodev,noexec,relatime)
binfmt_misc on /proc/sys/fs/binfmt_misc type binfmt_misc (rw,nosuid,nodev,noexec,relatime)
/dev/sda1 on /boot type vfat (rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=ascii,shortname=mixed,errors=remount-ro)

I can't connect it to wifi so I had to copy it by hand, also its on a laptop so I don't think an outage would affect anything.
Give me a second to type out the second one
Back to top
View user's profile Send private message
psycho
Guru
Guru


Joined: 22 Jun 2007
Posts: 542
Location: New Zealand

PostPosted: Wed Sep 11, 2024 10:34 pm    Post subject: Reply with quote

The first item in each of those sets of brackets is telling you whether the filesystem is mounted read-write (rw) or read-only (ro). Your root filesystem (/) on which everything else is mounted, is currently mounted ro. Normally Zucca's solution would fix that.

Last edited by psycho on Wed Sep 11, 2024 10:36 pm; edited 1 time in total
Back to top
View user's profile Send private message
grknight
Retired Dev
Retired Dev


Joined: 20 Feb 2015
Posts: 1918

PostPosted: Wed Sep 11, 2024 10:34 pm    Post subject: Reply with quote

Needgentoohelppls wrote:
/dev/sda3 / ext4 ssd,defaults 1 0

The option "ssd" is not valid for ext4
This is what is blocking root mounted rw.


Last edited by grknight on Wed Sep 11, 2024 11:05 pm; edited 1 time in total
Back to top
View user's profile Send private message
Needgentoohelppls
n00b
n00b


Joined: 11 Sep 2024
Posts: 5

PostPosted: Wed Sep 11, 2024 10:50 pm    Post subject: Reply with quote

lsblk -f
Code:

NAME    FSTYPE    FSVER        LABEL            UUID                                           FSAVAIL            FSUSE%      MOUNTPOINTS
sda
    sda1 vfat         FAT32                           8AAB-2A78                                          920.8M        10%             /boot
    sda2 swap         1                                b3b505b7-36c9-43eb-ab4c-30393d63b5ac                                   [SWAP]
    sda3 ext4        1.0                               1288ec8f-8486-4174-9dd1-359345a4adf4    76.3G    8%               /
sdb
sdc    iso9660 Joliet Extension Gentoo-amd-64-@DATESTAMP@ 2024-09-08-18-40-11-00
    sdc1
    sdc2 vfat          FAT12                        3746-86BF
    sdc3 hfsplus                     Gentoo-amd64@DATESTAMP@
    sdc4

better now
Back to top
View user's profile Send private message
Hu
Administrator
Administrator


Joined: 06 Mar 2007
Posts: 22648

PostPosted: Wed Sep 11, 2024 11:07 pm    Post subject: Reply with quote

Needgentoohelppls wrote:
better now
Do you mean you got this to work? As I read grknight's post, you have an invalid mount option in /etc/fstab for /, so any mount call that uses fstab for this filesystem will fail. You need to remove the invalid option. Try mount -o remount,rw / /, which should inhibit using fstab. After that, you can edit fstab to fix it.
Back to top
View user's profile Send private message
Needgentoohelppls
n00b
n00b


Joined: 11 Sep 2024
Posts: 5

PostPosted: Wed Sep 11, 2024 11:21 pm    Post subject: Reply with quote

I just said better now because I fixed the formatting. Thank you so much for that code! I got it fixed and everything's working now.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Installing Gentoo All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum