Jump to content

Welcome to Geeks to Go - Register now for FREE

Need help with your computer or device? Want to learn new tech skills? You're in the right place!
Geeks to Go is a friendly community of tech experts who can solve any problem you have. Just create a free account and post your question. Our volunteers will reply quickly and guide you through the steps. Don't let tech troubles stop you. Join Geeks to Go now and get the support you need!

How it Works Create Account
Photo

Command line to DISABLE Network adapter


  • Please log in to reply

#1
G_Redray

G_Redray

    New Member

  • Member
  • Pip
  • 4 posts
Hello,

I am trying to find a way I can disable the network adapter from the command line.

Any suggestions,
  • 0

Advertisements


#2
dsenette

dsenette

    Je suis Napoléon!

  • Community Leader
  • 26,047 posts
  • MVP
open a command prompt and type netsh press enter
then type interface
then do set interface /? that will display the bellow

netsh interface>set interface /?

Usage set interface [name = ] IfName
			[ [admin = ] ENABLED|DISABLED
			  [connect = ] CONNECTED|DISCONNECTED
			  [newname = ] NewName ]

	  Sets interface parameters.

	  IfName  - the name of the interface
	  admin   - whether the interface should be enabled (non-LAN only).
	  connect - whether to connect the interface (non-LAN only).
	  newname - new name for the interface (LAN only).

	  Notes:
	  - At least one option other than the name must be specified.
	  - If connect = CONNECTED is specified, then the interface
		is automatically enabled even if the admin = DISABLED
		option is specified.


netsh interface>

now...what you can actually do with that...i'm not sure...never needed to disable an interface from a command line....why do you need to do such a thing?
  • 0

#3
G_Redray

G_Redray

    New Member

  • Topic Starter
  • Member
  • Pip
  • 4 posts
I have a college instructor that as posed this question! It would also be useful because when we set up new users we sometimes need to disable the network adapter. We are ususally setting up new computers from the command line, be nice to know!

Thanks



netsh interface>set interface /?

Usage set interface [name = ] IfName
			[ [admin = ] ENABLED|DISABLED
			  [connect = ] CONNECTED|DISCONNECTED
			  [newname = ] NewName ]

	  Sets interface parameters.

	  IfName  - the name of the interface
	  admin   - whether the interface should be enabled (non-LAN only).
	  connect - whether to connect the interface (non-LAN only).
	  newname - new name for the interface (LAN only).

	  Notes:
	  - At least one option other than the name must be specified.
	  - If connect = CONNECTED is specified, then the interface
		is automatically enabled even if the admin = DISABLED
		option is specified.
netsh interface>

now...what you can actually do with that...i'm not sure...never needed to disable an interface from a command line....why do you need to do such a thing?
[/quote]
  • 0

#4
gerryf

gerryf

    Retired Staff

  • Retired Staff
  • 11,365 posts
Had a service once that loaded at startup that accessed the network and would crash the computer..disabling the NIC allowed the PC to start to repair the issue.

Course, unplugging the card did the same thing :whistling:
  • 0

#5
dsenette

dsenette

    Je suis Napoléon!

  • Community Leader
  • 26,047 posts
  • MVP
http://www.microsoft...e.mspx?mfr=true here's a reference on disabeling a driver or service from RC
  • 0

#6
G_Redray

G_Redray

    New Member

  • Topic Starter
  • Member
  • Pip
  • 4 posts
Thanks,
  • 0






Similar Topics

0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users

As Featured On:

Microsoft Yahoo BBC MSN PC Magazine Washington Post HP