0

I had installed python jasmin for trying out. But now I am unable to remove it. Also it is causing problem while installing or updating other packages also. I get the following error while running apt-get upgrade

Extracting templates from packages: 100%
Preconfiguring packages ...
(Reading database ... 332480 files and directories currently installed.)
Removing python-jasmin (0.9.27) ...
Failed to stop jasmind.service: Unit jasmind.service not loaded.
dpkg: error processing package python-jasmin (--remove):
 subprocess installed post-removal script returned error exit status 5
Errors were encountered while processing:
 python-jasmin
E: Sub-process /usr/bin/dpkg returned an error code (1)

adding the output of apt-cache policy python-jasmin

python-jasmin:
  Installed: 0.9.27
  Candidate: 0.9.27
  Version table:
 *** 0.9.27 500
        500 https://packagecloud.io/jookies/python-jasmin/ubuntu xenial/main amd64 Packages
        500 https://packagecloud.io/jookies/python-jasmin/ubuntu xenial/main i386 Packages
        100 /var/lib/dpkg/status
     0.9.26 500
        500 https://packagecloud.io/jookies/python-jasmin/ubuntu xenial/main amd64 Packages
        500 https://packagecloud.io/jookies/python-jasmin/ubuntu xenial/main i386 Packages

also the file /etc/init.d/jasmind is empty.

How do I fix this?

2

The package’s maintainer scripts are broken, and you should remove them before attempting to uninstall the package:

sudo rm /var/lib/dpkg/info/python-jasmin.{pre,post}rm
sudo apt purge python-jasmin

This will restore your system to its previous state, mostly. You can clean up completely by following up with

sudo rm -rf /etc/jasmin /var/log/jasmin
0

It looks like the service that is trying to stop it does not exist: did you installed successfully the package before you found this trouble?

Following the URL your sources.list(5) calls you can find:

"last push: 8 months ago | 10 packages jookies is not collaborating on any repos..."

It would be useful to know all steps you made (if any) to avoid reiterating your effort finding the solution.

  • The error message indicates that the service exists, but isn’t running. – Stephen Kitt Jan 1 at 17:30

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.