The startup sound doesn't play if the audio output was muted at shutdown.
-
Copy
login.sh
andlogout.sh
to/Library/Scripts
. Make sure they're executable and owned by root. -
Check if there are any existing login/logout hooks (they will be overwritten):
sudo defaults read com.apple.loginwindow LoginHook sudo defaults read com.apple.loginwindow LogoutHook
-
Add the hooks:
sudo defaults write com.apple.loginwindow LoginHook /Library/Scripts/login.sh sudo defaults write com.apple.loginwindow LogoutHook /Library/Scripts/logout.sh