Symptoms
-
Cannot update Plesk. The following error appears during the process:
Preparing to unpack .../linux-headers-4.4.0-116_4.4.0-116.140_all.deb ...
Unpacking linux-headers-4.4.0-116 (4.4.0-116.140) ...
dpkg: error processing archive /var/cache/apt/archives/linux-headers-4.4.0-116_4.4.0-116.140_all.deb (--unpack):
unable to create '/usr/src/linux-headers-4.4.0-116/drivers/net/arcnet/Makefile.dpkg-new' (while processing './usr/src/linux-headers-4.4.0-116/drivers/net/arcnet/Makefile'): No space left on device
dpkg-deb: error: subprocess paste was killed by signal (Broken pipe)
Preparing to unpack .../linux-headers-4.4.0-116-generic_4.4.0-116.140_amd64.deb ...
Unpacking linux-headers-4.4.0-116-generic (4.4.0-116.140) ...
dpkg: error processing archive /var/cache/apt/archives/linux-headers-4.4.0-116-generic_4.4.0-116.140_amd64.deb (--unpack):
unable to create '/usr/src/linux-headers-4.4.0-116-generic/include/config/ncpfs/ioctl/locking.h.dpkg-new' (while processing './usr/src/linux-headers-4.4.0-116-generic/include/config/ncpfs/ioctl/locking.h'): No space left on device
dpkg-deb: error: subprocess paste was killed by signal (Broken pipe)
Errors were encountered while processing:
/var/cache/apt/archives/linux-headers-4.4.0-116_4.4.0-116.140_all.deb
/var/cache/apt/archives/linux-headers-4.4.0-116-generic_4.4.0-116.140_amd64.deb
Cause
Inodes are used on the partition where /usr
is mounted.
Resolution
-
Connect to the server via SSH;
-
Check if all kernels are installed correctly:
# dpkg -l | tail -n +6 | grep -E ‘linux-image-[0-9]+’ | grep -Fv $(uname -r)
ii linux-image-4.4.0-92-generic
<..>
ii linux-image-4.4.0-96-generic
<..>
ii linux-image-4.4.0-108-generic
iU linux-image-4.4.0-112-generic
ii linux-image-4.4.0-114-generic
iU linux-image-4.4.0-116-generic -
If
iU
is shown more than once, it means that, for example, kernel4.4.0-112
is not installed properly. Remove it. It is safe, as the command above does not show currently used kernel:# dpkg –remove linux-headers-4.4.0-112 linux-image-4.4.0-112-generic linux-image-extra-4.4.0-112-generic
Note: Replace the version to one that is actually shown on the server
-
Move files of the oldest kernel installed on the server, for example:
# mv /usr/src/linux-headers-4.4.0-92* /root/
-
Fix the rest:
# apt-get install -f -y
-
Remove unnecessary packages, including the old kernels:
# apt autoremove -y
-
Install Plesk updates:
# plesk installer –select-release-current –reinstall-patch –upgrade-installed-components
-
Upgrade the system packages (not required but recommended):
# apt-get upgrade -y