Public bug reported:
Binary package hint: graphviz-cairo
Basically, trying to install the graphviz-cairo plugin to graphvis using
apt-get results in two shell script files sticking around in
/var/lib/dpkg/info/ that apt-get keeps trying to run, so apt-get can't
install, remove, or update anything until the two script files are
deleted manually.
I'm running Edgy, but I encountered this bug a year ago on Dapper beta and
didn't report it. The fix is easy, but it's affected several people and come up
at least three times on the forums:
http://ubuntuforums.org/showthread.php?p=2117662
http://www.ubuntuforums.org/showthread.php?t=365719
http://ubuntuforums.org/showthread.php?p=2190896
repro steps:
>sudo apt-get install graphviz-cairo
it should end like this:
Setting up graphviz-cairo (2.8-2) ...
/var/lib/dpkg/info/graphviz-cairo.postinst: 11: dot: not found
dpkg: error processing graphviz-cairo (--configure):
subprocess post-installation script returned error exit status 127
Errors were encountered while processing:
graphviz-cairo
E: Sub-process /usr/bin/dpkg returned an error code (1)
now, try using apt-get for just about anything else:
>sudo apt-get remove evolution
...
Removing evolution-plugins ...
Removing evolution-exchange ...
Removing evolution ...
Setting up graphviz-cairo (2.8-2) ...
/var/lib/dpkg/info/graphviz-cairo.postinst: 11: dot: not found
dpkg: error processing graphviz-cairo (--configure):
subprocess post-installation script returned error exit status 127
Errors were encountered while processing:
graphviz-cairo
E: Sub-process /usr/bin/dpkg returned an error code (1)
apt-get can't even uninstall graphviz-cairo and fix the problem:
>sudo apt-get remove graphviz-cairo
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages were automatically installed and are no longer required:
graphviz-cairo
Use 'apt-get autoremove' to remove them.
The following packages will be REMOVED:
graphviz-cairo
0 upgraded, 0 newly installed, 1 to remove and 1 not upgraded.
1 not fully installed or removed.
Need to get 0B of archives.
After unpacking 193kB disk space will be freed.
Do you want to continue [Y/n]? y
(Reading database ... 133226 files and directories currently installed.)
Removing graphviz-cairo ...
/var/lib/dpkg/info/graphviz-cairo.postrm: 11: dot: not found
dpkg: error processing graphviz-cairo (--remove):
subprocess post-removal script returned error exit status 127
Errors were encountered while processing:
graphviz-cairo
E: Sub-process /usr/bin/dpkg returned an error code (1)
On the other hand, the fix is quite simple.
>sudo rm /var/lib/dpkg/info/graphviz-cairo.post*
allows apt-get to work, and
>sudo aptitude remove -f graphviz-cairo
then removes the offending plugin.
The problem seems to me to be two script files,
/var/lib/dpkg/info/graphviz-cairo.postinst and
/var/lib/dpkg/info/graphviz-cairo.postrm
I know almost nothing about shell scripting, but they seem very broken. This is
graphviz-cairo.postinst: (some spaces removed)
#!/bin/sh
set -e
case "$1" in
configure)
dot -c
;;
esac
exit 0
and graphviz-cairo.postrm is almost identical:
>diff /var/lib/dpkg/info/graphviz-cairo.post*
8,9c8,9
< configure)
< dot -c
---
> remove)
> dot -c
I have no experience with this, but this seems like a somewhat serious
bug that should also be (relatively) quite easy to fix.
** Affects: graphviz-cairo (Ubuntu)
Importance: Undecided
Status: Unconfirmed
--
installing graphviz-cairo breaks apt-get until script files are manually deleted
https://launchpad.net/bugs/86914
--
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs