That is irrelevant ot Cache, you need to use OS facilities for this kind of stuff.

I used netsh scripts when I needed to switch between static IP-address in homenet, and DHCP IP-address in the office.

http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnxpesp1/html/tchWorkingWithNetshInWindowsXPEmbedded.asp
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/netshell/netshell/netshell_start_page.asp

Here is how I ran the netsh script for my home connection:

@net start remoteregistry > nul
@netsh -f c:\utils\netsh-welcon.txt

Here is the netsh-welcon.txt script:

#interface ip

# ----------------------------------
# Interface IP Configuration
# ----------------------------------
pushd interface ip

# reset all

# Interface IP Configuration for "Local Area Connection"

set address name = "Local Area Connection" source = static addr = 172.16.xx.y000 mask = 255.255.0.0
set address name = "Local Area Connection" gateway = 172.16.x.y gwmetric = 1
set dns name = "Local Area Connection" source = static addr = 172.16.x.y
add dns name = "Local Area Connection" addr = 195.34.xx.y1
set wins name = "Local Area Connection" source = static addr = 172.16.xx.y2



popd # End of interface IP configuration

I created it in this simple (semi-automatic) way.
1. Configured everything in UI properly;
2. netsh interface ip dump
3. and then patch the dump from prior step, changing GUIDs to human-readable name. Because otherwise netsh didn't like the resultant script on input.


Best Regards,
Timur Safin

On 03.06.2004 18:30, Stijn De Saeger said the following:

hi all,

another tricky little problem: I know there are several ways to interact
with the OS frow within Cache. Does anyone know a simple way to change the
server's IP address from within a COS script? (using windows 2000). That
would great if it were possible, but I don't really know where to start
looking.
Thanks in advance.
s.





Reply via email to