1

I am finding it impossible to completely remove plex from my Ubuntu system, i get the following error:

davewold@ubuntuhome:~$ sudo aptitude purge plexmediaserver
[sudo] password for davewold: 
no talloc stackframe at ../source3/param/loadparm.c:4864, leaking memory
Ignoring unknown parameter "announce version"
The following packages will be REMOVED:  
  libavahi-core7{u} libavahi-gobject0{u} plexmediaserver{p} 
0 packages upgraded, 0 newly installed, 3 to remove and 0 not upgraded.
Need to get 0 B of archives. After unpacking 409 kB will be freed.
Do you want to continue? [Y/n/?] y
(Reading database ... 204286 files and directories currently installed.)
Removing libavahi-core7:amd64 (0.6.31-4ubuntu1) ...
Removing libavahi-gobject0:amd64 (0.6.31-4ubuntu1) ...
Processing triggers for libc-bin (2.19-0ubuntu6.6) ...
(Reading database ... 204272 files and directories currently installed.)
Removing plexmediaserver (0.9.11.7.803-87d0708-debian) ...
Plex Media Server is not running (no process found)...
update-rc.d: /etc/init.d/plexmediaserver exists during rc.d purge (use -f to force)
dpkg: error processing package plexmediaserver (--purge):
 subprocess installed pre-removal script returned error exit status 1
Errors were encountered while processing:
 plexmediaserver
E: Sub-process /usr/bin/dpkg returned an error code (1)
A package failed to install.  Trying to recover:
  • thats after using all the official commands for removal – Dave Wold Mar 20 '15 at 22:02
  • any luck with this problem? – Memes Jul 20 '16 at 9:57
3

Try to force the removal with sudo aptitude -f purge plexmediaserver If it doesn't work, try these commands:

sudo rm -f /etc/init.d/plexmediaserver
sudo dpkg --purge --force-all plexmediaserver
  • i tried that command and this is the result, i'm lost at the moment – Dave Wold Mar 20 '15 at 22:11
  • Removing plexmediaserver (0.9.11.7.803-87d0708-debian) ... Plex Media Server is not running (no process found)... update-rc.d: /etc/init.d/plexmediaserver exists during rc.d purge (use -f to force) dpkg: error processing package plexmediaserver (--purge): subprocess installed pre-removal script returned error exit status 1 Errors were encountered while processing: plexmediaserver E: Sub-process /usr/bin/dpkg returned an error code (1) A package failed to install. Trying to recover: – Dave Wold Mar 20 '15 at 22:11
  • I edited the answer, try now. – 0x2b3bfa0 Mar 20 '15 at 22:14
  • no luck i get this Plex Media Server is not running (no process found)... update-rc.d: /etc/init.d/plexmediaserver exists during rc.d purge (use -f to force) dpkg: error processing package plexmediaserver (--purge): subprocess installed pre-removal script returned error exit status 1 Errors were encountered while processing: plexmediaserver – Dave Wold Mar 20 '15 at 22:42
  • Try now. I made a edit. – 0x2b3bfa0 Mar 21 '15 at 18:14
0

Shot in the dark, but it helped me sometimes.

Reinstall the package, then try sudo apt-get --purge remove <package>.

Also make sure no process is running, related to this package.

If this doesn't work then do it the hard way..

mv /var/lib/dpkg/info/<package>.* /tmp/
dpkg --remove --force-remove-reinstreq <package>
  • won't let me reinstall, i'm going around in circles with this, i'm nearly at stage of reinstalling ubuntu – Dave Wold Mar 20 '15 at 22:49
0
cd /etc/init.d/

get rid of the plex init entry

sudo mv plexmediaserver plexmediaserver.dead

remove it from update-rc

sudo update-rc.d -f plexmediaserver remove

Uninstall

sudo apt-get --purge remove -f plexmediaserver

delete the init.d entry

sudo rm -rf plexmediaserver.dead

Your Answer

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

Not the answer you're looking for? Browse other questions tagged or ask your own question.