1

It's me again. I'm trying to run this command: sudo apt-get remove bitcoind But I'm getting this response:

Reading package lists... Done
Building dependency tree       
Reading state information... Done
You might want to run 'apt-get -f install' to correct these:
The following packages have unmet dependencies:
 linux-image-generic-hwe-16.04 : Depends: linux-image-4.15.0-46-generic but it is not going to be installed
 linux-modules-extra-4.15.0-33-generic : Depends: linux-image-4.15.0-33-generic but it is not going to be installed or
                                                  linux-image-unsigned-4.15.0-33-generic but it is not going to be installed
 linux-modules-extra-4.15.0-38-generic : Depends: linux-image-4.15.0-38-generic but it is not going to be installed or
                                                  linux-image-unsigned-4.15.0-38-generic but it is not going to be installed
 linux-modules-extra-4.15.0-42-generic : Depends: linux-image-4.15.0-42-generic but it is not going to be installed or
                                                  linux-image-unsigned-4.15.0-42-generic but it is not going to be installed
 linux-modules-extra-4.15.0-45-generic : Depends: linux-image-4.15.0-45-generic but it is not going to be installed or
                                                  linux-image-unsigned-4.15.0-45-generic but it is not going to be installed
 linux-modules-extra-4.15.0-46-generic : Depends: linux-image-4.15.0-46-generic but it is not going to be installed or
                                                  linux-image-unsigned-4.15.0-46-generic but it is not going to be installed
E: Unmet dependencies. Try 'apt-get -f install' with no packages (or specify a solution).

Then when apt-get -f install:

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:
  libdb4.8++ libllvm5.0 linux-headers-4.13.0-41
  linux-headers-4.13.0-41-generic linux-headers-4.13.0-43
  linux-headers-4.13.0-43-generic linux-headers-4.15.0-24
  linux-headers-4.15.0-24-generic linux-headers-4.15.0-29
  linux-headers-4.15.0-29-generic linux-headers-4.15.0-33
  linux-headers-4.15.0-33-generic linux-headers-4.15.0-38
  linux-headers-4.15.0-38-generic linux-headers-4.15.0-42
  linux-headers-4.15.0-42-generic linux-headers-4.15.0-45
  linux-headers-4.15.0-45-generic linux-image-4.13.0-41-generic
  linux-image-4.13.0-43-generic linux-image-4.15.0-24-generic
  linux-image-4.15.0-29-generic linux-image-4.15.0-33-generic
  linux-image-4.15.0-38-generic linux-image-4.15.0-42-generic
  linux-image-4.15.0-45-generic linux-image-extra-4.13.0-41-generic
  linux-image-extra-4.13.0-43-generic linux-image-extra-4.13.0-45-generic
  linux-modules-4.15.0-24-generic linux-modules-4.15.0-29-generic
  linux-modules-4.15.0-33-generic linux-modules-4.15.0-38-generic
  linux-modules-4.15.0-42-generic linux-modules-4.15.0-45-generic
  linux-modules-extra-4.15.0-24-generic linux-modules-extra-4.15.0-29-generic
  linux-modules-extra-4.15.0-33-generic linux-modules-extra-4.15.0-38-generic
  linux-modules-extra-4.15.0-42-generic linux-modules-extra-4.15.0-45-generic
Use 'sudo apt autoremove' to remove them.
The following additional packages will be installed:
  linux-image-4.15.0-33-generic linux-image-4.15.0-38-generic
  linux-image-4.15.0-42-generic linux-image-4.15.0-45-generic
  linux-image-4.15.0-46-generic linux-modules-4.15.0-42-generic
  linux-modules-4.15.0-45-generic linux-modules-4.15.0-46-generic
Suggested packages:
  fdutils linux-hwe-tools
The following NEW packages will be installed:
  linux-image-4.15.0-33-generic linux-image-4.15.0-38-generic
  linux-image-4.15.0-42-generic linux-image-4.15.0-45-generic
  linux-image-4.15.0-46-generic linux-modules-4.15.0-42-generic
  linux-modules-4.15.0-45-generic linux-modules-4.15.0-46-generic
