How does Mac OS X decide which volumes to mount? One of my disks doesn't mount at boot

apple.stackexchange https://apple.stackexchange.com/questions/275507

  •  14-04-2021
  •  | 
  •  

Question

I have four disks in my Mac Pro. The boot disk and two others mount when OS X starts but the fourth one does not. I can mount it in Disk Utility and it appears to be all right.

How can I tell Mac OS X to mount it?

diskutil list /dev/disk2s2
/dev/disk2
   #:                       TYPE NAME                    SIZE       IDENTIFIER
   0:      GUID_partition_scheme                        *1.0 TB     disk2
   1:                        EFI                         209.7 MB   disk2s1
   2:                  Apple_HFS Broken                  999.9 GB   disk2s2

Update: There seems to have been a misunderstanding about this question. I do not want to find out what's wrong' with my disk I named "Broken". It appears to work fine. I also reformatted it several times. I want to know how to tell OS X to mount a specific disk at boot. I named the disk "Broken" because it doesn't mount automatically, not because I have any problems with it as such and nor are there any error messages. Just forget I mentioned the disk and answer the question how to tell OS X which disks to mount at boot, if you know the answer. Thanks.

Was it helpful?

Solution 4

The volume is mounted automatically again.

I never did find out how Mac OS X decides which volumes to mount and which not. But whatever it is, Mac OS decided to mount the volume again. Apparently the solution is to reboot until it works.

OTHER TIPS

OS X uses diskarbitrationd which discovers new storage devices and probes them for mountable filesystems. The Disk Arbitration framework handles notifying applications of disk mount/unmount events, and allows them to influence whether a volume is mounted or not.

Consult the man page for diskarbitrationd for very limited further information; for example, diskarbitrationd consults /etc/fstab to determine if the discovered filesystem should be mounted other than at the default location(/Volumes/) or with special options (or not mounted at all.)

Reasons for diskarbitrationd not mounting a filesystem or "volume" on a device may include:

  • Errors (corruption) in the partition table.
  • A mismatch between the partition type and the filesystem.
  • A damaged filesystem which fsck cannot repair.
  • Hardware failure.
  • Filesystem is listed in /etc/fstab with noauto.
  • An application has used the Disk Arbitration framework to prevent auto-mounting

According to your comments, all your journaled filesystems are mounting, and the filesystem which isn't mounting doesn't have journaling turned on. Journaling was introduced in 10.2 Server and 10.3 Client and by now is considered a vital, critical feature. It should be enabled unless you really know what you're doing; hence why you must hold down the option-key in Disk Utility to disable it in modern versions of OS X. Make sure the volume has journaling enabled:

  1. Select the volume in Disk Utility
  2. Choose File->Enable journaling (if it is greyed out, journaling is enabled.
  3. Verify by choosing File->Get info; you should see "Mac OS Extended (Journaled)" as the filesystem type.

A little late, but hopefully this helps anyone else searching (since the rest of the answers here are useless!)

Quoting https://discussions.apple.com/message/29744735#29744735 -

Since at least Panther and through to El Capitan, AutomountDisksWithoutUserLogin needs to be set to true (1) in /Library/Preferences/SystemConfiguration/autodiskmount.plist, then all external storage should be mounted at boot.

Check current setting: sudo defaults read /Library/Preferences/SystemConfiguration/autodiskmount AutomountDisksWithoutUserLogin

The output will be either 0 or 1 0 = false 1 = true

Set to true: sudo defaults write /Library/Preferences/SystemConfiguration/autodiskmount AutomountDisksWithoutUserLogin -bool true

Assuming there's no dramas with the volumes themselves, you can mount additional volumes at login by adding them as Login Items for your user account in the System Preferences.

Go to System Preferences>Accounts>Login Items. Click on the plus sign and add your drive on that list. Every time you log into your account, Finder will automatically mount that drive.

In my case I had to mount an afp volume at boot, and I wanted it to be transparent. What I did was to create an script and added it to login items. That way the window is not shown.

tell application "Finder"
    mount volume "afp://ServerName._afpovertcp._tcp.local/VOLUMENAME" as user name "macUser"
end tell

you can try to do something similar with

do shell script "diskutil mount /dev/disk2s1"
Licensed under: CC-BY-SA with attribution
Not affiliated with apple.stackexchange
scroll top