VBS: Read Write MACtoIP Table

I know I know, I'm basically reinventing the wheel here but before anyone goes too crazy I've got a good excuse, bureaucracy...

So, where I work there is a massive network, some 500 machines with static IPs all connected to switches behind a single router. If the higher ups would clear the POs for the routers for individual labs of computers, I wouldn't have to do this but as it stands this is my current situation.

I've been asked to change machine IDs and IP addresses in a couple of different labs to match a new scheme. So far I've gotten a logon script set up to run on a special account I've set up that will prompt me to make most of the changes I need but, because of the version of Ghost I have, I'm having a problem coming up with a quick way to assign IP addresses based on computers without going crazy with a list of IP addresses, mac addresses and computer names on yellow lined paper and ink scribbles.

So basically what I want is to have a script that will write MacAddress IPAddress MachineID to a file on the server. That part is easy, what I need after that is the ability to search that file for a specific MacAddress and then pull the IPAddress value on that line so that I can change the local machine to reflect the information in the file, which I've named "poorMans.dhcp."

I feel sort of ridiculous asking this because I know it has to be simple, I just can't find any reference to accomplish this specific task, lots of partial examples of what I want to do but I can't figure out how to fit it all together.

Now this poorMans.dhcp is not going to get very big, the idea is that the data file on the server will only get as big as one lab at a time, some 30 computers. After I'm done with one lab I'm going to archive the file and then start over with a new one in the next lab.

Thanks in advance.
Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories