Skip to main content
Question

Computer Renaming to Default


Forum|alt.badge.img+5

We rename our machines at enrollment based off of a user choice in DEPNotify to see if it is a shared, primary, or test machine, SerialNumber-(S/P/T). This choice is used to easily identify a machine based on usage, as well as smart group/policy scoping.

We name machines with the following script:

#!/bin/sh
      scutil --set HostName "$SerialNumber"
      scutil --set LocalHostName "$SerialNumber"
      scutil --set ComputerName "$SerialNumber"
      defaults write /Library/Preferences/SystemConfiguration/com.apple.smb.server NetBIOSName "$SerialNumber"
"$JAMF_BINARY" setComputerName -name "$SerialNumber"

      echo "Machine name set to $SerialNumber"

Even with this machines are still renaming to default macOS names with "MacBook Pro", "Mac Pro", "'usernames' MacBook Pro".

I had read the article from https://mrmacintosh.com/10-15-4-supplemental-update-resets-computername-hostname-to-default/
and this does not seem to be the issue as this is happening to fully up to date 10.15.7 machines on a recurring basis.

Has anyone else seen this issue within Catalina, as well as Mojave on a few instances? We are now running a script at recurring check-in to see if the machine name contains the serial number, and if not, updates it again as it has been occurring so often and causes certificate issues.

Thanks

0 replies

Be the first to reply!

Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings