Skip to content

Server troubleshooting ​

This page collects common problems when managing a server with FlashPanel and how to fix them. When an operation fails, always start by opening the server's Events page to read the error message.

"Can not connect to server!" error ​

FlashPanel runs every task over SSH. This error means it could not log in to the server, so the task did not run. The Solution section in the event details links to this section.

  • Only website tasks fail (deployments, Git, Commands, WordPress tools, installing source code…): these tasks log in as the website's system user. Open the server's System Users page, edit that user and turn on Can Access SSH/SFTP.
  • Every task fails: FlashPanel cannot log in as root. Follow the checks in Server disconnected.

Server disconnected ​

FlashPanel manages the server over SSH using the root account and a key unique to the server. While it cannot connect, operations on the server fail until the connection is restored. Check the following in order:

  1. Is the server running? Check your provider's control panel and start the server if it is off.
  2. Is a firewall blocking it? If you restrict SSH by IP (on the server or in the provider's firewall), allow the FlashPanel IP addresses. If you deleted the SSH firewall rule, see the section below.
  3. Is the FlashPanel key still on the server? It is stored in /root/.ssh/authorized_keys and /home/flashpanel/.ssh/authorized_keys. If it was removed or overwritten by the provider (for example after reinstalling the OS or resetting the password), use Grant Root Access to reinstall the key.
  4. Is the authorized_keys file valid? Remove any lines that are not public keys (for example a private key pasted by mistake).

If it still fails, log in through the provider's console and fix the permissions of the .ssh folders:

bash
# root user
chown root:root /root
chown -R root:root /root/.ssh
chmod 700 /root/.ssh
chmod 600 /root/.ssh/authorized_keys

# flashpanel user
chown flashpanel:flashpanel /home/flashpanel
chown -R flashpanel:flashpanel /home/flashpanel/.ssh
chmod 700 /home/flashpanel/.ssh
chmod 600 /home/flashpanel/.ssh/authorized_keys

If none of the steps above help, run the following command as root and send the output to FlashPanel support:

bash
grep 'sshd' /var/log/auth.log | tail -n 20

SSH firewall rule deleted or SSH port changed ​

If the firewall rule for the SSH port was deleted, or you changed the SSH port and the new port is blocked, FlashPanel cannot connect and therefore cannot reopen the port for you.

  1. Open the console (VNC/Web Console) in your server provider's control panel and log in as root.

  2. Reopen the SSH port (replace 22 with your current SSH port if you changed it):

    bash
    ufw allow 22
  3. If your provider has its own firewall (security group, cloud firewall), open the port there too.

See also Firewall and SSH.

Change the root or system user password ​

FlashPanel does not store the server's login passwords, so it cannot tell you the old password. You can set a new password while the server is still connected:

  1. Open the server's System Users page and click the pencil icon on the user's row (root is at the top of the list).
  2. Enter a new password or click the key icon to generate one.
  3. Click Save.

If the server is already disconnected, reset the password with your provider's tools, then see Server disconnected.

TIP

By default the server only allows SSH logins with keys, so passwords are mainly used for sudo and the provider's console. To log in over SSH, use SSH Keys.

Restart PHP-FPM ​

You can restart PHP from the server's Applications page or PHP page (the Restart button).

In a deploy script or terminal, every system user is allowed to reload PHP-FPM with sudo without a password. Replace 8.3 with the website's PHP version:

bash
sudo service php8.3-fpm reload

This is useful at the end of every deployment when OPcache is enabled, so PHP picks up the new code.

Website shows 502 Bad Gateway ​

This is usually caused by PHP-FPM being stopped, the website pointing to an uninstalled PHP version, or a Node.js app/daemon not running. See 502 Bad Gateway error for details.

Nginx fails to start after a configuration change ​

This is usually caused by a website configuration block with invalid syntax. See Nginx fails to start.

Operations stuck or "Could not get lock" error ​

When installing an application or updating the server fails with an APT lock error, see Fix APT Lock. For the dpkg was interrupted error, see this section.

"Repository changed its 'Label' value" error ​

Updating packages fails with an error like:

text
E: Repository 'http://ppa.launchpad.net/ondrej/nginx/ubuntu focal InRelease' changed its 'Label' value from 'PPA for NGINX Stable with HTTP/2' to 'PPA for NGINX Stable'

The maintainer of a package repository (PPA) renamed it. As a safety check, APT stops until you confirm the change. The Solution section in the event details links to this section.

  1. Open Terminal on the server's overview page and run:

    bash
    sudo apt update --allow-releaseinfo-change
  2. Run the task that failed again.

WARNING

Only accept the change for repositories you trust. The ppa:ondrej/* repositories (PHP, Nginx, Apache) are maintained by Ondřej Surý and are safe. For an unknown repository, check its source first.

Redis fails to start ​

  1. Open Terminal on the server's overview page and read why Redis stopped:

    bash
    sudo systemctl status redis-server
    sudo journalctl -u redis-server -n 50 --no-pager
  2. Fix it based on the message:

    • Can't open the log file: No such file or directory: the log folder is missing. Recreate it:

      bash
      sudo mkdir -p /var/log/redis
      sudo chown redis:redis /var/log/redis
      sudo chmod 755 /var/log/redis
    • Address already in use: another program is using port 6379. Find it with sudo lsof -i :6379 and stop it. If you would rather move Redis to another port, change port in the Redis configuration (Config button on the Applications page) and update every application that connects to Redis.

  3. Click Start on the Redis row of the Applications page, or run sudo systemctl restart redis-server. Redis is running again when its status shows Active.

Disk full ​

A full disk makes the database, PHP, and web server fail in unpredictable ways, often with the error No space left on device. Run the Cleanup System utility first, then follow Disk Full to find and remove what is using the space.

Cannot create a server through the provider's API ​

  • Invalid API key or missing permissions: create a new API key following Connect a server provider.
  • Account resource limit reached (for example DigitalOcean's droplet limit): contact the provider to raise the limit, then create the server again.