This post mainly introduces the ipconfig command. Learn how to use various ipconfig commands, e.g. ipconfig, ipconfig /all, ipconfig /release, ipconfig /renew, ipconfig /flushdns, ipconfig /displaydns, etc. to find your IP address, release or renew IP address, flush DNS, etc. on your Windows 10/11 computer.
On This Page :
The ipconfig (short for IP Configuration) is a basic, yet popular, Windows network command-line utility used to display the TCP/IP network configuration of a computer. If you are familiar with Linux, this tool is similiar to ifconfig. This tool is often used for troubleshooting network connectivity issues. With ipconfig, you can identify the types of network adapaters on your computer, the computer’s IP address, the IP addresses of the DNS (Domain Name System) servers being used, and much more.
These commands shown here are tested on a comptuer with Windows 10 but most will work in other versions of Windows as well.
Overview
ipconfig — утилита командной строки для управления сетевыми интерфейсами.
В операционных системах Microsoft Windows ipconfig — это утилита командной строки для вывода деталей текущего соединения и управления клиентскими сервисами DHCP и DNS. Также есть подобные графические утилиты с названиями winipcfg и wntipcfg (последняя предшествовала ipconfig). Утилита ipconfig позволяет определять, какие значения конфигурации были получены с помощью DHCP, APIPA или другой службы IP-конфигурирования либо заданы администратором вручную.
Часто в операционных системах Linux и UNIX детали соединения отслеживаются несколькими утилитами, главной среди них является ifconfig. Тем не менее, ipconfig наряду с ifconfig присутствует в Mac OS X, там ipconfig команда сервиса как оболочка к агенту IPConfiguration и может использоваться для контроля BootP и DHCP клиента из CLI.
The ipconfig command is used to display information about your network configuration and refresh DHCP and DNS Settings. By default, the ipconfig command displays your IP Address, Subnet Mask, and default gateway. But with correct parameters, you can get a lot more information out of it.
In this article, I will explain the ipconfig command and the different options that you can use.
So let’s first start with something simple, how to use the ipconfig command.
- Press Windows key + X or Right Click on the start menuTo use the IP config command we will need to open Command Prompt or PowerShell
- Select Windows PowerShell or Command Prompt
- Type ipconfig and press enterThis will show you the basic network information from your network adapters
As you can see in the screenshot above, the command will return information about each network adapter on your computer. In this case, we have an ethernet adapter (for our wired network connection) and a wireless network adapter.
If you are using a VPN client, then this will also be listed as a network adapter.
Ipconfig /all command
Without the use of any parameter, the command shows only the basic network information. But information about the DNS and DHCP servers isn’t displayed by default. To show all the information about your network adapter, you will need to use the /all parameter.
The ipconfig /all command is often used to troubleshoot network connection problems. But which information is important and do you need to look at?
If we take a closer look at the results of ipconfig /all then we can indicate 4 items that are important to look at:
- IPv4 Address – This is your IP Address
- Default Gateway – The router or modem to which you network package are sent
- DNS servers – Used to translate domain names to IP Addresses
- DHCP Enabled – Needs to be Yes in most cases. No means that you have manually enter an IP Address
Параметры утилиты IPCONFIG
- Чтобы вывести основную конфигурацию TCP/IP для всех адаптеров, введите: ipconfig
- Чтобы вывести полную конфигурацию TCP/IP для всех адаптеров, введите: ipconfig /all
- Чтобы сбросить кэш сопоставления имен DNS при наличии неполадок в сопоставлении имен, введите: ipconfig /flushdns
- Чтобы вывести код класса DHCP для всех адаптеров с именами, начинающимися со слова “Подключение”, введите: ipconfig /showclassid “Подключение”
- Чтобы задать код класса DHCP TEST для адаптера Подключение по локальной сети, введите: ipconfig /setclassid “Подключение по локальной сети” TEST
Видео – Работа с утилитой IPCONFIG
- Если имя адаптер содержит пробелы, его следует заключать в кавычки (т. е. “имя_адаптера“).
- В именах адаптеров, задаваемых для команды ipconfig, поддерживается использование подстановочного знака звездочки (*) для задания имен, начинающихся с указанной строки или содержащих указанную строку. Например, имя Подкл* будет включать все адаптеры, начинающиеся со строки «Подкл», а имя *сет* все адаптера, содержащие строку «сет».
- Эта команда доступна, только если в свойствах сетевого адаптера в объекте Сетевые подключения в качестве компонента установлен протокол Интернета (TCP/IP).
ipconfig поддерживает несколько параметров командной строки, как описано ниже. Команда «ipconfig /?» отображает набор доступных опций.
Освобождение адресов для всех подключений с соответствующим именем, например «Проводное подключение Ethernet 1» или «Проводное подключение Ethernet 2».
- ipconfig /release «Local Area Connection 1»
- ipconfig /release *Local*
Ipconfig /renew — Обновление адресов всех адаптеров
Этот параметр повторно устанавливает соединения TCP / IP во всех сетевых адаптерах. Как и в случае с опцией release, ipconfig /renew принимает необязательный спецификатор имени соединения.
ipconfig /renew EL* — Обновление адресов для всех подключений, имя которых начинается с «EL»
Параметры Both /renew и /release работают только на клиентах, настроенных для динамической (DHCP) адресации.
Примечание. Остальные параметры ниже доступны только в Windows 2000 и более поздних версиях Windows.
Ipconfig / showclassid, ipconfig / setclassid
Эти параметры управляют идентификаторами класса DHCP. Классы DHCP могут быть определены администраторами на DHCP-сервере для применения различных сетевых настроек для разных типов клиентов. Это расширенная функция DHCP, обычно используемая в бизнес-сетях, а не в домашних сетях.
Ipconfig /displaydns, ipconfig /flushdns
Эти параметры обеспечивают доступ к локальному кэшу DNS, который поддерживает Windows. Параметр / displaydns печатает содержимое кеша, а параметр / flushdns стирает содержимое.
В домашних сетях эти параметры DNS иногда полезны для расширенного поиска и устранения неполадок. Если информация в вашем кеше DNS становится поврежденной или устаревшей, вы можете столкнуться с трудностями при доступе к определенным сайтам в Интернете. Рассмотрим эти два сценария:
- IP — адрес в веб — сайт, сервер электронной почты или других изменений сервера (редкое явление). Имя и адрес этого сайта обычно остаются в вашем кеше в течение 24 часов после вашего последнего посещения. Возможно, вам понадобится очистить кеш, чтобы получить доступ к серверу раньше.
- Веб-сайт или другой сервер был отключен, когда вы последний раз его посещали (надеюсь, это редкое событие), но с тех пор он вернулся в Интернет. Кэш обычно будет хранить запись о том, что сервер отключен в течение 5 минут после вашего последнего посещения. Возможно, вам понадобится очистить кеш, чтобы получить доступ к серверу раньше.
Подобно приведенным выше параметрам, этот параметр обновляет параметры DNS на компьютере под управлением Windows. Однако вместо простого доступа к локальному кешу DNS этот параметр инициирует обмен данными с DNS-сервером (и сервером DHCP) для повторной регистрации с ними.
Эта опция полезна при устранении неполадок , связанных с соединение с провайдером Интернет — услуг, таких как неспособность получить динамический IP — адрес или невозможность подключения к ISP сервера DNS
Подобно параметрам / release и / renew, / registerdns необязательно обновляет имена определенных адаптеров. Если параметр имени не указан, / registerdns обновляет все адаптеры.
Ipconfig против winipcfg
Как упоминалось выше, для ввода команды ipconfig all необходима такая утилита, как командная строка на Windows. На других операционных системах, таких как UNIX-подобные, эта команда также присутствует, но об этом позже.
Для того чтобы открыть командную строку, можно воспользоваться разными способами. Перечислены будут абсолютно все, чтобы каждый нашел себе по вкусу.
- Самый обыденный для заядлого пользователя Windows алгоритм действий по открыванию командной строки будет через меню «Пуск». Для этого войдите в данное меню и проследуйте в раздел «Все программы». Там, крутя колесико мыши вниз, отыщите папку под названием «Стандартные» и уже в ней найдите ту самую утилиту «Командная строка».
- Второй способ намного быстрее первого, но, возможно, далекие от компьютера люди его не поймут. Но все же откройте меню «Пуск» и на боковой панели найдите строку «Выполнить». После нажатия появится окошко в левом нижнем углу рабочего стола. В поле для ввода напишите «cmd.exe» и нажмите «ОК».
- Если по каким-то причинам вы не нашли «Выполнить», то третий способ специально для вас. Вместо безуспешных поисков просто нажмите сочетание горячих клавиш Win + R и заветное окошко появится. Ну, а дальше вы знаете, что делать, ввести в строку «cmd.exe» и нажать «ОК».
Командная строка открыта, а это значит, что можно приступать к рассматриванию команд ipconfig all, ping и tracert.
Table of Content
The ipconfig /renew will cause your computer to reach out to your DHCP server for an IPv4 address if it doesn’t already have one or renews an existing one for all network adapters. Depending on how your DHCP server is configured or the pool of available addresses, the IP address you will receive can be one you had previously or it can be a new IP address. Once you execute this command, it will typically take just seconds for a DHCP to assign your computer with an IP address. In the illustration below, the IP address assigned to this computer is 192.168.226.132.
See example for ipconfig /release for related information.
Первой на очереди и по важности будет команда ipconfig. Если вы часто сталкиваетесь с проблемами с сетью, то данную команду вы должны знать от А до Я, так как именно она вам поможет найти причины неполадок, проанализировать их и предотвратить.
Например, если на экране показывает, что шлюз у вас 0.0.0.0, то знайте, что проблема с маршрутизатором.
Example Usage
There are a variety of switches (sub commands) available with the ipconfig utility that will either display certain information or perform certain network functions. At the most basic, the ipconfig displays a computer’s IP address, subnet mask and the default gateway (which is typically the IP address of your router or network firewall).
ОграниченияПравить
ipconfig о если в свойствах сетевого адаптера установлен протокол TCP/IP.
Ipconfig /displaydns – View DNS Cache
When you visit a website using it’s domain name (e.g., www.meridianoutpost.com), your computer will need to know the IP address for that website in order for it to find it the server hosting it on the Internet. The process of identifying the IP address is called DNS lookup (analogous to looking up a number in a phone book). Once your computer learns the associated IP address for the website you want to visit, it will cache it (store it) on your computer. The purpose of caching it is to improve performance by not having your computer perform a DNS lookup each time you access a web page on the website.
This command will list all the currently cached IP addresses on your computer (also referred to as the DNS resolver cache). If you’ve accessed a lot of websites since turning on your computer, this list can be very lengthy. The illustration below shows just a few entries out of many for a particular computer. If you just turned on our computer and have not access websites or servers on the network on the Internet, then you list will only show a “localhost” setting in your local hosts file.
This command is typically used to troubleshoot specific DNS lookup issues. See example for ipconfig /flushdns for related information.
The information displayed on the list include:
- Record Name: the name of the website or server that a DNS lookup was performed on
- Record Type:
1 = A 2 = NS (indicates the entry is a name server)5 = CNAME (stands for canonical name and is a type of record that maps an alias name to a true domain name)15 = MX (indicates the entry is an email server) - 1 = A
- 2 = NS (indicates the entry is a name server)
- 5 = CNAME (stands for canonical name and is a type of record that maps an alias name to a true domain name)
- 15 = MX (indicates the entry is an email server)
- Time to Live: the time (in seconds) before this cache entry expires (can be as short as a few minutes to a few days)
- Data Length: the length (in bytes)
8 Bytes = IPv4 address16 Bytes = IPv6 address - 8 Bytes = IPv4 address
- 16 Bytes = IPv6 address
Ipconfig Parameters
The command is similar to ipconfig /release except it renews the IPv6 address on the adapters.
Tips
After you have released the IP Address you will need to request a new one from the DHCP Server. We can do this with the Ipconfig /renew command:
When the renew was successful you will see the same output as the ipconfig command, an overview of your new IP Address, subnet mask, and gateway.
Again, we can specify a single network adapter by specifying the name of the adapter.
ipconfig /renew Wireless*
Ipconfig Syntax
The command is similar to ipconfig /renew except it renews the IPv6 address on the adapters.
Wrapping Up
The ipconfig command is the most used command on Windows to troubleshoot network issues. It gives you information about your current network configuration and it has the ability to renew your Ip addresses and DNS cache.
If you have any questions, just drop a comment below.
Чтобы вывести основную конфигурацию TCP/IP для всех адаптеров, введите:
Чтобы вывести полную конфигурацию TCP/IP для всех адаптеров, введите:
ipconfig /renew “Подключение по локальной сети”
Чтобы сбросить кэш сопоставления имен DNS при наличии неполадок в сопоставлении имен, введите:
Чтобы вывести код класса DHCP для всех адаптеров с именами, начинающимися со слова Подключение, введите:
ipconfig /showclassid Подключение*
Чтобы задать код класса DHCP TEST для адаптера Подключение по локальной сети, введите:
ipconfig /setclassid “Подключение по локальной сети” TEST
Для вопросов, обсуждений, замечаний, предложений и т. п. можете использовать раздел форума этого сайта (требуется регистрация).
- https://celitel.info/klad/nhelp/helpbat.php?dcmd=ipconfig
- https://comhub.ru/ipconfig/
- https://FB.ru/article/276862/komanda-ipconfig-all-i-drugie-esli-voznikli-problemyi-s-setyu
- https://ab57.ru/cmdlist/ipconfig.html
- https://qna.habr.com/q/615380
Ipconfig /release Command
The ipconfig command doesn’t only show your information about your network settings, but it can also be used to reset or refresh your network settings. When you have DHCP enabled on your network card, you can request a new IP Address from the DHCP server.
If you want to know more about how DHCP works, then make sure you read this article.
The first step to do this is to release the current IP Address. This means that we will inform the DHCP server that we don’t want to use the assigned IP Address any longer.
By default, the command will release the IP Addresses for all network adapters. You can also specify a single network adapter. To do this you will need to enter the name of the adapter that you find here in the results of ipconfig:
For example, if you only want to release the IP Address of your wireless network adapter, you can type:
ipconfig /release Wireless*
This will release the IP Address of all adapters where the name starts with “Wireless”.
Доступные ключи командной строки в WindowsПравить
To use this utility, you will need to launch the Command Prompt window. The three common ways to launch the Command Prompt window are:
- Search for cmd using the built-in Windows search tool.
- Right-click on the Start icon and select Command Prompt.
- Press the keyboard combination WinKey + R, then type cmd at the Run window that appears.
Ipconfig – Retrieve Basic TCP/IP Network Information
- IPv4 address: 192.168.0.98
- Network subnet mask: 255.255.255.0
- Default Gateway: 192.168.0.1
Please note that unless your computer is connected directly to the Internet (this is rare), the IP address reported by ipconfig will be your local network IP, not your public external IP address.
While other network details can be retrieved by the ipconfig utility, for most network troubleshooting, this is what is typically needed.
Ipconfig /flushdns – Purge DNS Cache
This command will purge the cached DNS entries on your computer. You would typically do this to troubleshoot DNS related problems. An example of this is when you try to access a website but you encounter an error message stating the website is not found. For most people, executing this command does not have adverse effect on your computer. See example for ipconfig /displaydns for related information.
СсылкиПравить
In this post, you’ve learned the various ipconfig commands. Now you can use the ipconfig command to check your IP address, use the ipconfig /release and ipconfig /renew commands to release and renew your IP address, use ipconfig /displaydns and ipconfig /flushdns commands to display or reset/flush DNS, etc.
If you have other computer problems, please visit MiniTool Software official website.
Flush DNS Command
Sometimes your DNS Cache contains outdated records, which can result in DNS-related errors (unable to reach websites for example). You can solve this often by using the flush dns command:
# Flush DNS Command
ipconfig /flushdns
The command ipconfig /flushdns clears out your DNS Cache. You can do this without any risk, your computer will simply request new, and up-to-date DNS records from the DNS servers.
Утилита командной строки Windows — ipconfig
Примеры использования ipconfig. exe
https://youtube.com/watch?v=gtRBYQyYG6U%3Flist%3DPLRJ7CY1vZEI3j9YPCs46jFIOhnfZUN5_e
Summary
The ipconfig utility, with the /all switch, is often used to find the MAC address (the 6-byte ‘burned-in’ physical/hardware address) of network adapters. While this does the job, the output shows a plethora of information as mentioned above. If you have multiple adapters, the output can be lengthy making it cumbersome to find what you are looking for.
This command is actually a series of three commands, namely:
- ipconfig /all
- findstr /v 00-00-00
- findstr Physical
As the above command shows, the output of ipconfig /all is funneled into the command findstr /v 00-00-00 as its input. The findstr with the /v switch will look for lines of text in the output of ipconfig /all that does not contain 00-00-00. What this does is exclude any network adapters that are disabled or not connected. These network adapters will have MAC address that starts with 00-00-00.
The result from the first findstr will still contain a lot of information that we can further filter out, such as DHCP lease information. To further reduce clutter to ultimately end up with an output that lists only MAC address of physical adapters, we will need to funneled the output of the first findstr into a second findstr command. This second findster will filter out every line of text except those that has the word Physical.
This series of commands produce an output that is concise to show only the MAC address of connected network adapters. As the illustration below shows, this is a much more easier report to read as oppose to using just using ipconfig /all.
Ipconfig on Linux
The equivalent for ipconfig on Linux is the ifconfig command. Ifconfig will show you the basic network information of your adapters in Linux.
View DNS servers on Linux
The ifconfig command doesn’t show the DNS servers that are used. To view the DNS servers on Linux we need to open a configuration file.
cat /etc/resolv.conf
# Result:
# Generated by resolvconf
nameserver 192.168.1.1
nameserver 1.1.1.1
nameserver fd51:42f8:caae:d92e::1
This will give you an idea of which DNS servers are used on your Linux machine.
Renew IP Address on Linux
# Renew IP Address on Linux
dhclient eth0
Your computer keeps a local cache of all DNS records that it’s has visited. This cache is used to quickly translate the domain names to the correct IP Address. This way your computer doesn’t have to contact the DNS server every time when you visit Google.com for example.
To view the content of the DNS cache you can use the command ipconfig /displaydns.
This will show every DNS record in your DNS cache:
You often don’t need to go through the records, but let me explain a little bit about what we are seeing here:
Ipconfig /DisplayDNS explained
Команда IPCONFIG – отображение параметров TCP/IP
ipconfig is short for internet protocol configuration. It is a console application in Windows OS that can display all your current TCP/IP network configuration values like your IP address. It can also flush your DNS (Domain Name System) settings, refresh DHCP (Dynamic Host Configuration Protocol) settings, etc. The ipconfig command is also available in macOS and ReactOS.
Ipconfig /renew – Get a New IPv4 Address For a Specific Network Adapter
Ipconfig /all – Retrieve All TCP/IP Network Information
This will show a detailed report of various network details for the computer. Again, your report will differ depending on your network setup and the network adapters installed on your computer. This report includes information such as:
- Make and model of your network adapter(s)
- Physical address (also known as the MAC address or hardware address) of your adapter(s)
- Whether your IP address is leased (i.e., DHCP issued or statically assigned)
- If IP address is leased, what the lease expiration and the DHCP that leased it
- DNS servers
As you can see, ipconfig /all provides you with a plethora of details about your computer network setup.
Ipconfig /release – Releases the IPv4 Address for a Specific Network Adapters
Note, if you have a statically assigned (manually assigned) IP address, this command will not release it. See example for ipconfig /renew for related information.
Ipconfig /release – Releases the IPv4 Address of All Network Adapters
Note, if you have a statically assigned (manually assigned) IP address, this command will not release it. See example ipconfig /renew for related information.
- ifconfig — утилита UNIX и Unix-like операционных систем, эквивалентом которой и является ipconfig
- netsh
- Сетевой адаптер
- DHCP
- DNS
Примеры вывода для WindowsПравить
Печать статуса соединения:
Перерезервирование и обновление DHCP:
Сбрасывание кэша DNS:
Регистрация записей ресурса DNS
Recommended Reading
Improve confidence and job performance
Improve productivity and efficiency