Home All Groups Group Topic Archive Search About

Disable/Enable "Local Area Connection" using DEVCON

Author
23 Dec 2005 3:38 PM
Max
Hi,

I was following up on a different thread and need to disable/enable a
network connection, specifically "Local Area Connection" using a command line
utility so that I can package it in a batch file. It turns out that DEVCON
may be of help. A thread from 7/05 talks about it, but it doesn't go deep
enough to outline the way to get to the connection. The help for devcon is
not helping enough to suggest a way to isolate the connection.

Can someone with DEVCON experience suggest a way to disable the connection?
Novell has a utility called NETSHX that can do it for their networks. This
will probably be a nice tip for some people! WINDOWSITPRO seems to have an
article that covers this topic but it's for subscribers only. :-|

Thanks.

Author
23 Dec 2005 5:42 PM
aaron
Try looking into the netsh command on XP, it should do what you need it to
do.

--
aaron
A+,NET+,MCSE 2K/2K3,CNA,CCNA
Show quoteHide quote
"Max" <M**@discussions.microsoft.com> wrote in message
news:AFA795EC-45BC-406C-B4F4-259146F08B02@microsoft.com...
>
> Hi,
>
> I was following up on a different thread and need to disable/enable a
> network connection, specifically "Local Area Connection" using a command
> line
> utility so that I can package it in a batch file. It turns out that DEVCON
> may be of help. A thread from 7/05 talks about it, but it doesn't go deep
> enough to outline the way to get to the connection. The help for devcon is
> not helping enough to suggest a way to isolate the connection.
>
> Can someone with DEVCON experience suggest a way to disable the
> connection?
> Novell has a utility called NETSHX that can do it for their networks. This
> will probably be a nice tip for some people! WINDOWSITPRO seems to have an
> article that covers this topic but it's for subscribers only. :-|
>
> Thanks.
>
Author
23 Dec 2005 6:23 PM
Philip Ashley
this will find the network adaptor ids
devcon listclass net
the string you need is up to the first '&'
then for example for my wireless network card this disables it
devcon disable PCI\VEN_10EC

hth

philip ashley

Show quoteHide quote
"aaron" <aa***@fake.net> wrote in message
news:%23FSM1g%23BGHA.1288@TK2MSFTNGP09.phx.gbl...
> Try looking into the netsh command on XP, it should do what you need
> it to do.
>
> --
> aaron
> A+,NET+,MCSE 2K/2K3,CNA,CCNA
> "Max" <M**@discussions.microsoft.com> wrote in message
> news:AFA795EC-45BC-406C-B4F4-259146F08B02@microsoft.com...
>>
>> Hi,
>>
>> I was following up on a different thread and need to disable/enable a
>> network connection, specifically "Local Area Connection" using a
>> command line
>> utility so that I can package it in a batch file. It turns out that
>> DEVCON
>> may be of help. A thread from 7/05 talks about it, but it doesn't go
>> deep
>> enough to outline the way to get to the connection. The help for
>> devcon is
>> not helping enough to suggest a way to isolate the connection.
>>
>> Can someone with DEVCON experience suggest a way to disable the
>> connection?
>> Novell has a utility called NETSHX that can do it for their networks.
>> This
>> will probably be a nice tip for some people! WINDOWSITPRO seems to
>> have an
>> article that covers this topic but it's for subscribers only. :-|
>>
>> Thanks.
>>
>
>
Author
23 Dec 2005 6:49 PM
Max
Thanks Philip, your answer was right on the dot, in the context!

But ... the bad news is that it works only partially!

If you DISABLE from the GUI connection icon, and then try enabling through
devcon, it doesn't work. But, then if you ENABLE from the GUI connection
icon, and then try disabling through devcon, it will stop the traffic even
though the light on the port will stay on (indicating a live connection
between the machine and the hub). I'm using regular ethernet port, so there
is a light that I can check.

So, as the old thread from july 2k5 was suggesting, there seems to be
something else that the GUI action of DISABLE from the icon seems to be
doing, which is not completely matched by the devcon action. Devcon seems to
take care of part of it at the lower layer of data traffic, but not the part
that opens/closes the communication signals between the machine and the
router.

My objective is to basically script the action taken by the GUI part of
disabling and enabling a connection. I hope there is some solution to this.

Thanks.



Show quoteHide quote
"Philip Ashley" wrote:

> this will find the network adaptor ids
> devcon listclass net
> the string you need is up to the first '&'
> then for example for my wireless network card this disables it
> devcon disable PCI\VEN_10EC
>
> hth
>
> philip ashley
Author
23 Dec 2005 7:10 PM
Philip Ashley
try disabling the corresponding packet scheduler miniport as well

hth

philip ashley

Show quoteHide quote
"Max" <M**@discussions.microsoft.com> wrote in message
news:7658DEEB-BE54-46C1-9629-C9EFD332C3DF@microsoft.com...
>
> Thanks Philip, your answer was right on the dot, in the context!
>
> But ... the bad news is that it works only partially!
>
> If you DISABLE from the GUI connection icon, and then try enabling
> through
> devcon, it doesn't work. But, then if you ENABLE from the GUI
> connection
> icon, and then try disabling through devcon, it will stop the traffic
> even
> though the light on the port will stay on (indicating a live
> connection
> between the machine and the hub). I'm using regular ethernet port, so
> there
> is a light that I can check.
>
> So, as the old thread from july 2k5 was suggesting, there seems to be
> something else that the GUI action of DISABLE from the icon seems to
> be
> doing, which is not completely matched by the devcon action. Devcon
> seems to
> take care of part of it at the lower layer of data traffic, but not
> the part
> that opens/closes the communication signals between the machine and
> the
> router.
>
> My objective is to basically script the action taken by the GUI part
> of
> disabling and enabling a connection. I hope there is some solution to
> this.
>
> Thanks.
>
>
>
> "Philip Ashley" wrote:
>
>> this will find the network adaptor ids
>> devcon listclass net
>> the string you need is up to the first '&'
>> then for example for my wireless network card this disables it
>> devcon disable PCI\VEN_10EC
>>
>> hth
>>
>> philip ashley
>
Author
23 Dec 2005 7:07 PM
Max
!!
Warning: I can't recall the exact sequence, but I just ran into a blue
screen after tinkering with devcon combined with GUI manipulation
(disable/enable) of the connection. Watch out!
!!