Skip to main content
Question

Set Jamf Pro computer name to name of computer

  • June 13, 2019
  • 3 replies
  • 35 views

Forum|alt.badge.img+2

Hi all, the company I work for has a naming convention for all systems. Laptops are the serial number with a -L
Desktops are the serial number with a -D

I have written a script that handles this. The problem is the name does not update in the jamf pro admin console. Is there a way to make jamf pro pull the name from the computer?

3 replies

Forum|alt.badge.img+21
  • Valued Contributor
  • June 13, 2019

Easiest way would probably be to use the Jamf binary to update inventory after your script has set the computer name. Add this line below where your script sets the name:

/usr/local/bin/jamf recon

Forum|alt.badge.img+2
  • Author
  • New Contributor
  • June 13, 2019

Thanks, I tried it and it worked. Will add it to the end of my script.


Forum|alt.badge.img+3
  • New Contributor
  • September 30, 2019

Are you able to post your script? I have a big deployment coming up and would like to see if I can get this working in my environment too. Thanks.