0

I am trying to upgrade my Raspberry Pi 3 B+:

$ uname -a  
Linux plexmediaserver-pi 4.14.98-v7+ #1200 SMP Tue Feb 12 20:27:48 GMT 2019 armv7l GNU/Linux

But I am getting this weird error:

pi@plexmediaserver-pi:~ $ sudo apt update
Get:2 http://deb.debian.org/debian stretch-backports InRelease [91.8 kB]
Get:1 http://archive.raspberrypi.org/debian stretch InRelease [25.4 kB]          
Get:3 http://raspbian.raspberrypi.org/raspbian stretch InRelease [15.0 kB]           
Ign:4 https://downloads.plex.tv/repo/deb public InRelease    
Hit:5 https://downloads.plex.tv/repo/deb public Release
Err:2 http://deb.debian.org/debian stretch-backports InRelease
  Unknown error executing apt-key
Err:1 http://archive.raspberrypi.org/debian stretch InRelease
  Unknown error executing apt-key
Err:3 http://raspbian.raspberrypi.org/raspbian stretch InRelease
  Unknown error executing apt-key
Err:6 https://downloads.plex.tv/repo/deb public Release.gpg
  Unknown error executing apt-key
Reading package lists... Done
W: GPG error: http://deb.debian.org/debian stretch-backports InRelease: Unknown error executing apt-key
E: The repository 'http://deb.debian.org/debian stretch-backports InRelease' is not signed.
N: Updating from such a repository can't be done securely, and is therefore disabled by default.
N: See apt-secure(8) manpage for repository creation and user configuration details.
W: An error occurred during the signature verification. The repository is not updated and the previous index files will be used. GPG error: http://archive.raspberrypi.org/debian stretch InRelease: Unknown error executing apt-key
W: An error occurred during the signature verification. The repository is not updated and the previous index files will be used. GPG error: http://raspbian.raspberrypi.org/raspbian stretch InRelease: Unknown error executing apt-key
W: An error occurred during the signature verification. The repository is not updated and the previous index files will be used. GPG error: https://downloads.plex.tv/repo/deb public Release: Unknown error executing apt-key


root@plexmediaserver-pi:/home/pi# apt upgrade -y
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Calculating upgrade... Done
The following packages will be upgraded:
  certbot libraspberrypi-bin libraspberrypi-dev libraspberrypi-doc libraspberrypi0 plexmediaserver python3-acme python3-certbot python3-josepy raspberrypi-bootloader raspberrypi-kernel
11 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
Need to get 146 MB of archives.
After this operation, 6,475 kB disk space will be freed.
Get:1 http://archive.raspberrypi.org/debian stretch/main armhf libraspberrypi-doc armhf 1.20190517-1 [31.4 MB]
Get:2 http://ftp.icm.edu.pl/pub/Linux/distributions/raspbian/raspbian stretch/main armhf python3-josepy all 1.1.0-2~deb9u1 [27.8 kB]
Get:3 http://ftp.icm.edu.pl/pub/Linux/distributions/raspbian/raspbian stretch/main armhf python3-acme all 0.28.0-1~deb9u1 [48.7 kB]
Get:4 http://ftp.icm.edu.pl/pub/Linux/distributions/raspbian/raspbian stretch/main armhf certbot all 0.28.0-1~deb9u2 [37.7 kB]
Get:6 https://downloads.plex.tv/repo/deb public/main armhf plexmediaserver armhf 1.15.6.1079-78232c603 [74.1 MB]
Get:5 http://ftp.icm.edu.pl/pub/Linux/distributions/raspbian/raspbian stretch/main armhf python3-certbot all 0.28.0-1~deb9u2 [222 kB]
Get:7 http://archive.raspberrypi.org/debian stretch/main armhf libraspberrypi-dev armhf 1.20190517-1 [404 kB]                                                                                            
Get:8 http://archive.raspberrypi.org/debian stretch/main armhf raspberrypi-kernel armhf 1.20190517-1 [35.1 MB]                                                                                           
Get:9 http://archive.raspberrypi.org/debian stretch/main armhf libraspberrypi-bin armhf 1.20190517-1 [332 kB]                                                                                            
Get:10 http://archive.raspberrypi.org/debian stretch/main armhf libraspberrypi0 armhf 1.20190517-1 [839 kB]                                                                                              
Get:11 http://archive.raspberrypi.org/debian stretch/main armhf raspberrypi-bootloader armhf 1.20190517-1 [3,567 kB]                                                                                     
Fetched 146 MB in 53s (2,707 kB/s)                                                                                                                                                                       
Failed to import the site module
Traceback (most recent call last):
  File "/usr/lib/python3.5/site.py", line 580, in <module>
    main()
  File "/usr/lib/python3.5/site.py", line 567, in main
    known_paths = addsitepackages(known_paths)
  File "/usr/lib/python3.5/site.py", line 344, in addsitepackages
    addsitedir(sitedir, known_paths)
  File "/usr/lib/python3.5/site.py", line 212, in addsitedir
    addpackage(sitedir, name, known_paths)
  File "/usr/lib/python3.5/site.py", line 168, in addpackage
    for n, line in enumerate(f):
  File "/usr/lib/python3.5/codecs.py", line 321, in decode
    (result, consumed) = self._buffer_decode(data, self.errors, final)
