Webmin wont stop DHCP

Posted on 2012-08-22
Last Modified: 2012-09-22
I have recently set up a Ubuntu 11.10 server as a DHCP server.
For ease I installed webmin to control the server.

I seem to have the webmin DHCP Server module working but cannot seem to Stop the DHCP.

When the server boots it automatically starts the DHCP

In webmin it shows a button of the screen saying Start Server (even though the server is working).

I would expect it to show STOP Server if it was running at the time.

If I click it, it doesnt make any difference.

Any someone shed some light..

Many Thanks

Question by:sjtinsley83
    LVL 2

    Expert Comment

    Hi Steve,

    By default the Ubuntu is probably set to dhcp To change the network settings, please check if that is the case:
    SUDO vim /etc/network/interfaces
    (this will probaly ask for your password)

    You Can change this to a static IP Address for example:
    (to edit press i, to finish press esc and to save type :wq)

    #Primary Network Interface
    iface eth0 inet static

    To restart your network type:
    Sudo /etc/init.d/networking restart

    Note that this should be added according to your network settings and the eth in use usually its eth0 or eth1.

    Once you have the correct config DHCP is off.

    Hope this answers your question,

    Author Comment

    The IP address of the server is already STATIC.
    Its the DHCP Server i want to be able to START and STOP via webmin.
    LVL 2

    Expert Comment


    Didint got it really. Ok. There is a command to stop DHCP Server:
     /etc/init.d/isc-dhcp-server stop

    To start again:
     /etc/init.d/isc-dhcp-server start

    Does this work?


    Author Comment

    LVL 2

    Expert Comment

    Ok. That is a good turnarround. Nevertheless I'm wondering what could be doing that.
    How was the installation performed with repository or manually?
    You could start by checking the DHCP configuration:
    In the Webmin go to unused modules, select DHCP Server. Make the following changes if you didint already:

    DHCP Server Config File = /etc/dhcp/dhcpd.conf
    DHCP Server Executable = /usr/sbin/dhcpd
    Command to start DHCP server = /etc/init.d/isc-dhcp-server start
    Command to apply configuration = /etc/init.d/isc-dhcp-server restart
    Command to stop DHCP server = /etc/init.d/isc-dhcp-server stop
    Path to DHCP server PID file = /var/run/dhcp-server/

    In the end click save.
    Reboot the system and check if button already works.

    Author Comment

    Checked that and I have that correct..

    I am beginning to wonder if webmin doesn't have a STOP button.

    - In the terminal when I STOP the DHCP server then check the DHCP server status is says stop.
    - I then go to webmin and START the DHCP server via the START BUTTON.
    - Back in the terminal i check the DHCP server status and it says RUNNING.
    - I look in webmin and the button still says START... I would expect it to say STOP when its running.

    Any thoughts?
    LVL 2

    Expert Comment


    Ok. So we have the issue with DHCP solved. Still you would like to be able to Stop/start webmin.

    The fact is webmin is the web interface, if it is stopped you wont be able to access it again via the web interface. The button that shows start (this will depend on the version, was revised and in some versions will say restart webmin). So this button is used usually for example to process an update with pearl.

    Nevertheless you may stop and start webmin the following way:

    To stop webmin manually you should use the following command:
    sudo /etc/webmin stop;
    to start:
    sudo /etc/webmin start;

    Hope this helps,

    Author Comment

    I wanted to be able to stop the DHCP server via webmin... Not Stop webmin!
    LVL 2

    Accepted Solution

    Hi Again,

    If I understand correctly you have ISC DHCP installed and running as per our previous interactions. You want to be able to administer this module via Webmin.
    Go to the following web page:


    This will allow you to manage ISC DHCP via Webmin.

    Hope this helps,

    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    How to run any project with ease

    Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
    - Combine task lists, docs, spreadsheets, and chat in one
    - View and edit from mobile/offline
    - Cut down on emails

    If you have a server on collocation with the super-fast CPU, that doesn't mean that you get it running at full power. Here is a preamble. When doing inventory of Linux servers, that I'm administering, I've found that some of them are running on l…
    Little introduction about CP: CP is a command on linux that use to copy files and folder from one location to another location. Example usage of CP as follow: cp /myfoder /pathto/destination/folder/ cp abc.tar.gz /pathto/destination/folder/ab…
    Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
    Learn how to navigate the file tree with the shell. Use pwd to print the current working directory: Use ls to list a directory's contents: Use cd to change to a new directory: Use wildcards instead of typing out long directory names: Use ../ to move…

    760 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    11 Experts available now in Live!

    Get 1:1 Help Now