Question

I'm looking for a way to change the hostname and IP address of a Windows XP system that is mounted via a loop-back image on a Linux system. So basically I have access to the Windows XP system on a file level, but I cannot execute any programs on it. A way similar to editing the /etc/hostname and whatever network configuration file under Linux.

The only ways I've found so far would include running a tool after boot, e.g. MS sysprep or use a solution like Acronis Snap Deploy.

Was it helpful?

Solution

You can use chntpw tool to edit Windows registry offline. Here's an example of how to use it.

The keys you're looking for are these:

HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Control\ComputerName\ComputerName

HKEY_LOCAL_MACHINE\SYSTEM\Current Control Set\
Services\Tcpip\Parameters\Interfaces\{<Interface GUID>}

Under your interface's GUID you'll find many keys, the ones you need are:

IPAddress (REG_MULTI_SZ) = x.x.x.x

SubnetMask (REG_MULTI_SZ) = x.x.x.x

DefaultGateway (REG_MULTI_SZ) = x.x.x.x

Do take a look at the rest of they keys in there, you might find some interesting information.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top