UnicodeDecodeError: 'utf-8' codec can't decode byte 0xbb in position 57: invalid start byte
Use of uninitialized value $value in substitution (s///) at /usr/share/perl5/Debconf/Format/822.pm line 65, <__ANONIO__> line 51.
Use of uninitialized value $item in hash element at /usr/share/perl5/Debconf/DbDriver/File.pm line 85, <__ANONIO__> chunk 54.
dpkg: error processing archive /tmp/apt-dpkg-install-t5lPVw/00-python3-josepy_1.1.0-2~deb9u1_all.deb (--unpack):
 subprocess dpkg-split returned error exit status 11
dpkg: error processing archive /tmp/apt-dpkg-install-t5lPVw/01-python3-acme_0.28.0-1~deb9u1_all.deb (--unpack):
 subprocess dpkg-split returned error exit status 11
dpkg: error processing archive /tmp/apt-dpkg-install-t5lPVw/02-certbot_0.28.0-1~deb9u2_all.deb (--unpack):
 subprocess dpkg-split returned error exit status 11
dpkg: error processing archive /tmp/apt-dpkg-install-t5lPVw/03-python3-certbot_0.28.0-1~deb9u2_all.deb (--unpack):
 subprocess dpkg-split returned error exit status 11
dpkg: error processing archive /tmp/apt-dpkg-install-t5lPVw/04-libraspberrypi-doc_1.20190517-1_armhf.deb (--unpack):
 subprocess dpkg-split returned error exit status 11
dpkg: error processing archive /tmp/apt-dpkg-install-t5lPVw/05-libraspberrypi-dev_1.20190517-1_armhf.deb (--unpack):
 subprocess dpkg-split returned error exit status 11
dpkg: error processing archive /tmp/apt-dpkg-install-t5lPVw/06-raspberrypi-kernel_1.20190517-1_armhf.deb (--unpack):
 subprocess dpkg-split returned error exit status 11
dpkg: error processing archive /tmp/apt-dpkg-install-t5lPVw/07-libraspberrypi-bin_1.20190517-1_armhf.deb (--unpack):
 subprocess dpkg-split returned error exit status 11
dpkg: error processing archive /tmp/apt-dpkg-install-t5lPVw/08-libraspberrypi0_1.20190517-1_armhf.deb (--unpack):
 subprocess dpkg-split returned error exit status 11
dpkg: error processing archive /tmp/apt-dpkg-install-t5lPVw/09-raspberrypi-bootloader_1.20190517-1_armhf.deb (--unpack):
 subprocess dpkg-split returned error exit status 11
dpkg: error processing archive /tmp/apt-dpkg-install-t5lPVw/10-plexmediaserver_1.15.6.1079-78232c603_armhf.deb (--unpack):
 subprocess dpkg-split returned error exit status 11
Errors were encountered while processing:
 /tmp/apt-dpkg-install-t5lPVw/00-python3-josepy_1.1.0-2~deb9u1_all.deb
 /tmp/apt-dpkg-install-t5lPVw/01-python3-acme_0.28.0-1~deb9u1_all.deb
 /tmp/apt-dpkg-install-t5lPVw/02-certbot_0.28.0-1~deb9u2_all.deb
 /tmp/apt-dpkg-install-t5lPVw/03-python3-certbot_0.28.0-1~deb9u2_all.deb
 /tmp/apt-dpkg-install-t5lPVw/04-libraspberrypi-doc_1.20190517-1_armhf.deb
 /tmp/apt-dpkg-install-t5lPVw/05-libraspberrypi-dev_1.20190517-1_armhf.deb
 /tmp/apt-dpkg-install-t5lPVw/06-raspberrypi-kernel_1.20190517-1_armhf.deb
 /tmp/apt-dpkg-install-t5lPVw/07-libraspberrypi-bin_1.20190517-1_armhf.deb
 /tmp/apt-dpkg-install-t5lPVw/08-libraspberrypi0_1.20190517-1_armhf.deb
 /tmp/apt-dpkg-install-t5lPVw/09-raspberrypi-bootloader_1.20190517-1_armhf.deb
 /tmp/apt-dpkg-install-t5lPVw/10-plexmediaserver_1.15.6.1079-78232c603_armhf.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)
root@plexmediaserver-pi:/home/pi# python
Segmentation fault

It started when I tried to download subtitles with subliminal, but I've got this strange Segmentation fault error.
I've tried to uninstall, install, upgrade, remove... nothing is working. No python program is working. Some apt actions are not working as well.

  • Did you update first? The best option is to restore from your backup and try again. – Milliways Jun 9 at 9:23
  • Yes, I've issued sudo apt update first. I don't want to restore, because I don't have a backup. :( – Ricardo Silva Jun 9 at 9:51
  • Do you modified /etc/apt/sources.list and /etc/apt/sources.list.d/raspi.list? How do you install the plex mediaserver? I cannot find it in the default Raspbian repository. Please address me with @Ingo, otherwise I won't see your reply. – Ingo Jun 12 at 10:56

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.