0 upgraded, 8 newly installed, 0 to remove and 281 not upgraded.
75 not fully installed or removed.
Need to get 0 B/78,2 MB of archives.
After this operation, 237 MB of additional disk space will be used.
Do you want to continue? [Y/n] Y
(Reading database ... 593097 files and directories currently installed.)
Preparing to unpack .../linux-modules-4.15.0-46-generic_4.15.0-46.49~16.04.1_amd64.deb ...
Unpacking linux-modules-4.15.0-46-generic (4.15.0-46.49~16.04.1) ...
dpkg: error processing archive /var/cache/apt/archives/linux-modules-4.15.0-46-generic_4.15.0-46.49~16.04.1_amd64.deb (--unpack):
 cannot copy extracted data for './boot/System.map-4.15.0-46-generic' to '/boot/System.map-4.15.0-46-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)
Preparing to unpack .../linux-image-4.15.0-46-generic_4.15.0-46.49~16.04.1_amd64.deb ...
Unpacking linux-image-4.15.0-46-generic (4.15.0-46.49~16.04.1) ...
dpkg: error processing archive /var/cache/apt/archives/linux-image-4.15.0-46-generic_4.15.0-46.49~16.04.1_amd64.deb (--unpack):
 cannot copy extracted data for './boot/vmlinuz-4.15.0-46-generic' to '/boot/vmlinuz-4.15.0-46-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)
Preparing to unpack .../linux-image-4.15.0-33-generic_4.15.0-33.36~16.04.1_amd64.deb ...
Unpacking linux-image-4.15.0-33-generic (4.15.0-33.36~16.04.1) ...
dpkg: error processing archive /var/cache/apt/archives/linux-image-4.15.0-33-generic_4.15.0-33.36~16.04.1_amd64.deb (--unpack):
 cannot copy extracted data for './boot/vmlinuz-4.15.0-33-generic' to '/boot/vmlinuz-4.15.0-33-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)
Preparing to unpack .../linux-image-4.15.0-38-generic_4.15.0-38.41~16.04.1_amd64.deb ...
Unpacking linux-image-4.15.0-38-generic (4.15.0-38.41~16.04.1) ...
dpkg: error processing archive /var/cache/apt/archives/linux-image-4.15.0-38-generic_4.15.0-38.41~16.04.1_amd64.deb (--unpack):
 cannot copy extracted data for './boot/vmlinuz-4.15.0-38-generic' to '/boot/vmlinuz-4.15.0-38-generic.dpkg-new': failed to write (No space left on device)
No apport report written because MaxReports is reached already
                                                              dpkg-deb: error: subprocess paste was killed by signal (Broken pipe)
Preparing to unpack .../linux-modules-4.15.0-42-generic_4.15.0-42.45~16.04.1_amd64.deb ...
Unpacking linux-modules-4.15.0-42-generic (4.15.0-42.45~16.04.1) ...
dpkg: error processing archive /var/cache/apt/archives/linux-modules-4.15.0-42-generic_4.15.0-42.45~16.04.1_amd64.deb (--unpack):
 cannot copy extracted data for './boot/System.map-4.15.0-42-generic' to '/boot/System.map-4.15.0-42-generic.dpkg-new': failed to write (No space left on device)
No apport report written because MaxReports is reached already
                                                              dpkg-deb: error: subprocess paste was killed by signal (Broken pipe)
Preparing to unpack .../linux-image-4.15.0-42-generic_4.15.0-42.45~16.04.1_amd64.deb ...
Unpacking linux-image-4.15.0-42-generic (4.15.0-42.45~16.04.1) ...
dpkg: error processing archive /var/cache/apt/archives/linux-image-4.15.0-42-generic_4.15.0-42.45~16.04.1_amd64.deb (--unpack):
 cannot copy extracted data for './boot/vmlinuz-4.15.0-42-generic' to '/boot/vmlinuz-4.15.0-42-generic.dpkg-new': failed to write (No space left on device)
No apport report written because MaxReports is reached already
                                                              dpkg-deb: error: subprocess paste was killed by signal (Broken pipe)
Preparing to unpack .../linux-modules-4.15.0-45-generic_4.15.0-45.48~16.04.1_amd64.deb ...
Unpacking linux-modules-4.15.0-45-generic (4.15.0-45.48~16.04.1) ...
dpkg: error processing archive /var/cache/apt/archives/linux-modules-4.15.0-45-generic_4.15.0-45.48~16.04.1_amd64.deb (--unpack):
 cannot copy extracted data for './boot/System.map-4.15.0-45-generic' to '/boot/System.map-4.15.0-45-generic.dpkg-new': failed to write (No space left on device)
