"/sbin/mount -uw /" not working? I am trying to add an administrator account on my MacBook Pro using single-user mode. However, the command /sbin/mount -uw / does not seem to work.
Any reason as to why?
/sbin/mount -uw /
apfs_vfsop_mount:1151: Updating mount from /dev/disk1s5 to read/write node is not allowed
mount_apfs: volume could not be mounted: Operation not permitted
mount: / failed with 77
localhost:/ root# /sbin/mount -uw /
apfs_vfsop_mount:1151: Updating mount from /dev/disk1s5 to read/write node is not allowed
mount_apfs: volume could not be mounted: Operation not permitted
mount: / failed with 77
localhost:/ root#
This can happen because System Integrity Protection (SIP) is active. You'll need to disable it first using the command:
csrutil disable

You would commonly do this by rebooting your Mac into Recovery Mode by holding Cmd-R at boot, launch the Terminal and run the command above.