Skip to content

TheOneOh1/AutoDHCP

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 

Repository files navigation

AutoDHCP

  • Automating DHCP Server configuration with Bash
  • Client Configuration is not mentioned here as it has to be done manually
  • As of now you have to manually install the DHCP package with
    sudo apt install isc-dhcp-server

How to use?

  • You can directly use the code or clone the repo

    bash AutoDHCPilot.sh

  • It will ask for details to that to be filled out by user and configuration will be automated

    • Provide Domain Name
    • Provide Subnet (eg. 192.168.80.0)
    • Provide Option Routers (eg. 192.168.80.1)
    • Provide IP Pool with Starting and Ending IP address
  • At the end it will show which IP has been assigned yet.

Output

Client Side

  • First check the network interface of client machine (eg. ens33, eth0)
  • Open the Interfaces file
    sudo nano /etc/network/interfaces
    And enter the following details
    auto <interface-name>
    iface <interface-name>inet dhcp
    
  • Once done restart the network or reboot the system
    systemctl restart networking
    dhclient -4

Releases

No releases published

Packages

No packages published

Languages