View previous topic :: View next topic |
Author |
Message |
mikefot l33t
Joined: 19 Nov 2014 Posts: 709
|
Posted: Tue Apr 30, 2019 7:48 am Post subject: problem with read only disks after reinstallation [SOLVED] |
|
|
Dear All,
I am running gentoo stable on an amd64 kaveri box.
I have just reinstalled.
When I boot in I am getting errors saying things like "read only disk" in them leading to problems using the
command etc.
My fstab looks like this:
Code: | /dev/sda7 /boot ext2 defaults 0 2
/dev/sda8 / ext4 noatime 0 1
/dev/sda6 none swap sw 0 0
#/dev/cdrom /mnt/cdrom auto noauto,ro 0 0
#/dev/sda10 /boot/efi vfat defaults 0 2 |
Do I need to have e.g. in front of in the partition?
Would a command like this help here:
Code: | mount -o remount,rw / |
?
Comments appreciated.
Regards
MF
Last edited by mikefot on Wed May 01, 2019 10:50 am; edited 3 times in total |
|
Back to top |
|
|
NeddySeagoon Administrator
Joined: 05 Jul 2003 Posts: 54237 Location: 56N 3W
|
Posted: Tue Apr 30, 2019 8:48 am Post subject: |
|
|
mikefot,
Part of the boot process runs rootfsck. When that fails, root stays read only.
dmesg will tell more.
The filesystem type for rootfsck is determined by reading fstab
Code: | /dev/sda8 / ext4 noatime 0 1 |
For you, if root was not ext4, the check would fail.
It will also fail if there are problems that cannot be fixed while the filesystem is read only. _________________ Regards,
NeddySeagoon
Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail. |
|
Back to top |
|
|
mikefot l33t
Joined: 19 Nov 2014 Posts: 709
|
Posted: Tue Apr 30, 2019 9:50 am Post subject: |
|
|
Many thanks for the help again.
I booted up and ran dmesg.
I can't write a file out which In could then post up to the site here.
So I logged out, booted up debian and chrooted into gentoo and ran dmesg and captured the output in the terminal buffer and posted it.
See here:
https://paste.debian.net/1080852/
The output is different when you boot in directly and run dmesg.
I am going to do it again and make some handwritten notes and post them up as well.
Regards
MF
PS When I ran dmesg after booting up gentoo directly right at the end of the output I saw this:
ACPI BIOS Error (bug)
Could not resolve [\SB.ALIBI], AE_NOT FOUND (20180810/psargs_330)
and
ACPI Error: Method parse/execution failed \SB.PC10.VGA.ATC0
AE_NOT_FOUND (20180810) psparse_516
Does this help?
Are there any commands I can run when logged in natively to gentoo that will generate short (few lines) output
I can write down and post up here that will help resolve the problem?
Regards
MF
PS I used ran the Code: | mount -o remount,rw / | command
suggested here:
https://superuser.com/questions/296373/cannot-lock-etc-passwd-try-again-later
and it has solved the problem....
The only thing is I have to run the command again every time I log in.
Regards
MF |
|
Back to top |
|
|
NeddySeagoon Administrator
Joined: 05 Jul 2003 Posts: 54237 Location: 56N 3W
|
Posted: Tue Apr 30, 2019 12:47 pm Post subject: |
|
|
mikefot,
We need the dmesg and errors related to gentoo starting.
Read any dmesg errors related to the root filesystem before you do what follows.
If it says cannot be fixed, run fsck by hand, you need to to that on the unmouted root filesystem.
If that is not there, Code: | mount -o remount,rw / | will make root writable.
Save dmesg ...
Shut down and boot your install environment.
Mount your Gentoo root at /mnt/gentoo
Pastebin the file /mnt/gentoo/dmsg.txt as its your gentoo dmesg.
You could use a USB drive if you don't want to mount root read write.
Later
At least we know that Code: | mount -o remount,rw / | does not destroy your filesystem :) _________________ Regards,
NeddySeagoon
Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail. |
|
Back to top |
|
|
mikefot l33t
Joined: 19 Nov 2014 Posts: 709
|
Posted: Tue Apr 30, 2019 2:01 pm Post subject: |
|
|
Many thanks again.
I logged back into the gentoo installation and attached usb drive to the pc.
I then made a mount point for it.
I then changed directory into it.
I ran your suggested command and instead of complaining about the read only problem it ran happily.
And wrote it to the usb drive.
It would not have worked with the hard drive.
The output is here:
https://paste.debian.net/1080886/
It did occur to me that if I were capable enough I could have found a way to remote login to the new OS from another machine.
Then I could have run dmesg and captured the output on the other pc and posted it.
I will think about that for the future.
I did not run fsck this time although I tried it in the previous boot up of gentoo and it seemed to run OK.
This output was run without any or Code: | mount -o rw,remount / | contamination.
I hope it tells us something helpful here.
Regards
MF |
|
Back to top |
|
|
NeddySeagoon Administrator
Joined: 05 Jul 2003 Posts: 54237 Location: 56N 3W
|
Posted: Tue Apr 30, 2019 3:42 pm Post subject: |
|
|
mikefot,
With a read only root, lots of services don't start, so don't count on being able to ssh in.
Code: | [ 4.649137] EXT2-fs (sda8): error: couldn't mount because of unsupported optional features (244)
[ 4.649815] EXT4-fs (sda8): INFO: recovery required on readonly filesystem
[ 4.649816] EXT4-fs (sda8): write access will be enabled during recovery
[ 4.778289] EXT4-fs (sda8): orphan cleanup on readonly fs
[ 4.778330] EXT4-fs (sda8): 1 orphan inode deleted
[ 4.778331] EXT4-fs (sda8): recovery complete
[ 4.860240] EXT4-fs (sda8): mounted filesystem with ordered data mode. Opts: (null) |
The kernel tries ext3, ext2 then ext4. You don't have ext3 support, so that was skipped. The error: couldn't mount because of unsupported optional features can be ignored.
Boot your install media and run a fsck on your Gentoo root.
I suspect you get the above error every time, so its not really fixed.
You are missing the line Code: | EXT4-fs (sda8): re-mounted. ... |
_________________ Regards,
NeddySeagoon
Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail. |
|
Back to top |
|
|
mikefot l33t
Joined: 19 Nov 2014 Posts: 709
|
Posted: Tue Apr 30, 2019 9:50 pm Post subject: |
|
|
Many thanks for your help again.
I booted up gentoo and ran .
This time it complained about some efi directories on the disk and asked me if I wanted to delete them.
So I said yes.
I then exited from root and as a user I checked to see if this had helped with the read only problem.
It did not.
I then went back to being root again and ran again and it said the disk was clean.
Then I ran the manual remount command which made work when I exited and went back to being a user again.
When I booted back into gentoo again later for the first time two things happened. The first was that the host name was identified.
The second was that startx worked and when I logged into root I could emerge packages without needing to run the manual remount command......
The output from the later log in session is here:
http://dpaste.com/1ECPPRN
It doesn't say that the disk was remounted as far as I can see.
Regards
MF |
|
Back to top |
|
|
NeddySeagoon Administrator
Joined: 05 Jul 2003 Posts: 54237 Location: 56N 3W
|
Posted: Tue Apr 30, 2019 10:11 pm Post subject: |
|
|
mikefot,
The penultimate line ...
Code: | [ 11.121434] EXT4-fs (sda8): re-mounted. Opts: (null) |
This Code: | [ 4.478619] EXT4-fs (sda8): INFO: recovery required on readonly filesystem
[ 4.478620] EXT4-fs (sda8): write access will be enabled during recovery | shouldn't happen.
It indicates an unclean shutdown.
This time it was really fixed and the remount worked.
All the services that fail to start with a read only root are working now. _________________ Regards,
NeddySeagoon
Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail. |
|
Back to top |
|
|
mikefot l33t
Joined: 19 Nov 2014 Posts: 709
|
Posted: Wed May 01, 2019 10:49 am Post subject: |
|
|
A great many thanks for fixing the problem.
Regards
MF |
|
Back to top |
|
|
|