Jump to content

Welcome to Geeks to Go - Register now for FREE

Need help with your computer or device? Want to learn new tech skills? You're in the right place!
Geeks to Go is a friendly community of tech experts who can solve any problem you have. Just create a free account and post your question. Our volunteers will reply quickly and guide you through the steps. Don't let tech troubles stop you. Join Geeks to Go now and get the support you need!

How it Works Create Account
Photo

Auto set hostname after ghost


  • Please log in to reply

#1
keschrich

keschrich

    New Member

  • Member
  • Pip
  • 1 posts
I work at a public school with several computer labs which tend to get overloaded with junk fairly often, as such it seems I'm constantly going up to computers with my little ghost diskette which maps a network drive and reimages the computer.

I'm in the process of setting up a PXE boot image such that if needed I can PXE boot a computer and it will automatically do the reimage. Using tftp it is fairly easy to set it up so that it uses the correct image for a given lab based on the mac address of the computer.

My problem: There is a mandatory scheme to be used for computer naming, and I would like to set it up so that after ghosting a computer, the correct computer name is automatically set. This name is based on the computers inventory number, so it is not something that can be generated.

I do have a table in a MySQL server which links hardware (MAC) addresses to their proper computer names. Thus my first thought was to write a script that connects to the SQL server, and does a simple query such as "SELECT hostname FROM mac_hostname WHERE mac_address='blah';", sets the hostname using the newsid utility from sysinternals, and then modifies a flag in the registry that essentially tells the script to bypass this whole procedure on future boots.

Does anybody else do anything similar or have any other suggestions on how I might implement this functionality?
  • 0

Advertisements







Similar Topics

0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users

As Featured On:

Microsoft Yahoo BBC MSN PC Magazine Washington Post HP