Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

How do I stop DHCP services on a particular ethernet port in Linux ? I was trying to take full control of an ethernet port of my computer to inject packets into the device plugged into it without being interfered by DHCP request traffic.

share|improve this question
Is your intention to disable DHCP and configure a static IP address on an eth interface? Ubuntu Network Configuration Guide – one.time Sep 6 '13 at 3:59

As far as an interface getting an IP via DHCP, that's controlled by /etc/network/interfaces - change any dhcp you find in the appropriate stanzas to static.

share|improve this answer
This is what I am trying to do. I want to setup a connection with my network device and respond to the GET request it is sending with my local webserver Perl script. I thought I should disable all system service before I can inject http traffic into the port. – Jean Sep 6 '13 at 14:50
Probably want to disable NetworkManager if it's running, service stop NetworkManager or similar. Then you may want to run lsof -i or netstat to see what else is listening, and stop programs or disable services accordingly if you want absolutely no other traffic on that interface. – LawrenceC Sep 6 '13 at 16:31

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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