Knowledgebase

Cannot upgrade Plesk or install a package: dpkg: error processing package linux-image-generic - error 25 : Write error : No space left on device

The error message you're seeing, "No space left on device," indicates that your server's storage is full, and it's preventing you from performing actions like upgrading Plesk or installing packages. To resolve this issue, you'll need to free up some disk space.

Here are some steps you can take to address this problem:

  1. Check Disk Usage:

    bash
    df -h

    This command will show you a summary of disk usage. Pay attention to the "Use%" column to identify which partitions are running out of space.

  2. Clean Up Unnecessary Files:

    • Remove Old Logs:
      go
      sudo find /var/log -type f -name '*.gz' -delete
    • Remove Cached Packages:
      Arduino
      sudo apt-get clean
    • Remove Old Kernels:
      SQL
      sudo apt-get autoremove --purge
    • Empty Trash (if applicable).
  3. Check Plesk Backups: If you have Plesk backups stored on your server, consider moving them to an external location or deleting old backups.

  4. Check and Clear Temporary Files:

    bash
    sudo du -h /var/tmp sudo rm -rf /var/tmp/*
  5. Check for Large Files or Directories:

    bash
    sudo du -h --max-depth=1 / | sort -hr

    This command will show you the largest directories in your system. Investigate if there are any large, unnecessary files you can remove.

  6. Resize Partitions: If you find that your root partition is running out of space, you may need to resize it. This process can be a bit complex and depends on your specific setup. It's recommended to back up your data and consult with your hosting provider or a system administrator.

  7. Consider Adding Additional Storage: If resizing isn't feasible or doesn't provide a sufficient solution, consider adding additional storage or upgrading your server's plan.

  8. Upgrade Server Plan: If you're using a cloud or VPS provider, you might consider upgrading your server to a plan with more storage.

  9. Monitor Disk Space Regularly: Set up monitoring to keep an eye on your server's disk space usage. This will help you identify and address space issues before they become critical.

After performing these steps, try upgrading Plesk or installing the package again. If you're still encountering issues, consider seeking help from your hosting provider or a system administrator, as they will have a better understanding of your specific server setup.

  • 0 Users Found This Useful
Was this answer helpful?