DirectAdmin tracks every IP address on the server and who may use it. New IPs from your provider must be added in IP Management before resellers and users can use them – for example a dedicated IP for a customer's website or private nameservers for a reseller.
Before you start
- Admin-level access.
- The new IPs routed to your server by the provider, with the correct netmask. On a VPS, see VPS IP addresses.
Add an IP address
- At Admin Level, go to Server Manager → IP Management.
- Click Add IP.
- Enter the IP and Netmask (for example
255.255.255.0, or a prefix such as/64for IPv6). - Choose the network device if asked (usually detected automatically).
- Click Add. DirectAdmin brings the IP up on the interface and records it.
You can add a range by entering the first IP and the number of addresses, where the option is offered.
IP statuses
| Status | Meaning |
|---|---|
| server | The server's main IP |
| free | Available to assign to a reseller or user |
| shared | Shared by several accounts (typical for websites) |
| owned | Assigned to one reseller or user |
Assign an IP to a reseller
- In IP Management, tick a free IP.
- Choose Assign To and select the reseller.
- Confirm. The reseller can now share it among their users, use it for their nameservers, or give it as a dedicated IP.
Use Share to make an IP available as a shared IP to everyone.
Change a user's IP
- Go to Account Manager → List Users (as admin or the owning reseller) and click the user.
- Choose Modify User (or Change IP).
- Select the new IP and save. DirectAdmin updates the web server configuration and, if it hosts DNS, the zone files.
If DNS is external, update the domain's A records there at the same time.
IPv6
Add the IPv6 address in IP Management, then link it to an IPv4 address with Link IP. Linked IPv6 addresses are added automatically to the web server and DNS records (AAAA) of domains on that IPv4. Make sure outgoing mail on IPv6 has a matching reverse DNS, or keep mail on IPv4.
Change the server's main IP
When moving a server or replacing its primary IP, add the new IP first, then run DirectAdmin's IP swap script as root:
/usr/local/directadmin/scripts/ipswap.sh OLD-IP NEW-IPThen update the licence IP with DirectAdmin and rewrite configs with CustomBuild (./build rewrite_confs).
Troubleshooting
- IP added but unreachable: wrong netmask or the provider has not routed it yet.
- Cannot delete an IP: it is still owned or used by accounts; move them first.
- Sites on a new IP show the default page: rewrite configs and restart the web server.
