Netsh Errors

R

Richard

I'm trying to write a batch file that will set the static IP address on the
machine, however it keeps giving me errors when trying to set the gateway.

I have Winlogon with Custom Shell - SP1
The following has been added to the build.
Network Command Shell
IP Router Monitor Library
Net Command Shell Interface Context
Remote Access Monitor
Network Diagnostics
Home Networking Monitor Lib
TCP/IP Utilities 6


This will not work
netsh interface ip set address name="Local Area Connection" source=static
addr=192.168.1.101 mask=255.255.255.0 gateway=192.168.1.101

Error =
Syntax for this command is not valid then it shows the Help File

This will work....
netsh interface ip set address name="Local Area Connection" source=static
addr=192.168.1.101 mask=255.255.255.0

It states some commands may not be available- Class not Registered, then
states "OK" and the IP is changed.

No Matter what I do, I always get "Could not obtain Host information from
Machine [DL1000] Some Commands may not be available. Class not registered.

It may work fine the way it is, but I'm concerned. The device is a headless
device which we only access via an XP Pro Latop and Crossover Cable. It
seems to work.

Thanks in advance for any adice or help.

Richard
 
K

KM

Richard,

Did you see any errors in FBALog.txt? Especially around the protocol installations (snetcfg)?

Try also adding these components:
"IP Security Services",
"Primitive: W32topl"

Let us know if it helps.

KM
Revisit....

Any suggestions? Please?

Richard


Richard said:
I'm trying to write a batch file that will set the static IP address on the
machine, however it keeps giving me errors when trying to set the gateway.

I have Winlogon with Custom Shell - SP1
The following has been added to the build.
Network Command Shell
IP Router Monitor Library
Net Command Shell Interface Context
Remote Access Monitor
Network Diagnostics
Home Networking Monitor Lib
TCP/IP Utilities 6


This will not work
netsh interface ip set address name="Local Area Connection" source=static
addr=192.168.1.101 mask=255.255.255.0 gateway=192.168.1.101

Error =
Syntax for this command is not valid then it shows the Help File

This will work....
netsh interface ip set address name="Local Area Connection" source=static
addr=192.168.1.101 mask=255.255.255.0

It states some commands may not be available- Class not Registered, then
states "OK" and the IP is changed.

No Matter what I do, I always get "Could not obtain Host information from
Machine [DL1000] Some Commands may not be available. Class not registered.

It may work fine the way it is, but I'm concerned. The device is a headless
device which we only access via an XP Pro Latop and Crossover Cable. It
seems to work.

Thanks in advance for any adice or help.

Richard
 
S

Susanne Stoehr

Richard said:
[...]

This will not work
netsh interface ip set address name="Local Area Connection" source=static
addr=192.168.1.101 mask=255.255.255.0 gateway=192.168.1.101

Error =
Syntax for this command is not valid then it shows the Help File
[...]

I had this problem, too. If you check the syntax of the commands of
netsh, you will see that this should work:

netsh interface ip set address name="Local Area Connection"
source=static addr=192.168.1.101 mask=255.255.255.0
gateway=192.168.1.101 1

I hope, it helps
Susanne Stoehr
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top