No apport report written because MaxReports is reached already
                                                              dpkg-deb: error: subprocess paste was killed by signal (Broken pipe)
Preparing to unpack .../linux-image-4.15.0-45-generic_4.15.0-45.48~16.04.1_amd64.deb ...
Unpacking linux-image-4.15.0-45-generic (4.15.0-45.48~16.04.1) ...
dpkg: error processing archive /var/cache/apt/archives/linux-image-4.15.0-45-generic_4.15.0-45.48~16.04.1_amd64.deb (--unpack):
 cannot copy extracted data for './boot/vmlinuz-4.15.0-45-generic' to '/boot/vmlinuz-4.15.0-45-generic.dpkg-new': failed to write (No space left on device)
No apport report written because MaxReports is reached already
                                                              dpkg-deb: error: subprocess paste was killed by signal (Broken pipe)
Errors were encountered while processing:
 /var/cache/apt/archives/linux-modules-4.15.0-46-generic_4.15.0-46.49~16.04.1_amd64.deb
 /var/cache/apt/archives/linux-image-4.15.0-46-generic_4.15.0-46.49~16.04.1_amd64.deb
 /var/cache/apt/archives/linux-image-4.15.0-33-generic_4.15.0-33.36~16.04.1_amd64.deb
 /var/cache/apt/archives/linux-image-4.15.0-38-generic_4.15.0-38.41~16.04.1_amd64.deb
 /var/cache/apt/archives/linux-modules-4.15.0-42-generic_4.15.0-42.45~16.04.1_amd64.deb
 /var/cache/apt/archives/linux-image-4.15.0-42-generic_4.15.0-42.45~16.04.1_amd64.deb
 /var/cache/apt/archives/linux-modules-4.15.0-45-generic_4.15.0-45.48~16.04.1_amd64.deb
 /var/cache/apt/archives/linux-image-4.15.0-45-generic_4.15.0-45.48~16.04.1_amd64.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)

Hope you can help me to figure it out as you always do. Thanks again!

root@gear:/# df -h
Filesystem                   Size  Used Avail Use% Mounted on
udev                         3,9G     0  3,9G   0% /dev
tmpfs                        798M   74M  724M  10% /run
/dev/mapper/ubuntu--vg-root 1019G  359G  618G  37% /
tmpfs                        3,9G  337M  3,6G   9% /dev/shm
tmpfs                        5,0M  4,0K  5,0M   1% /run/lock
tmpfs                        3,9G     0  3,9G   0% /sys/fs/cgroup
/dev/loop0                   138M  138M     0 100% /snap/skype/33
/dev/loop1                    87M   87M     0 100% /snap/core/4650
/dev/sda1                    472M  471M     0 100% /boot
tmpfs      

              798M  144K  798M   1% /run/user/1000
  • 1
    The messages contain your clue "No space left on device" -- you need to create space for the commands to work. – guiverc Mar 09 '19 at 00:47
  • how should I proceed? why is it asking me for space when I'm trying to remove packages? I'm in Ubuntu. When sudo apt autoremove same answer. – Felipe Galaz Mar 09 '19 at 00:57
  • 1
    The programs or package tools need some space to complete their work. Yes when they complete you'll have more disk space, but they can't write data to temporary files due to your disk space issue (pipes work thru temporary files of the data passed between programs). You need to remove some files (ie. create space) first yourself for the auto (package) tools to work (there are other clues in that link beyond the auto-fix solution that can't work until you've created enough space for it to run). When fixed, do regular maintenance or use larger partitions if you don't want this hassle. – guiverc Mar 09 '19 at 01:39
  • I have no clue what I can safely delete. How can I use a larger partition? – Felipe Galaz Mar 09 '19 at 01:42
  • Read the duplicate for good ideas on how you should proceed. – user535733 Mar 09 '19 at 02:04
  • I did. It seems I have to delete old kernel, when I try I get the same answer again. – Felipe Galaz Mar 09 '19 at 02:08

1 Answers1

0

The error message suggests:

<list of packages>...
Use 'sudo apt autoremove' to remove them.

This will remove no-longer needed packages, and free the space they used on /boot, which is 100% full.

waltinator
  • 36,399
  • when sudo apt autoremove I got the same answer. Solution: Manually erase files from /boot and once some space is created, run commands like autoremove or dpkg. – Felipe Galaz Mar 10 '19 at 00:14