-2

I have been using ubuntu for 3 months now and I have come across this problem. An error message showed up saying

packages with unmet dependencies,update

When i tried to update it says

not enough disk space in /Boot.

I looked up some other answers in this forum and ran the command lines posted there but could'nt solve my problem.

Im pasting my terminal output below.

image

Ran the apt-get -f install command and got this output.

nram772@nram772-Lenovo-Z50-70:~$ sudo apt-get install -f
[sudo] password for nram772: 
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Correcting dependencies... Done
The following packages were automatically installed and are no longer required:
  libgles1-mesa linux-headers-4.4.0-31 linux-headers-4.4.0-31-generic linux-headers-4.4.0-64 linux-headers-4.4.0-64-generic
  linux-headers-4.4.0-66 linux-headers-4.4.0-66-generic linux-headers-4.4.0-72 linux-headers-4.4.0-72-generic linux-headers-4.4.0-75
  linux-headers-4.4.0-75-generic linux-headers-4.4.0-77 linux-headers-4.4.0-77-generic linux-headers-4.4.0-78
  linux-headers-4.4.0-78-generic linux-image-4.4.0-31-generic linux-image-4.4.0-64-generic linux-image-4.4.0-66-generic
  linux-image-4.4.0-72-generic linux-image-4.4.0-75-generic linux-image-4.4.0-77-generic linux-image-4.4.0-78-generic
  linux-image-extra-4.4.0-31-generic linux-image-extra-4.4.0-64-generic linux-image-extra-4.4.0-66-generic
  linux-image-extra-4.4.0-72-generic linux-image-extra-4.4.0-75-generic linux-image-extra-4.4.0-77-generic
  linux-image-extra-4.4.0-78-generic snap-confine ubuntu-core-launcher xsane-common
Use 'sudo apt autoremove' to remove them.
The following additional packages will be installed:
  linux-image-4.4.0-83-generic
Suggested packages:
  fdutils linux-doc-4.4.0 | linux-source-4.4.0 linux-tools
The following NEW packages will be installed
  linux-image-4.4.0-83-generic
0 to upgrade, 1 to newly install, 0 to remove and 58 not to upgrade.
19 not fully installed or removed.
Need to get 21.9 MB of archives.
After this operation, 66.9 MB of additional disk space will be used.
Do you want to continue? [Y/n] y
Get:1 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 linux-image-4.4.0-83-generic amd64 4.4.0-83.106 [21.9 MB]
Get:1 http://archive.ubuntu.com/ubuntu xenial-updates/main amd64 linux-image-4.4.0-83-generic amd64 4.4.0-83.106 [21.9 MB]                  
Fetched 19.4 MB in 14min 13s (22.7 kB/s)                                                                                                    
(Reading database ... 479502 files and directories currently installed.)
Preparing to unpack .../linux-image-4.4.0-83-generic_4.4.0-83.106_amd64.deb ...
Examining /etc/kernel/preinst.d/
run-parts: executing /etc/kernel/preinst.d/intel-microcode 4.4.0-83-generic /boot/vmlinuz-4.4.0-83-generic
Done.
Unpacking linux-image-4.4.0-83-generic (4.4.0-83.106) ...
dpkg: error processing archive /var/cache/apt/archives/linux-image-4.4.0-83-generic_4.4.0-83.106_amd64.deb (--unpack):
 cannot copy extracted data for './boot/abi-4.4.0-83-generic' to '/boot/abi-4.4.0-83-generic.dpkg-new': failed to write (No space left on device)
No apport report written because the error message indicates a disk full error
                                                                              dpkg-deb: error: subprocess paste was killed by signal (Broken pipe)
Examining /etc/kernel/postrm.d .
run-parts: executing /etc/kernel/postrm.d/initramfs-tools 4.4.0-83-generic /boot/vmlinuz-4.4.0-83-generic
run-parts: executing /etc/kernel/postrm.d/zz-update-grub 4.4.0-83-generic /boot/vmlinuz-4.4.0-83-generic
Errors were encountered while processing:
/var/cache/apt/archives/linux-image-4.4.0-83-generic_4.4.0-83.106_amd64.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)

No I didn't create any partitions or allocate additional space for /Boot.

  • Could you please post text files, dialogue messages, and program output listings as text, not as images? To achieve the latter two you can either 1) select, copy & paste the dialogue text or terminal content or 2) save the program output to a file and use that. Longer listings (the editor will tell you what's too long) should be uploaded to a pastie service and linked to in the question. Thanks. – David Foerster Jul 08 '17 at 06:56
  • Did you try to run the command suggested in the output of apt-get, i. e. sudo apt-get install -f? Could you please [edit] your question to include its output? Thanks. – David Foerster Jul 08 '17 at 06:57

2 Answers2

0

This is probably caused by having too many old kernels installed.

If you're happy with your current kernel and want to remove all the older ones, you can use this command to remove all kernels except the currently used one:

sudo dpkg --list | grep linux-image | awk '{ print $2 }' | sort -V | sed -n '/'uname -r'/q;p' | xargs sudo apt-get -y purge

I got this from this answer: https://askubuntu.com/a/254585/19779. I just ran it on my own computer to be sure it works as intended. It freed up 650MB. :)

0
not enough disk space in /Boot.

Can you mention whether or not you're using a separate disk partition for /boot? In case you did custom installation and created a separate boot partition, you might not have allocated enough space for it. I personally allocate a good 1GB for the /boot partition.