Your server should be more than 1cpu & 2 gb ram then you should obtain a licence from directadmin. After follow these steps:
Login as root to your server, download the installation script, and run it:
bash <(curl -fsSL https://download.directadmin.com/setup.sh) 'Provided license key should go here'
Note: using sudo to run this install command with a non-root shell will not work. If you have non-root shell, please use sudo -s to get root shell before executing the install command.
Important: The hostname should not be the same as the primary domain name. For example gary.com is not a good hostname, where server.gary.com is a good one. Having the same host/main domain name will cause e-mail and FTP problems. Also, please make sure the hostname resolves once you set up DNS.
Accessing the Control Panel
DirectAdmin can be accessed at http://server.ip.address:2222. Use the Admin username/password from the output information provided by setup.sh (the same information is specified in the /usr/local/directadmin/scripts/setup.txt file).