After updating to big sur, I can no longer mount the root as writable (even with SIP disabled):
sudo mount -uw / mount_apfs: volume could not be mounted: Permission denied mount: / failed with 66
How can I fix this?
Ask Different is a question and answer site for power users of Apple hardware and software. It only takes a minute to sign up.Sign up to join this community
DISCLAIMER: have a good backup and plan to erase and reinstall your Mac from the internet before trying this procedure. A mistake can prevent your system from starting without assistance.
csrutil authenticated-root disable
mountand chop off the last s, e.g. if your root is
/dev/disk1s2s3, you'll mount
mkdir -p -m777 ~/mount
sudo mount -o nobrowse -t apfs DISK_PATH MOUNT_PATH, using the values from above
sudo mount -o nobrowse -t apfs /dev/disk1s2 ~/mount
sudo bless --folder MOUNT_PATH/System/Library/CoreServices --bootefi --create-snapshot
My company requires to read/write environment informations under
/data/webapps/appenv. Therefore, this workaround shared by a colleague of mine might not answer this question directly, but it is super useful if you want to write something under your root path!
Create a file:
sudo vim /etc/synthetic.conf.
<dir> /System/Volumes/Data/<dir>. Notice: the space between is a tab!
In my case, it looks like this:
/System/Volumes/Data and do
sudo mkdir <dir>.
sudo chmod -R 777 <dir>.
Finally, reboot, and your directory
<dir> should now be accessible.