Изменить IP на основе точки доступа

671
dunpealslyr

Я подключаюсь к 8 различным точкам доступа, каждая из которых имеет отдельную подсеть и в каждом местоположении не разрешен DHCP.

Я хочу, чтобы мой компьютер изменил свой IP-адрес на назначенный IP-адрес для каждого местоположения в зависимости от того, к какой точке доступа я подключен, без необходимости каждый раз запускать скрипт netsh.

Где настройки windows для такой функциональности? Если нет встроенной функциональности Windows, существует ли стандартный метод или служба, которую люди обычно используют для этой желаемой функциональности?

2
Беспроводные сети не работают DHCP? Теперь это странно. Iszi 12 лет назад 0
Для этого я думаю, что DHCP * - это «стандартный метод или служба, которую обычно используют люди». :-( RedGrittyBrick 12 лет назад 2
Если это только один SSID и несколько местоположений, то единственным решением, которое я вижу, является сценарий пакетного файла / powershell, который проверяет BSSID и устанавливает IP-адрес вручную. И да, DHCP - способ получить эту функциональность. RobotHumans 12 лет назад 0
Вы смотрели на этот пост? http://superuser.com/questions/77132/static-ip-addr-for-just-a-particular-access-point-in-vista CharlieRB 12 лет назад 0

1 ответ на вопрос

0
Paul Sweatte

Windows allows you to fallback to an alternative Static IP, which is covered in this related question:

If you configure each AP to use Automatic Private IP Addressing, then multiple access points can be configured to automatically assign IP addresses without DHCP:

The Internet Assigned Numbers Authority (IANA) has reserved 169.254.0.0-169.254.255.255 for Automatic Private IP Addressing. As a result, APIPA provides an address that is guaranteed not to conflict with routable addresses. After the network adapter has been assigned an IP address, the computer can use TCP/IP to communicate with any other computer that is connected to the same LAN and that is also configured for APIPA or has the IP address manually set to the 169.254.x.y (where x.y is the client’s unique identifier) address range with a subnet mask of 255.255.0.0. Note that the computer cannot communicate with computers on other subnets, or with computers that do not use automatic private IP addressing. Automatic private IP addressing is enabled by default. You may want to disable it in any of the following cases: - Your network uses routers. - Your network is connected to the Internet without a NAT or proxy server. Unless you have disabled DHCP-related messages, DHCP messages provide you with notification when you change between DHCP addressing and automatic private IP addressing. If DHCP messaging is accidentally disabled, you can turn the DHCP messages back on by changing the value of the PopupFlag value in the following registry key from 00 to 01: HKEY_LOCAL_MACHINE\System\CurrentControlSet\Services\VxD\DHCP 

OSX allows mixing local and remote access points as well via link-local addressing.

References

Dynamic Configuration of IPv4 Link-Local Addresses

IPv6 Address Types

Mixing link-local IP addresses and routable IP addresses

Zero Configuration Networking

Airport: About Using Link-Local Addressing

Service Publication: An Example

Похожие вопросы