Operating System Ubuntu

How to Install Ajenti 2 on Ubuntu 26.04 or 24.04 (and What Replaced Ajenti V)

Install Ajenti 2 on Ubuntu 26.04 or 24.04 with the official virtual environment installer, secure it, add plugins, and see why Ajenti V is no longer an option.

Ajenti is a lightweight, open source web panel for administering a single Linux server: a dashboard, file manager, web terminal, service control, package management and a text editor in the browser. This guide installs the current Ajenti 2 release on Ubuntu 26.04 LTS (the steps are the same on Ubuntu 24.04 LTS), secures the login, and explains what happened to the Ajenti V hosting add-on. Ubuntu 14.04 and 16.04 are long past standard support and the original Ajenti 1.x packages for them should not be used on a new server.

Ajenti 2 and the status of Ajenti V

The Ajenti project is maintained on GitHub and publishes Ajenti 2 as Python packages on PyPI (the 2.2 series at the time of writing). Older tutorials add an APT repository at repo.ajenti.org and install an ajenti package; that was Ajenti 1.x, which ran on Python 2. Ajenti 2 is installed with the project's install script or with pip, not from an APT repository.

Ajenti V, the add-on that created Nginx, PHP-FPM, MySQL and mail virtual hosts, was written for Ajenti 1.x. It is not part of Ajenti 2 and is not in the Ajenti 2 plugin list, so there is no supported way to install it on a current Ubuntu release. Ajenti 2 is a server administration panel, not a web hosting panel: you configure Nginx, PHP and databases yourself and use Ajenti for the file manager, terminal and service control. If you need per-site hosting management with mail and databases, choose a dedicated hosting panel instead.

Requirements

  • A server running Ubuntu 26.04 LTS or 24.04 LTS. The Ajenti documentation lists Ubuntu 18.04 "Bionic" or later, Debian 9 or later and RHEL 8 or later as supported.
  • A user with sudo rights (the examples use deploy).
  • TCP port 8000 reachable from your own IP address.

Step 1: Install Ajenti in a virtual environment

Ubuntu 24.04 and later mark the system Python as "externally managed", so pip refuses to install packages system-wide. The Ajenti documentation therefore recommends the virtual environment installer, which puts everything under /opt/ajenti. Update the system and make sure curl is present:

sudo apt update
sudo apt -y upgrade
sudo apt -y install curl

Download the installer, read it, then run it as root:

curl -fsSL https://raw.githubusercontent.com/ajenti/ajenti/master/scripts/install-venv.sh -o install-venv.sh
less install-venv.sh
sudo bash install-venv.sh

The script enables the universe repository, installs build tools and Python headers, creates the virtual environment in /opt/ajenti, installs ajenti-panel with the core, dashboard, settings, plugins, notepad, terminal, file manager, packages and services plugins, writes /etc/ajenti/config.yml, generates a self-signed certificate in /etc/ajenti/ajenti.pem, and creates and starts a systemd unit named ajenti.

Step 2: Check the service and open the firewall

sudo systemctl status ajenti
sudo ss -tlnp | grep 8000

If you use UFW, allow the panel port only from the address you administer the server from:

sudo ufw allow from 203.0.113.10 to any port 8000 proto tcp

Step 3: Log in

Open https://203.0.113.20:8000 (your server's address) in a browser. The certificate is self-signed, so the browser shows a warning the first time.

Ajenti 2 authenticates against operating system accounts by default (provider: os in the configuration). There is no root / admin default password as in Ajenti 1.x. On Ubuntu the root account normally has no password, so log in with your own sudo user. Because allow_sudo: true is set, members of the sudo group can elevate to root inside the panel with their own password.

Step 4: Adjust the configuration

All settings are in /etc/ajenti/config.yml. The parts you are most likely to change:

bind:
  host: 0.0.0.0
  mode: tcp
  port: 8000
max_sessions: 9
session_max_time: 3600
ssl:
  enable: true
  certificate: /etc/ajenti/ajenti.pem
  fqdn_certificate:
  force: false
  • bind.host and bind.port set the listening address and port. Set the host to 127.0.0.1 if you put a reverse proxy in front of the panel or reach it through an SSH tunnel.
  • ssl.fqdn_certificate takes the path of a PEM file for your host name, for example one issued by Let's Encrypt, containing the certificate and private key.
  • session_max_time is the idle time in seconds before automatic logout.
  • trusted_domains and trusted_proxies are needed when the panel is published through a reverse proxy; entries in trusted_domains include protocol and port, such as https://panel.example.com:8000.

Restart the panel after editing the file:

sudo systemctl restart ajenti

Step 5: Add plugins

Extra plugins are ordinary Python packages named ajenti.plugin.*. Install them into the same virtual environment, either from the Plugins page in the panel or from the shell:

sudo /opt/ajenti/bin/python3 -m pip install ajenti.plugin.network ajenti.plugin.datetime ajenti.plugin.power
sudo systemctl restart ajenti

Updating and troubleshooting

Update the panel and its plugins with pip inside the virtual environment, then restart:

sudo /opt/ajenti/bin/python3 -m pip install -U ajenti-panel ajenti.plugin.core ajenti.plugin.dashboard ajenti.plugin.settings ajenti.plugin.plugins
sudo systemctl restart ajenti

Logs are written to /var/log/ajenti/ajenti.log, with crash reports next to it. To see start-up errors directly, stop the service and run the panel in the foreground:

sudo systemctl stop ajenti
sudo /opt/ajenti/bin/python3 /opt/ajenti/bin/ajenti-panel -v

Press Ctrl+C and start the service again when you are done. Two fixes from the official installation page: if the page stays empty after login, run sudo /opt/ajenti/bin/python3 -m pip install gipc gevent -U; if the certificate was not generated, run sudo /opt/ajenti/bin/python3 /opt/ajenti/bin/ajenti-ssl-gen $(hostname). See the Ajenti installation documentation for the manual method and removal steps.

Frequently asked questions

Can I still install Ajenti V for website hosting?

Not on a supported system. Ajenti V depends on Ajenti 1.x and Python 2, neither of which is available on Ubuntu 24.04 or 26.04. Manage Nginx and PHP-FPM by hand and use Ajenti 2 for files and services, or use a hosting-oriented control panel.

Is it safe to expose port 8000 to the internet?

The panel gives root-level access, so treat it like SSH. Restrict the port to known addresses in the firewall, or bind Ajenti to 127.0.0.1 and reach it with ssh -L 8000:127.0.0.1:8000 deploy@203.0.113.20.

Can I create panel users that are not system accounts?

Yes. Set auth.provider to users and install the ajenti.plugin.auth-users plugin; accounts are then stored in /etc/ajenti/users.yml with their own permissions and are managed from the panel.

How do I remove Ajenti?

Stop and disable the ajenti service, delete /lib/systemd/system/ajenti.service, run sudo systemctl daemon-reload, and remove /opt/ajenti and /etc/ajenti.

Share story:

Continue reading other guides on How VPS.