Bug #1279

Filesystem on NanoBSD is left read/write at first bootup after package reinstallation

Added by Jim P over 2 years ago. Updated 9 months ago.

Status:Resolved Start date:02/11/2011
Priority:High Due date:
Assignee:- % Done:

100%

Category:Operating System
Target version:2.1
Affected version:2.0 Affected Architecture:All

Description

It should be read only by the end of the boot process, but it doesn't seem to be making that change when packages were reinstalled during that boot.

Associated revisions

Revision e8567e89
Added by Jim P about 2 years ago

When doing conf_mount_ro/rw on NanoBSD, pass sync,noatime to mount to preserve the options we have already set in fstab. Ticket #1279 and Ticket #444

Revision 548be1fd
Added by Erik Fonnesbeck about 2 years ago

Workaround for conf_mount_rw/ro during boot to only allow it to change at the start and end. Fixes #1279

Revision 63e18082
Added by Jim P about 2 years ago

Backing this out to see if it unbreaks NanoBSD upgrades with packages involved. Revert "Workaround for conf_mount_rw/ro during boot to only allow it to change at the start and end. Fixes #1279"

This reverts commit 548be1fd6697ab115cbb29d61bc5507744488094.

Revision e1b068d7
Added by Ermal Luçi almost 2 years ago

Ticket #1279. Decrease the refcount even though we're in booting phase. This helps the refcount to work as intended and help in making filesystem read only correctly on embedded platfroms. While here put some exceptions to refcount API and silent any related errors that might trigger. Also take not of the NOTE on the php manual that after a share memory is opened further references to it for size and access mode should be 0.

Revision e15e9c6b
Added by Ermal Luçi almost 2 years ago

Ticket #1279. Decrease the refcount even though we're in booting phase. This helps the refcount to work as intended and help in making filesystem read only correctly on embedded platfroms. While here put some exceptions to refcount API and silent any related errors that might trigger. Also take not of the NOTE on the php manual that after a share memory is opened further references to it for size and access mode should be 0.

History

#1 Updated by Erik Fonnesbeck about 2 years ago

Specifically it was 52f4c092b14cca36bcc430717baf907273b66532

I don't think I saw the discussion on this, so I don't know the exact reason that was done.

#2 Updated by Braden McGrath about 2 years ago

This is happening in RC1; I haven't yet tried a newer snapshot to check there.

#3 Updated by Erik Fonnesbeck about 2 years ago

  • Status changed from New to Feedback
  • % Done changed from 0 to 100

#4 Updated by Jim P about 2 years ago

#5 Updated by Josh Stompro almost 2 years ago

Using nanobsd i386 8.1-release-p4 Jul 8 06:31:18 EDT 2011, after resetting to system default and rebooting, the / mount is set to RW.

It is my impression that it should be RO after the bootup is complete.

Josh

#6 Updated by Jim P almost 2 years ago

  • Status changed from Feedback to New

The filesystem is mounted noatime, so even if it's left rw, it still isn't touched except when the system wants to write out things like the config, which it switched to rw to do anyhow. It should still be fixed at some point before release, but it isn't as critical as it looks.

#7 Updated by Ermal Luçi almost 2 years ago

  • Status changed from New to Feedback

I put a fix that helps this.
Can you please try with latest snapshots?

#8 Updated by Jim P almost 2 years ago

  • Status changed from Feedback to New

It ends up read only but it breaks many other things if you upgrade with packages. GUI doesn't load, many processes die with sig11. Same thing that happened last time a fix was attempted.

#9 Updated by Chris Buechler over 1 year ago

  • Priority changed from Normal to High
  • Target version changed from 2.0 to 2.0.1

#10 Updated by Chris Buechler over 1 year ago

  • Subject changed from Filesystem on NanoBSD is left read/write at bootup to Filesystem on NanoBSD is left read/write at first bootup after package installation

#11 Updated by Chris Buechler over 1 year ago

  • Subject changed from Filesystem on NanoBSD is left read/write at first bootup after package installation to Filesystem on NanoBSD is left read/write at first bootup after package reinstallation

#12 Updated by Chris Buechler over 1 year ago

  • Target version deleted (2.0.1)

#13 Updated by Jim P 12 months ago

  • Target version set to 2.1

Seems we need to revisit this again... If a NanoBSD upgrade reinstalls packages, once again it tends to completely hose the system these days until you reboot. Sometimes the GUI will not respond, many processes still sig11, and so on.

#14 Updated by Phillip Davis 10 months ago

I have also seen this behaviour - both filesystem RW and sig11 process exits. Now I know it is not just me I will look harder and see if there are any interesting things in logs before rebooting, try to work out what combinations of packages etc have the symptoms.

#15 Updated by Ermal Luçi 9 months ago

  • Status changed from New to Feedback

With changes done to the reference counting code this should be fixed.

#16 Updated by Jim P 9 months ago

  • Status changed from Feedback to Resolved

This is fixed from all the tests I've tried, and others on the forum have reported it to be fixed.

Also available in: Atom PDF