This is the mail archive of the
cygwin
mailing list for the Cygwin project.
RE: Anyone Done This ???
- From: "Dave Korn" <dk at artimi dot com>
- To: <cygwin at cygwin dot com>
- Date: Thu, 12 Aug 2004 12:31:39 +0100
- Subject: RE: Anyone Done This ???
> -----Original Message-----
> From: cygwin-owner On Behalf Of Reini Urban
> Sent: 11 August 2004 22:29
> Tennis Smith (tennis) schrieb:
> Has anyone written a utility/script that can change the
> name of the PC? I
> > have several _dozen_ PCs that need to be converted to a new naming
> > convention.
>
> isn't it just a registry entry?
>
It may be stored in a registry entry, but changing it probably involves more
than just altering the registry, particularly if the computer is joined to a
domain.
The proper way to rename a domain machine (local or remote) programmatically
is with the NetRenameMachineInDomain function from the windoze netapi32
library.
If it's not in a domain, you should be able to use the NetServerSetInfo
function to much the same end.
cheers,
DaveK
--
Can't think of a witty .sigline today....
--
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Problem reports: http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ: http://cygwin.com/faq/