Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

hostname / NETBIOS name

Status
Not open for further replies.

thepl4yer

Technical User
Jan 28, 2005
27
GB
I've just come across a PC that has a different NETBIOS name to the hostname. I'm wondering what implications this may have it the machine was placed in an AD environment and secondly how such a situation could arise ?(I realise they are different properties of a machine, but in an MS environment, they have always in my experience been identical)


Thanks
 
thepl4yer,

If I am reading your post correctly??

Hostname usually refers to some location outside of the client PC while NetBIOS name refers to the clients NetBIOS name.

In my experience these are always different on a client station.

Secondly, these should get reset when you perform a "join to domain" routine on this client and the reset values will align with the account that will have to be setup on the server & AD before you do the join. This depends on if you are aplying your CAL's as per seat or per device.

These links might assist you:

Join a domain

How to change a computer name or join a domain in Windows XP

Hope this helps

rvnguy
"I know everything..I just can't remember it all
 
I would have thought that the name displayed in System Properties/ Computer Name is the only one that "identifies your full computer name on the network".

Type "Hostname" at a command prompt and it should be, normally, the same as the first paragraph's "Computer Name".

"Hostname and Computername are related but are not the same. Hostname is used mostly for winsock programs. Computername is used for NetBIOS programs."

The GetHostName function retrieves your previous computer name in Windows XP

Computer description appears before the computer name in the My Network Places Browse list
 
I'll try and explain a little more clearly...

If I go into System Properties/Machine Name I get for example "Machine1" (or with regard to the Full computer name - Machine1.ad.local.co.uk if it was to join AD).

If however I type hostname I will get "Machine2". I am wondering why the hostname value is different, how this can be set and what implications it would have. I realise that the machine name (or NETBIOS name) is what AD/MS is concerned with, but I have always found the hostname to match....



Thanks

 
thepl4yer,
how this can be set
You can set it to be the same, the implications are nil as long as it is unique within the domain. see the links for information. Second link is to setname but is part of a complete document on names.

How to change a computer name or join a domain in Windows XP

Setname fumction

rvnguy
"I know everything..I just can't remember it all
 
I understand that the NETBIOS name can be changed by changing the computer - I am just trying to ascertain why the "hostname" would be different and how that is set ?
 
thepl4yer,

As you came across this machine it is very difficult to answer how this happened.

I can tell you that it is possible to set different names but doing this breaks the convention of interdependent NetBIOS and DNS names. Applications that use the DnsHostnameToComputerName function to derive the NetBIOS name from the first label of the DNS name will fail if this convention is broken.

I can't determine why this was done to this machine.

If you looked at the "Set Name" Link and the several function calls with descriptions, you should be able to re-set one or both of these names. If you are really good you can just change them in the registry, which is what the function calls do.

This is what the convention should be:

The fully qualified DNS name is a combination of the DNS host name and the DNS domain name, using the form HostName.DomainName.

"SetComputerName" and "SetComputerNameEx" with correct parameters will answer "how that is set"

rvnguy
"I know everything..I just can't remember it all
 
Well basically this machine is one of a number that is experiencing this issue. They are currently residing in an Novell environment and are due to be migrated to an AD environment... Whilst it isn't a problem at the moment, I think it may cause issues when they are migrated.

I think you hit the nail on the head when you mention the fact that applications may use the DNS hostname to derive the NETBIOS name. I think some sort of script is obviously in order to bring them back into sync.
 
thepl4yer,

Well I think that you just might have answered your own question as to how this might have happened.

We have been talking about the MS AD in the server environment. As these were/are on Novell you might look to this documentation as to the conventions used there.

I have not had exposure to Novell for well over 15 years and cannot comment on what might be the naming structure there.

Yes, if there many machines to adjust and there is some sort of structure to the current naming scheme, you could invest time in a batch script using the "getcomputername", "setcomputername" and "setcomputernameex" functions.

rvnguy
"I know everything..I just can't remember it all
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top