LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Bedrock Linux
User Name
Password
Bedrock Linux This forum is for the discussion of Bedrock Linux.

Notices


Reply
  Search this Thread
Old 01-23-2018, 03:00 PM   #1
pressman57
Member
 
Registered: Feb 2005
Location: Escondido Ca.
Distribution: Arch
Posts: 106

Rep: Reputation: 21
Gentoo mounts read-only


Hi all. Thanks for reading.

I've got Ubuntu-Mate and Arch getting along together on one box and I'd like Gentoo and Arch on another. With Ubuntu it was just a matter of adding rw to Grub, but for the life of me I can't keep Gentoo from changing back to read-only, and there it stays.

I have enjoyed myself immensely with this distribution. Many thanks.
 
Old 01-23-2018, 03:49 PM   #2
Emerson
LQ Guru
 
Registered: Nov 2004
Location: Saint Amant, Acadiana
Distribution: Gentoo ~arch
Posts: 6,311

Rep: Reputation: Disabled
What you mean by "changing back"? Kernel mounts root filesystem ro, this is a feature. Then kernel runs init system and it is supposed to remount root filesystem rw. So either there is filesystem corruption (then it remains ro as precaution) or your init system does not run properly.
 
Old 01-23-2018, 04:10 PM   #3
pressman57
Member
 
Registered: Feb 2005
Location: Escondido Ca.
Distribution: Arch
Posts: 106

Original Poster
Rep: Reputation: 21
The kernel boots as rw and a line on the screen reads "Changing to ro" or words to that effect. It's as though it's trying to mount as rw and then changes to ro.

Whether or not this is the case the init system ran fine without Bedrock installed.

Last edited by pressman57; 01-23-2018 at 04:19 PM.
 
Old 01-24-2018, 06:22 AM   #4
ParadigmComplex
Bedrock Linux Founder
 
Registered: Feb 2016
Distribution: Bedrock Linux
Posts: 60

Rep: Reputation: Disabled
Quote:
Originally Posted by Emerson View Post
What you mean by "changing back"? Kernel mounts root filesystem ro, this is a feature. Then kernel runs init system and it is supposed to remount root filesystem rw. So either there is filesystem corruption (then it remains ro as precaution) or your init system does not run properly.
Bedrock Linux tries to squeeze its own initialization code between the initrd and init-proper. As of the current release, this relies on the filesystem being read-write. Since many initrds support telling the initrd to mount the filesystem read-write by putting `rw` on the boot loader kernel line, the Bedrock Linux installation instructions indicate a user should do this. However, apparently that's not a universal standard. No filesystem corruption issues necessary here, nor issues with the (eventual) init.

Rather than require people mess with the bootloader, I plan on having the early Bedrock Linux code remount the filesystem read-write itself in the next release.

Quote:
Originally Posted by pressman57 View Post
Hi all. Thanks for reading.

I've got Ubuntu-Mate and Arch getting along together on one box and I'd like Gentoo and Arch on another. With Ubuntu it was just a matter of adding rw to Grub, but for the life of me I can't keep Gentoo from changing back to read-only, and there it stays.

I have enjoyed myself immensely with this distribution. Many thanks.
It looks like Gentoo's initrd uses different flags from the other initrds I've tested when I wrote those instructions. Most Gentoo people apparently figured out what they needed to do to make it work and fixed it themselves such that I never noted the fact I need to change the instructions there. Looking at IRC logs, I found someone who I think uses a Gentoo initrd stating:

Code:
linux/kernel-genkernel-x86_64-4.4.26-gentoo root=UUID=<...> rw rootflags=rw init=/bedrock/sbin/brn real_init=/bedrock/sbin/brn resume=UUID=<...>
In part of Gentoo where the instructions indicate you should put `rw init=/bedrock/sbin/brn`, try putting `rw rootflags=rw init=/bedrock/sbin/brn real_init=/bedrock/sbin/brn` instead. See if that does it. If it does, let me know and I'll update the installation instructions to mention it accordingly.

