Re: Propagating Read-Only?
Re: Propagating Read-Only?
- Subject: Re: Propagating Read-Only?
- From: Kevin Elliott <email@hidden>
- Date: Thu, 11 Feb 2010 16:00:11 -0800
You should not be changing this state while the media is mounted. Doing so has unpredictable consequences, varying between "bizarre" and "catastrophic". A read/write filesystem expects to be able to write data to it's target, so changing that value unpredictably will corrupt the file system as it's metadata writes fail to complete.
On the other hand, if you only change the state when the volume is unmounted (unmount, make read only, remount, etc..) my experience has been that very thing will work as expected.
-Kevin
On Feb 11, 2010, at 2:54 PM, Duane Murphy wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA256
>
> We have a block storage driver kext that can we would like to be able
> to change from read-write to read-only dynamically.
>
> I've worked out how to change the driver to read-only and the
> underlying IOMedia object. But the read-only change doesn't propagate
> any further to the file system IOMedia objects or the file system.
>
> If the underlying media is changed to read-only then an error is
> returned by the file system. However, if the media is then changed
> back to read-write, the file system continues to display an error. I'm
> fine with the error, the problem in this case is getting the file
> system to try again so that it is successful.
>
> How can I go about updating the file system so that it is aware that
> the media has changed to read-only and then later back to read-write?
>
> Thanks for any tips,
>
> ...Duane
>
>
>
>
> -----BEGIN PGP SIGNATURE-----
> Version: PGP Desktop 9.10.0 (Build 500)
> Charset: US-ASCII
>
> wsBVAwUBS3SKo0rg9acQ4r2CAQj5DwgA9zRRyL5bb8B2HkBs0bH0BhJwzc3LUukj
> sWMKIkM2ZMw80gED7ZT1ZPckxVReSDAaEKfe3usM8G3R1KMmq+CQansvm6y6J5lu
> R6r4sDb66POoR2l3xgQ8+iwo/Wl/oCCr/kNQC2DcgmQnD3X41+im3P0YV/NTafZB
> loaitvKGu95nXzVs8eEAkV0oz36Cxi0DhiPWBAzcA/A67sWot0NvaSo3Q0xec49M
> ztfJamVtNhOYrT2FknHXxUWKoiEDJcg+RNbdoRQa3W/JuOeiEL/X2mL1BA4ZuFYE
> SsNqk5aJixcVtcZ1w7KSGfR69oAu6vzOlrRErfxKrHUUaax9mcdc2g==
> =g48r
> -----END PGP SIGNATURE-----
> _______________________________________________
> Do not post admin requests to the list. They will be ignored.
> Darwin-kernel mailing list (email@hidden)
> Help/Unsubscribe/Update your Subscription:
>
> This email sent to email@hidden
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Darwin-kernel mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden