🌐 ATRC DHCP Server Manager

Zero-downtime, web-based management for ISC DHCP Server — built in Rust.

v0.1.0 Static Binary IPv4-Ready Linux

🌟 Core Features

đŸ“Ļ Zero-Dependency Deployment

Compiles to a single static x86_64-unknown-linux-musl binary. No runtime dependencies required.

🤖 Auto-Provisioning

Detects your Linux distribution and installs the ISC DHCP server automatically if missing.

đŸ›Ąī¸ Smart IPv4/IPv6 Handling

Auto-patches Debian/Ubuntu systems to run IPv4-only, preventing common IPv6 daemon crashes.

đŸ–Ĩī¸ Web-Based UI

Modern, responsive interface for managing subnets, fixed leases, and app settings.

🔍 Live Diagnostics

Displays systemctl status and journalctl logs directly in the browser after restart.

🔒 Secure by Default

Config files are generated with strict 0600 (root-only) permissions.

🚀 Installation & Quick Start

Option 1: Run Pre-compiled Binary

chmod +x atrc_dhcp_server_manager_x86_64_linux
sudo ./atrc_dhcp_server_manager_x86_64_linux

Option 2: Build from Source

# Install build dependencies (Debian/Ubuntu)
sudo apt update
sudo apt install build-essential musl-tools

# Build for x86_64 and i686 musl targets
time nice ./compile_atrc_dhcp_server_manager.sh

Binaries will be located in:

â„šī¸ Supported Distributions Debian, Ubuntu, RHEL, Fedora, CentOS, AlmaLinux, Rocky Linux, and Kali Linux.

đŸŽ¯ First Run & Default Credentials

On first execution, the application will:

  1. Verify root privileges.
  2. Install the DHCP server if missing (via apt or dnf).
  3. Generate /etc/atrc_dhcp_manager/dhcp_server.conf with defaults.
  4. Patch /etc/default/isc-dhcp-server to serve IPv4 only.
  5. Start the web server on 0.0.0.0:8080.
âš ī¸ Default Credentials Username: admin
Password: admin

Change the password immediately via the Application Config page after first login.

đŸ–ąī¸ How to Use the Web UI

Open your browser and navigate to:

http://<your-server-ip>:8080

Scenario A: Adding a New Network Subnet

1

Open the Subnets Page

Click Manage Subnets in the dashboard.

2

Fill in the Subnet Details

FieldExample
Network192.168.10.0
Netmask255.255.255.0
Range Start192.168.10.50
Range End192.168.10.200
Router192.168.10.1
Broadcast192.168.10.255
3

Save & Restart

Click Add Subnet & Apply, then go to the Dashboard and click Restart DHCP Service.

Scenario B: Reserving an IP (Fixed Lease)

1

Open Fixed Leases Page

Click Manage Fixed Leases in the dashboard.

2

Enter Device Information

FieldExample
Hostnamehr-printer-01
MAC Address00:1A:2B:3C:4D:5E (use colons)
IP Address192.168.10.201 (outside dynamic range)
Device TypePrinter
3

Save & Restart

Click Add Lease & Apply, then restart the DHCP service from the dashboard.

Scenario C: Changing App Settings

Click Application Config to modify:

â„šī¸ Note Changes to Bind Address or Port require restarting the Manager application itself (not just the DHCP service).

Scenario D: Restarting the DHCP Service

After any configuration change, click Restart DHCP Service on the dashboard. The page will display:

📂 Configuration Files Reference

File Path Description Permissions
/etc/atrc_dhcp_manager/dhcp_server.conf ATRC Manager's internal state (TOML format). Stores app settings, subnets, and leases. 0600 (Root only)
/etc/dhcp/dhcpd.conf The active ISC DHCP Server configuration file, generated dynamically by the Manager. 0644
/etc/default/isc-dhcp-server Debian/Ubuntu init defaults. Modified by the Manager to enforce IPv4-only mode. 0644

🔧 Troubleshooting

Symptom Likely Cause Solution
"Unit not found" on restart DHCP server isn't installed Run sudo apt install isc-dhcp-server manually.
"Configuration file errors" Typo in Subnet or MAC address Check the journalctl output in the Web UI. It points to the exact line. Correct it and restart.
"Lease declared twice" Overlapping subnet ranges Ensure subnet ranges don't overlap with fixed leases or other subnets.
Cannot access Web UI Firewall blocking port 8080 Run sudo ufw allow 8080/tcp (Ubuntu) or check cloud security groups.
Forgot Admin Password Locked out of Web UI Edit /etc/atrc_dhcp_manager/dhcp_server.conf, change admin_password, save, and restart the app.
Service fails with IPv6 errors IPv6 daemon can't find subnet6 declaration The Manager auto-patches this on startup. If it persists, verify /etc/default/isc-dhcp-server has INTERFACESv6="".
💡 Pro Tip: MAC Address Format Always use colons (00:11:22:33:44:55). Hyphens (00-11-22...) will cause the DHCP server to fail on restart.

🔒 Security Best Practices

  1. Change Default Credentials: Always update the admin_password on first login.
  2. Restrict Network Access: If the manager doesn't need remote access, change bind_address to 127.0.0.1.
  3. Firewall Rules: Ensure your host firewall only allows trusted IP ranges to access port 8080.
  4. Backups: Regularly back up /etc/atrc_dhcp_manager/dhcp_server.conf and /etc/dhcp/dhcpd.conf.
  5. Run as Root Only: The application requires root to manage services — never run it as an unprivileged user.

📞 Support & Contact

Developed and maintained by ATRC (Applied Technology Research Center).

For enterprise support, custom integrations, or IT consulting: