- Разрешение конфликтов IP-адресов на Mac
- Release & Renew DHCP from the Command Line with ipconfig on Mac
- How to Renew DHCP Lease from Command Line of Mac
- Использование DHCP или ввод IP-адреса вручную на Mac
- How to Renew a DHCP Lease in Mac OS X
- Renew DHCP Lease from OS X System Preferences
- Renewing a DHCP Lease from the Command Line
- How do I renew an IP address for my computer (MAC OS)
Разрешение конфликтов IP-адресов на Mac
Если при использовании протокола TCP/IP Вам не удается подключить Mac к другим компьютерам или службам, причиной может быть конфликт IP-адреса Вашего компьютера и IP-адреса другого устройства в сети.
Есть несколько способов устранения таких конфликтов. Выбор решения зависит от способа предоставления IP-адресов.
Если IP-адреса предоставляются автоматически с применением DHCP, то можно предположить, что выделенный Вашему компьютеру адрес уже используется каким-то устройством в сети. Чаще всего в таком случае сервер DHCP в течение нескольких минут предоставляет Вашему компьютеру Mac новый IP-адрес. Попробуйте подключиться к сети еще раз.
Закройте приложение, использующее подключение (например, Safari или Сообщения), затем откройте его снова.
Переведите компьютер в режим сна. Через несколько минут верните его в рабочий режим. Попробуйте подключиться к сети еще раз.
Закройте все открытые приложения и перезагрузите компьютер.
Если Вы вводили IP-адрес вручную, убедитесь, что он указан правильно. Если сетью управляет администратор, посоветуйтесь с ним. См. раздел Ввод дополнительных параметров TCP/IP.
Если описанная проблема возникла в Вашей домашней сети и ни одно предложенное решение не помогает, попробуйте отключить от сети и выключить все устройства (в том числе маршрутизатор и модем). Подождите несколько минут, затем снова включите устройства. См. раздел Перезагрузка внешнего устройства.
Источник
Release & Renew DHCP from the Command Line with ipconfig on Mac
If you need to release and renew DHCP from the command line on a Mac, the helpful ipconfig utility is able to do so quickly. Do keep in mind that for most Mac OS X users, renewing a DHCP lease from the Mac System Preferences is the best approach because it’s user friendly and just as effective, but the Terminal approach has benefits to advanced users and is able to be run through ssh and single user mode, making this a worthwhile bit of knowledge to share.
How to Renew DHCP Lease from Command Line of Mac
The basic syntax to renew DHCP lease from the command line with ipconfig is as follows:
sudo ipconfig set (DEVICEINTERFACE) DHCP
If you know the device interface (en0, en1, en2, etc), just run that command to release and then renew DHCP for the determined device. Let’s say it’s en0, standard for modern Macs with wi-fi only.
sudo ipconfig set en0 DHCP
Once the command is run you can check if DHCP has set properly by determining DHCP info with the same ipconfig command with ‘getpacket’ like so:
ipconfig getpacket en0
Assuming the prior ‘set’ command was successful, getpacket will return the DHCP assigned IP, DNS server, subnet mask, router / gateway, and the lease time. If the DHCP info returns blank, then either the interface queried was wrong, or the DHCP lease did not renew or distribute properly.
Another crude option would be to run ipconfig for all available device interfaces on the Mac by stringing the syntax together like so:
sudo ipconfig set en0 DHCP && sudo ipconfig set en1 DHCP
It’s best to set DHCP for the specific interface, however.
If you don’t know the interface, then the first step is to determine the computers hardware device interface used for the particular networking port you’re using. For most modern Macs, we’re looking for wi-fi which is typically on en0, but many Mac users use ethernet, an iPhone personal hotspot, a tethered Android phone, or an external NIC card as well, each of which may have a different device interface depending on the hardware. You can easily determine what the device interface is by running networksetup -listallhardwareports like so:
Scroll through the output to find the interface you want to set and renew DHCP for, let’s assume you’re looking for “Wi-Fi” which may look like this:
Hardware Port: Wi-Fi
Device: en0
Ethernet Address: b1:3f:22:dd:ab:19
Alongside ‘Device’ you’ll find the interface, in this case it’s “en0”, which is what gets plugged into the aforementioned ipconfig command.
Источник
Использование DHCP или ввод IP-адреса вручную на Mac
IP-адрес — это номер, идентифицирующий каждый компьютер в Интернете или сети. Когда Вы подключаетесь к Интернету или IP-сети, компьютеру требуется IP-адрес.
Есть два основных способа, с помощью которых можно задать IP-адрес.
Автоматически: Вашему компьютеру назначается адрес с помощью протокола DHCP.
Вручную. Ваш интернет-провайдер или сетевой администратор предоставляет IP-адрес, который необходимо ввести на панели «Сеть» в Системных настройках.
Выполните описанные ниже действия, чтобы ввести свой IP-адрес или назначить его автоматически.
На Mac выберите меню Apple
> «Системные настройки», затем нажмите «Сеть».
Выберите сетевое подключение, которое хотите использовать, в списке (например, Ethernet).
Нажмите всплывающее меню «Конфигурация iPv4» и выберите нужный вариант:
Если Ваш адрес назначается автоматически, выберите «Использовать DHCP».
Если интернет-провайдер или администратор предоставил Вам IP-адрес, выберите «Вручную» и введите адрес в поле «IP-адрес». Поставщик услуг сети Интернет предоставляет DHCP-адрес вместе с прочей информацией, например маской подсети, маршрутизатора и сервера DNS (служба доменных имен). Укажите маску подсети и маршрутизатор в соответствующих полях. Чтобы ввести адрес DNS-сервера, нажмите «Дополнительно», откройте вкладку «DNS», затем нажмите кнопку и введите адрес.
Примечание. Большинство IP-адресов — это адреса IPv4, которые выглядят как серия чисел, разделенных тремя точками, например: 123.45.67.89. Если Вы получили IP-адрес с более длинной последовательностью чисел и букв, разделенных семью точками (например, fa80:0000:0000:0123:0203:93ee:ef5b:44a0), то это другой тип IP-адреса, который называется IPv6. Чтобы ввести адрес IPv6, в разделе настроек «Сеть» нажмите «Дополнительно». В TCP во всплывающем меню «Конфигурация IPv6» выберите «Вручную» и введите адрес IPv6.
Источник
How to Renew a DHCP Lease in Mac OS X
DHCP stands for Dynamic Host Configuration Protocol, and is commonly used to configure network devices so they can communicate with one another. Typically you’ll have a DHCP server (like a wireless router), and client machines on the local network (like a Mac, iPhone, PC, etc) that pull a dynamically assigned local IP address from that server.
This is all well and good and usually functions just fine, but sometimes you need to renew a DHCP lease, which basically means you’ll be retrieving a new IP address and routing data from the DHCP server. This is a common trick for troubleshooting network issues, and can be helpful when resolving problems with internet connectivity when a wi-fi connection has been determined to be stable, or when a machine on the network can’t access the outside world after power-cycling a broadband modem or router.
Renew DHCP Lease from OS X System Preferences
This is the easiest way to renew a DHCP lease from Mac OS X:
- Pull down the Apple menu and choose “System Preferences”
Often renewing a DHCP lease means the Mac will end up with a different local IP address than it had before, though sometimes you will end up with the same one. If the reason you are renewing DHCP is to try and get a new IP address but the router continues to stubbornly assign the same LAN IP over and over again, consider setting a static IP instead by configuring DHCP with manual addresses.
Another approach, though more advanced, is to renew DHCP by way of the command line. This is typically best used by advanced users, but it can also be helpful for remote troubleshooting if you can only SSH into a remote Mac and something like Screen Sharing is not available to you. The other obvious advantage with a command line approach is possibility of using the lease renewal in a script or as part of an automated task within cron.
Renewing a DHCP Lease from the Command Line
There are two different ways to renew the DHCP lease from the OS X command line. The first approach uses the ever useful ipconfig tool:
sudo ipconfig set en0 DHCP
When using ipconfig, be sure to use the proper interface address otherwise you may run into other problems, or find nothing changes at all. You can retrieve interface data by using ipconfig to pull current DHCP information like so:
ipconfig getpacket en1
Ran successfully, you will find DHCP server information, client IP, lease time, the subnet mask, router IP, and DNS servers, the tail of the command should look something like this:
If running that command returns nothing, then you are looking at the wrong interface. Typically en0 is the default wi-fi interface on MacBook Air and newer MacBook Pro models, but it is often en1 on Macs with physical ethernet ports.
The ipconfig method will interrupt the current network connection, whereas resetting through Network Preferences does not. You can refresh DHCP without interruption from the command line by using the following scutil command provided by a MacWorld user:
echo «add State:/Network/Interface/en0/RefreshConfiguration temporary» | sudo scutil
You can verify the changes took place by using the aforementioned ipconfig command again:
ipconfig getpacket en0
Again, be sure to use the appropriate network interface for your hardware: en1 or en0.
Each method outlined here will work in virtually every version of Mac OS X, from the old versions to the new.
Finally, if you’re troubleshooting network wide issues on all devices on a LAN, you can also renew a DHCP lease from iOS and get new local IP addresses on iPhones, iPods, and iPads.
Источник
How do I renew an IP address for my computer (MAC OS)
If you had configure your computer as Obtain an IP address automatically, sometimes such as after you change the IP address of your router, then you need renew the IP address of your computer to access the network/router.
In the top options, select TCP/IP. If you get IP by Using DHCP, you can see Renew DHCP Lease button. Click it to renew the IP address.
Subscribe TP-Link takes your privacy seriously. For further details on TP-Link’s privacy practices, see TP-Link’s Privacy Policy.
Be The First To Get Exclusive Deals & News
Get products, events and services for your region.
To provide a better experience, we use cookies and similar tracking technologies to analyze traffic, personalize content and ads. By continuing to browse this website, you agree to our use of cookies and such technologies. Learn more Don’t show again
To provide a better experience, we use cookies and similar tracking technologies to analyze traffic, personalize content and ads. By continuing to browse this website, you agree to our use of cookies and such technologies. Learn more Don’t show again
These cookies are necessary for the website to function and cannot be deactivated in your systems.
Site Selection Popup
SMB Product Selection System
tp_smb-select-product_scence, tp_smb-select-product_scenceSimple, tp_smb-select-product_userChoice, tp_smb-select-product_userChoiceSimple, tp_smb-select-product_userInfo, tp_smb-select-product_userInfoSimple
__livechat, __lc2_cid, __lc2_cst, __lc_cid, __lc_cst, CASID
VISITOR_INFO1_LIVE, YSC, LOGIN_INFO, PREF, CONSENT, __Secure-3PSID, __Secure-3PAPISID, __Secure-3PSIDCC
Analysis and Marketing Cookies
Analysis cookies enable us to analyze your activities on our website in order to improve and adapt the functionality of our website.
The marketing cookies can be set through our website by our advertising partners in order to create a profile of your interests and to show you relevant advertisements on other websites.
Google Analytics & Google Tag Manager & Google Optimize
_gid, _gat, _gat_global, _ga, _gaexp
Google Ads & DoubleClick
NID, IDE, test_cookie, id, 1P_JAR
fr, spin, xs, datr, c_user, sb, _fbp
_ce.s, _CEFT, _gid, cean, _fbp, ceac, _drip_client_9574608, cean_asoc
_hjKB, _fbp, ajs_user_id, _BEAMER_LAST_UPDATE_zeKLgqli17986, _hjid, _gcl_au, _ga, ajs_anonymous_id, _BEAMER_USER_ID_zeKLgqli17986, _hjAbsoluteSessionInProgress, _hjFirstSeen, _hjIncludedInPageviewSample, _hjTLDTest
Hm_lpvt_33178d1a3aad1dcf1c9b345501daa675, Hm_lvt_33178d1a3aad1dcf1c9b345501daa675, HMACCOUNT_BFESS
lms_analytics, AnalyticsSyncHistory, _gcl_au, liap
Источник