- Newest
- Most votes
- Most comments
Hello, Greetings of the day!! Thank you for contacting AWS.
I understand that after updating the MacOs to Sonoma 14.5, the GUI access to mac instance using VNC is not working and you seek our assistance to verify if there are any terminal commands to allow screen-sharing on Sonoma 14.5 instances.
Before moving forward with the following steps, please ensure that you have taken a backup of your data. To take backup of data, please refer the following:
Snapshot - https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebs-creating-snapshot.html#ebs-create-snapshot
In order to connect to your instance using ARD client or VNC client:
MacOS:
-
Verify that your local computer has an ARD client or a VNC client that supports ARD installed. On macOS, you can leverage the built-in Screen Sharing application.
-
From your local computer, connect to your instance using SSH.
-
Set up a password for the ec2-user account using the passwd command as follows.
sudo passwd ec2-user
- Install and start macOS Screen Sharing using the following command.
sudo launchctl enable system/com.apple.screensharing
sudo launchctl load -w /System/Library/LaunchDaemons/com.apple.screensharing.plist
4a. In case if the above command results in error "Load failed: 5: Input/output error", simply unload and reload:
sudo launchctl unload /System/Library/LaunchDaemons/com.apple.screensharing.plist
sudo launchctl load -w /System/Library/LaunchDaemons/com.apple.screensharing.plist
- Disconnect from the MacOS instance by typing exit and pressing Enter.
For more details, please refer: https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/connect-to-mac-instance.html#mac-instance-vnc
Troubleshooting GUI connectivity issues for Sonoma 14.5 instances:
- Try to restart and disable both the apple remote desktop and screen sharing services, then re-enable the screen sharing service:
- Restart and Disable the Apple Remote Desktop (ARD)
sudo /System/Library/CoreServices/RemoteManagement/ARDAgent.app/Contents/Resources/kickstart -configure -activate -access -on -privs -all -allowaccessfor -allusers -restart -agent
sudo /System/Library/CoreServices/RemoteManagement/ARDAgent.app/Contents/Resources/kickstart -deactivate -configure -access -off
- Stop and Disable the Screen Sharing services
sudo launchctl unload -w /System/Library/LaunchDaemons/com.apple.screensharing.plist
sudo launchctl disable system/com.apple.screensharing
- Enable the macOS Screen Sharing service
sudo launchctl enable system/com.apple.screensharing
sudo launchctl load -w /System/Library/LaunchDaemons/com.apple.screensharing.plist
- Check the service e.g. listening on port 5900, etc:
You should see tcp4 0 0 *.5900
sudo netstat -p tcp -van | grep LISTEN
sudo lsof -nP -iTCP:5900 -sTCP:LISTEN
In case if the issue persists, we would require details that are non-public information. Thus, I would request you to kindly open a support case with AWS using the following link - https://console.aws.amazon.com/support/home#/case/create
Thank you and have a nice day!
Relevant content
- asked 2 years ago
- AWS OFFICIALUpdated 6 months ago
- AWS OFFICIALUpdated 3 months ago
