How to turn off LAN with CMD command

CMD, also known as Command Prompt, an application that allows developers to run test commands or interfere with the system. In today's article, TipsMake.com shared with readers an interesting feature with Command Prompt that is how to turn on and off LAN with commands in CMD. Please read along.

How to turn off LAN with CMD command Picture 1

Because turning on and off LAN is related to system rights, you have to start CMD under Admin. Proceed as follows:

Step 1: On Windows 7 , open the Start menu (1) => search with the keyword cmd (2) => right-click cmd (3) => select Run as administrator (4) .

How to turn off LAN with CMD command Picture 2

On Windows 10 , you search on Windows (1) and search for the keyword Command Prompt (2) . Then, select Run as administration (3) .

How to turn off LAN with CMD command Picture 3

If there is a message as shown below, then select Yes .

How to turn off LAN with CMD command Picture 4

Step 2: Enter the following command and press Enter .

netsh interface show interface

How to turn off LAN with CMD command Picture 5

Then you remember the LAN name highlighted in red Interface Name section is Ethernet0 or maybe Local Area Connection .

Step 3: You continue to enter the following command and Enter.

netsh interface set interface name = "LAN name" admin = DISABLED

In which "LAN name" is the name of the network you have seen in Step 2 .

How to turn off LAN with CMD command Picture 6

If your LAN icon is disconnected as shown below is successful.

How to turn off LAN with CMD command Picture 7

Step 4: To reopen the LAN, execute the following command.

netsh interface set interface name = "LAN name" admin = ENABLE

Where "LAN name" is your network name.

How to turn off LAN with CMD command Picture 8

After executing the command on the LAN, it will open again and connect successfully.

How to turn off LAN with CMD command Picture 9

With instructions to turn off and turn on the LAN with CMD, we can quickly turn on and off the LAN with the command line CMD and not have to manipulate complicated. Good luck!

4 ★ | 1 Vote

May be interested

  • Doskey command in WindowsDoskey command in Windows
    the doskey command calls doskey.exe (which reminds of previously entered command lines), modifies the command line and creates macros.
  • 10 useful commands in Windows you should know10 useful commands in Windows you should know
    command prompt is used to execute batch files, perform tasks quickly, help you troubleshoot and solve some windows problems when the system crashes. however, not all commands in windows are useful and must be done regularly. with the 10 command lines in the following article it is very useful even if you are not an administrator.
  • How to use the which command in LinuxHow to use the which command in Linux
    the which command in linux determines the executable binary, which will execute when you issue a command to the shell. if you have different versions of the same program on your computer, you can use which to find out which shell will use.
  • The command reg add in WindowsThe command reg add in Windows
    the reg add command adds new subkeys or entries to the registry.
  • Shutdown command - Schedule the shutdown of Windows 10 with the Shutdown commandShutdown command - Schedule the shutdown of Windows 10 with the Shutdown command
    shutdown command - schedule the shutdown of windows 10 with the shutdown command. you are downloading or automatically processing something on your computer but you do not wait until it is finished to turn off the computer. so you want to find a way to shut down your computer using shutdow
  • Exit command in WindowsExit command in Windows
    the exit command exits the cmd.exe program (command interpreter) or the current batch script. to learn how to use this command, please see the example below.
  • Rem command in WindowsRem command in Windows
    the rem command helps write comments (comments) in a batch file or config.sys.
  • The dd command in Linux, How to use the dd commandThe dd command in Linux, How to use the dd command
    dd is a command line utility for unix-like and unix operating systems, with the main purpose of converting and copying files.
  • How to use Xcopy command in Command PromptHow to use Xcopy command in Command Prompt
    knowing how to use xcopy command in command prompt, you will easily use commands in cmd professionally. in particular, the xcopy command is extremely useful for those who copy and copy data on the computer.
  • 20+ essential Linux security commands20+ essential Linux security commands
    here are some of the most important security commands for everyday work on linux systems. if you're interested in security issues on your linux system, don't ignore these helpful security commands.