I regularly need to test our hardware products. Usually that consists of having ~50 devices sitting on a bench for some time from 1 day to 14 days. Often we have a wifi connection to the device, so we use this comms channel to manage testing. Each time I do this testing I have to do some kind of bringup (e.g. onboarding onto the wifi network) to be able to talk to each device and manage the testing. This can be cumbersome and time consuming.

I'd like to have a router or other piece of hardware that allows me to assign a given IP to the host at a given port. That will allow me to plug an ethernet cable in and know what IP the device is at.

Can you recommend some hardware that would solve this problem?

  • Almost any modern router, but you’ll need the hardware MAC address of the device being plugged in, do you know that?
    – Tyson
    Commented Sep 28, 2018 at 14:29
  • 1
    Some switches can include an options in DHCP (opt 82). This can be used by some DHCP servers to offer a specific IP to a host based on the specific DHCP option. serverfault.com/questions/350446/… serverfault.com/questions/336063/…
    – Zoredache
    Commented Sep 28, 2018 at 21:12
  • Unfortunately I don't know the MAC of the hardware (hardware moves around, gets replaced etc).
    – user50418
    Commented Sep 29, 2018 at 17:04
  • Do the devices support llmnr or cdp protocols for automatic device identification?
    – cybernard
    Commented Oct 2, 2018 at 1:58
  • Do the devices offer DHCP Options 43, 55, and 60 and Other Customized Options? Such that some thing like this can be used: match if substring (option vendor-class-identifier,0,36) = "Cisco Systems, Inc. IP Phone CP-9971"; You may have to use a dhcp server and wireshark to examine the packets to tell if this is a valid option. See also: ingmarverheij.com/…
    – cybernard
    Commented Oct 2, 2018 at 2:08

1 Answer 1


You can do this with a managed switch. My personal experience is only with small/medium business managed switches, but either the ProSafe M5300-28GF3: 24-port Gigabit SFP Managed L3 Switch (GSM7328FS v2) (~$1500) or the NETGEAR ProSAFE 48-Port Gigabit Managed Switch Layer 2+ With Static L3 Routing (GSM7248) (~$450) can do this.

Documentation on how to handle this from the CLI and the web UI is available on the Netgear knowledge base.

Example from the CLI

(Netgear Switch) #config
(Netgear Switch) (Config)#interface 1/0/2
(Netgear Switch) (Interface 1/0/2)#routing
(Netgear Switch) (Interface 1/0/2)#ip address
(Netgear Switch) (Interface 1/0/2)#exit
(Netgear Switch) (Config)#exit

This will set the IP address of interface 1/0/2 to be This does not require that you know the MAC address of the device ahead of time.

  • The OP wants to set the IP of the devices connecting to the port. Not the IP assigned to a given port.
    – Zoredache
    Commented Sep 28, 2018 at 21:09

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.