Wednesday, July 24, 2019

Network interface Disable / Enable commands


Script to disable / enable network interface


Apart from modifying network adapter properties from the Control Panel, you can also use the Command line tool to enable disable Network Interface Card.
  1. Press Windows key + X, click Command Prompt (Admin).
     
  2. In the elevated command prompt, copy and paste the command below, and press Enter. This will show you all network adapter names on your PC. 
    netsh interface show interface
     
  3. To enable NIC type, the following command:
    netsh interface set interface "network_adapter_name" admin=enable(e.g netsh interface set interface "MyEthernet" admin=enable)
     
  4. To disable NIC type, the following command:netsh interface set interface "network_adapter_name" admin=disable(e.g netsh interface set interface "MyEthernet" admin=disable)
     
  5. Close the command prompt.



Original Link;

0 Comments:

Post a Comment

Subscribe to Post Comments [Atom]

<< Home