What DirectAdmin needs before the first command
DirectAdmin is a commercial hosting control panel sold by licence and installed on a server you own. The installer builds Apache, PHP, MySQL, mail and DNS around the panel, so it expects a clean machine with a hostname and a licence already in hand.
- OS: AlmaLinux 8 or 9, Rocky Linux 8 or 9, CloudLinux 8 or 9, Debian 11 or 12, Ubuntu 22.04 or 24.04. Minimal install, no panel on it.
- Specs: 2 GB RAM minimum, 4 GB comfortable, 2 vCPU and 20 GB disk for a small reseller box.
- A licence key tied to the server IP, bought from DirectAdmin or a reseller.
- A fully qualified hostname such as server.example.com, with an A record pointing at the server.
DirectAdmin 1.71x is the current line. The install script pulls the latest build for your OS, so the panel version is decided by the script rather than by you.
Set the hostname and run the installer
Three commands plus one long command run as root. The hostname must be a real FQDN with a dot in it, or setup aborts at the first check.
- SSH in as root:
ssh root@SERVER-IP. - Set the hostname:
hostnamectl set-hostname server.example.com, then confirm withhostname -f. - Update the OS:
apt update && apt -y upgradeon Ubuntu or Debian,dnf -y updateon AlmaLinux and Rocky. - Download the installer:
wget -O setup.sh https://download.directadmin.com/setup.shandchmod 755 setup.sh. - Run it with four arguments:
./setup.sh LICENSE_KEY server.example.com eth0 SERVER-IP. Replace eth0 with the interface fromip -o link show. - Wait 15 to 40 minutes. The script compiles services and installs the panel; do not close the SSH session.
Use tmux or screen before starting. A dropped SSH connection mid-compile leaves a half-built stack that is faster to rebuild than to repair.
Log in and finish the post-install steps
The installer prints a URL and a one-time login link at the end. Open it within the window it allows, or go straight to port 2222.
- Browse to
https://SERVER-IP:2222and accept the self-signed certificate warning. - Log in as
adminwith the password the installer generated, then change it immediately. - Set the main domain for the server and the admin email address in the panel.
- Create the nameservers if this box will answer DNS, and add glue records at the registrar.
- Set the panel to issue certificates for its own hostname, so the 2222 warning disappears.
Open the ports DirectAdmin and mail need
A panel that will not load at 2222, or mail that will not connect, is usually a closed port. Open these in the provider firewall and in the OS firewall.
| Port | Service | Notes |
|---|---|---|
| 2222 | DirectAdmin panel | HTTPS. Restrict to your own addresses if you can. |
| 80 and 443 | Websites | Needed for ACME certificate checks as well. |
| 22 | SSH | Key login, no password auth. |
| 25, 587, 465 | Mail submission and transfer | Most providers block 25 until you ask them to unblock it. |
| 53 | DNS | Only if this server runs its own nameservers. |
| 110, 143, 993, 995 | Mail retrieval | IMAP and POP over TLS. |
Confirm the install worked
Check the service before you check the browser. A running service with a login page is a finished install.
- Run
systemctl status directadmin. It should be active and enabled. - Print the build:
/usr/local/directadmin/directadmin vshows the version and compile options. - Log in at 2222 and create a test user with a domain you control.
- Load the domain in a browser. You know it worked when the default page appears over HTTP, and then over HTTPS after you issue a certificate.
Install WordPress and SSL on DirectAdmin
WordPress is a one-click install when Softaculous or Installatron is on the licence. From the user level, open Softaculous, choose WordPress, fill the domain, directory, database and admin email, and install. Without Softaculous, upload WordPress to public_html, create a database and user in MySQL Management, and run the installer.
For SSL, open the domain's SSL Certificates page, choose Free and automatic (Let's Encrypt), tick the domain and www, and save. The panel requests the certificate and installs it. You know it worked when https loads without a warning and the padlock shows the domain name. A failed issuance is almost always a DNS record that does not yet point at this server.
Common DirectAdmin install failures and fixes
These five account for most installs that stop at the first screen.
| Symptom | Cause | Fix |
|---|---|---|
| Licence is invalid for this IP | The licence is bound to the old server address | Update the IP on the licence in the DirectAdmin client area, then rerun getLicense.sh |
| Setup exits on the hostname check | Hostname has no dot, or does not resolve | Set a real FQDN with hostnamectl and add its A record before rerunning |
| Websites return 503 after install | Apache cannot bind port 80 because another server holds it | Rebuild from a clean OS image, or stop and remove the old web server |
| 2222 does not answer | Provider firewall or ufw blocks the panel port | Allow 2222 in both firewalls, then reload them |
| Domains resolve nowhere | No A record, or missing nameserver glue at the registrar | Create A records for the domain and glue for ns1 and ns2 |
The getLicense.sh step is: cd /usr/local/directadmin/scripts && ./getLicense.sh. Run it after any IP change, then systemctl restart directadmin.
DirectAdmin or cPanel for a new server
DirectAdmin is cheaper per licence and lighter on RAM, which is why it suits resellers on a 2 GB VPS. cPanel has the larger third-party plugin market and more staff who already know it. The features overlap for websites, mail and DNS; the difference is licence cost, memory and familiarity.
Run it on a WebJi VPS with a clean supported image, and read the WordPress on DirectAdmin walkthrough once the panel is up. If you would rather not manage a licence and a panel at all, cPanel hosting covers the same job with support included.
Frequently Asked Questions
What are the minimum requirements for DirectAdmin?
2 GB RAM, 2 vCPU, 20 GB disk and a clean 64-bit OS from the supported list: AlmaLinux 8 or 9, Rocky 8 or 9, CloudLinux 8 or 9, Debian 11 or 12, Ubuntu 22.04 or 24.04.
Which port does DirectAdmin use?
2222 over HTTPS for the panel. Websites use 80 and 443, and mail needs 25, 587 and 465 plus the IMAP and POP ports. Open them in the provider firewall as well as the OS firewall.
Can I install DirectAdmin without a licence?
No. The installer takes a licence key as its first argument, and the licence is bound to the server IP. A trial or paid key is issued from the DirectAdmin client area before you run setup.sh.
How do I install WordPress on DirectAdmin?
Use Softaculous if the licence includes it: choose WordPress, set the domain, directory and database, and install. Otherwise upload the files to public_html, create a database in MySQL Management, and run the browser installer.
How do I install an SSL certificate on DirectAdmin?
Open the domain's SSL Certificates page, choose the free automatic Let's Encrypt option, tick the domain and www, and save. Issuance fails when DNS does not point at the server yet, so check the A record first.
What if the licence says it is invalid for this IP?
The licence is tied to the old address. Update the IP on the licence in the DirectAdmin client area, run getLicense.sh from /usr/local/directadmin/scripts, then restart the directadmin service.

