Home Forums Software InstaDMG Computer Name

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #375855
    userosx
    Participant

    Is there a way to inject the computer name into the InstaDMG process? I have a launchd daemon that automatically renames the computer at first boot. However, I still need to populate a generic name in the image process.

    #375857
    Rusty Myers
    Participant

    I don’t know about during the build, but after the build, I set this:

    #Set hostname
    hostName=InstaDMG
    /usr/sbin/scutil –set ComputerName $hostName
    /usr/sbin/scutil –set LocalHostName $hostName

    Perhaps adding $3 somewhere will help?

    #375869
    aaronwyatt
    Participant

    Why do you need to populate a generic name in the image creation process?

    #375915
    Patrick Fergus
    Participant

    Could be that the “powers that be” at userosx’s facility don’t want nameless machines running around on the network. By default, imaging with InstaDMG for us leaves the name blank (since the Setup Assistant never runs and never has an opportunity to rename the machines). The computer then temporarily seems to name itself its IP address. Easy for me to find the right machine–the one that has an IP address for a name [i]and[/i] correctly responds to my AD creds in ARD is the right machine.

    But to point userosx in the right direction, you have two options I can see:

    – If you absolutely cannot have a machine on the network with the name that InstaDMG chooses by default, take thespider’s script (which only works on the current startup disk, btw, it doesn’t work as a CustomPKG from my experience) and mix with [url=http://www.fernlightning.com/doku.php?id=software:fseventer:start]fseventer[/url] to try to figure out what is being edited. Compare, contrast, and write a shell script to mimic what scutil is doing.

    – If you can wrangle having a nameless machine on the network for a minute or two, it would probably be easier to use thespider’s script to set the name on startup of a freshly imaged machine. You’ll need to restart after setting the name. You could even extend this to making a custom name for the machine by using a unique value (MAC address is a good choice) or by looking it up (a la set-names.sh from the now-deprecated NetRestore).

    – Patrick

Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.

Comments are closed