If not, we can get the Bedrock Linux subsystem that expects read-write to just remount it itself. This is probably what I should have done originally instead of asking people to mess with their boot loader. I didn't realize at the time that `rw` in the kernel line was not a universal standard. So, if the above proposal fails, let's try getting `brn` to mount the filesystem read-write. Open up `/bedrock/sbin/brn` (or maybe boot with some other medium if required then mount bedrock into it then `<mount-point>/bedrock/sbin/brn>`. You should see something like this:

https://github.com/paradigm/bedrockl...drock/sbin/brn

On line 419, just after the `print_logo` statement:

https://github.com/paradigm/bedrockl.../sbin/brn#L419

try adding

Code:
mount -o remount,rw /
That should resolve it.
 
1 members found this post helpful.
Old 01-24-2018, 07:18 PM   #5
pressman57
Member
 
Registered: Feb 2005
Location: Escondido Ca.
Distribution: Arch
Posts: 106

Original Poster
Rep: Reputation: 21
Thanks very much for the information, I'll have time over the weekend to give it a try so I'll report back then.
 
Old 01-27-2018, 02:19 PM   #6
pressman57
Member
 
Registered: Feb 2005
Location: Escondido Ca.
Distribution: Arch
Posts: 106

Original Poster
Rep: Reputation: 21
The first option worked. Thanks a lot.

I've got another issue with networking. Is there anything special I have to do or did I screw I up re-installing Gentoo?
 
Old 01-27-2018, 02:41 PM   #7
ParadigmComplex
Bedrock Linux Founder
 
Registered: Feb 2016
Distribution: Bedrock Linux
Posts: 60

Rep: Reputation: Disabled
Happy to hear it worked for you.

I can't confidently comment on your issue with networking without more detail. Ideally you shouldn't have to do anything special, but it's possible you ran into a bug in Bedrock Linux. There are some known quirks with how it handles /etc/resolv.conf which may be a likely culprit. I'm experimenting with clean solutions for them for the next release, but it'll be a bit.

EDIT: If you are doing a hijack install, you should be able to test networking before hijacking. If it works before hijack, but not immediately afterwards, that's probably Bedrock's fault.

Last edited by ParadigmComplex; 01-27-2018 at 02:51 PM.
 
Old 01-28-2018, 12:25 PM   #8
pressman57
Member
 
Registered: Feb 2005
Location: Escondido Ca.
Distribution: Arch
Posts: 106

Original Poster
Rep: Reputation: 21
Networking did work before Bedrock was installed (I had to emerge git), but I found a work around: I just run dhcpcd enp0s3 and it's up.
 
Old 01-28-2018, 01:09 PM   #9
ParadigmComplex
Bedrock Linux Founder
 
Registered: Feb 2016
Distribution: Bedrock Linux
Posts: 60

Rep: Reputation: Disabled
Excellent, glad you got it working. Don't hesitate to let me know if you run into anything else.
 
Old 01-31-2018, 08:02 PM   #10
pressman57
Member
 
Registered: Feb 2005
Location: Escondido Ca.
Distribution: Arch
Posts: 106

Original Poster
Rep: Reputation: 21
Actually, no default services were started using the grub-line method.
Adding the mount command to brn resulted in a stable system.
 
Old 01-31-2018, 08:18 PM   #11
ParadigmComplex
Bedrock Linux Founder
 
Registered: Feb 2016
Distribution: Bedrock Linux
Posts: 60

Rep: Reputation: Disabled
Could you elaborate? I don't know what you mean by "the grub-line method", nor which "mount command" to which you are refering.
 
Old 01-31-2018, 08:53 PM   #12
pressman57
Member
 
Registered: Feb 2005
Location: Escondido Ca.
Distribution: Arch
Posts: 106

Original Poster
Rep: Reputation: 21
Sorry I wasn't clear. I was referring to the above explained methods of mounting Gentoo as read-write.

As i understand the instructions in the first method I was to add : init=/bedrock/sbin/brn real_init=/bedrock/sbin/brn` grub's command line.

In the second I was to insert 'mount -o remount,rw /' in line 419 to /bedrock/sbin/brn.
 
Old 02-01-2018, 05:48 AM   #13
ParadigmComplex
Bedrock Linux Founder
 
Registered: Feb 2016
Distribution: Bedrock Linux
Posts: 60

Rep: Reputation: Disabled
Ahh, gotcha. I lost context, sorry. Okay, that's good to know - I'll make sure the 'mount -o remount,rw /' method is in use for the next release. Even if you could get it working by messing with the bootloader, that's one installation step we can remove.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Mounts are Read-Only After Ubuntu 9.10 BloodBlight Linux - General 0 11-01-2009 07:09 PM
USB HardDrive mounts read-only. Is there anyway to make it read-write? Fritz_Katz Linux - Hardware 7 09-13-2007 06:50 PM
rwcd mounts as read-only somae Slackware 5 02-10-2007 03:15 PM
NTFS mounts; but I can't read it JulienPDX Linux - Newbie 13 07-02-2006 03:03 PM
FAT mounts read-only jogurt666 Linux - General 3 02-12-2004 06:13 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Bedrock Linux

All times are GMT -5. The time now is 07:41 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration