PDA

View Full Version : [SOLVED] dpkg error coded 1 when removing gnome-shell



45acp
June 22nd, 2010, 01:48 PM
Tried sudo apt-get remove gnome-shell -f Didn't work Still returns:
Errors were encountered while processing:
gnome-shell
E: Sub-process /usr/bin/dpkg returned an error code (1)

How so I fix this?

Thanks in advance.

45acp
June 22nd, 2010, 01:50 PM
I also got:

E: gnome-shell: subprocess installed post-removal script returned error exit status 127

when I tried to remove it with synaptic.

wojox
June 22nd, 2010, 02:13 PM
Try try apt-get -f install

apt-get upgrade

45acp
June 22nd, 2010, 02:19 PM
Now I got this after running the above:

james@james-desktop:~$ sudo apt-get -f install
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages will be REMOVED:
gnome-shell
0 upgraded, 0 newly installed, 1 to remove and 0 not upgraded.
1 not fully installed or removed.
After this operation, 2,245kB disk space will be freed.
Do you want to continue [Y/n]? y
(Reading database ... 213323 files and directories currently installed.)
Removing gnome-shell ...
/var/lib/dpkg/info/gnome-shell.postrm: 10: glib-compile-schemas: not found
dpkg: error processing gnome-shell (--remove):
subprocess installed post-removal script returned error exit status 127
Errors were encountered while processing:
gnome-shell
E: Sub-process /usr/bin/dpkg returned an error code (1)


james@james-desktop:~$ sudo apt-get -f upgrade
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages will be REMOVED:
gnome-shell
0 upgraded, 0 newly installed, 1 to remove and 0 not upgraded.
1 not fully installed or removed.
After this operation, 2,245kB disk space will be freed.
Do you want to continue [Y/n]? y
(Reading database ... 213323 files and directories currently installed.)
Removing gnome-shell ...
/var/lib/dpkg/info/gnome-shell.postrm: 10: glib-compile-schemas: not found
dpkg: error processing gnome-shell (--remove):
subprocess installed post-removal script returned error exit status 127
Errors were encountered while processing:
gnome-shell
E: Sub-process /usr/bin/dpkg returned an error code (1)

wojox
June 22nd, 2010, 02:27 PM
Back to square one :p

wojox
June 22nd, 2010, 02:32 PM
sudo apt-get clean
sudo apt-get update

45acp
June 22nd, 2010, 02:39 PM
I deleted everything in /var/lib/dpkg/info/ that had to do with gnome-shell. Now I am no longer getting the error message. When I removed it I got:

james@james-desktop:~$ sudo apt-get upgrade
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages will be REMOVED:
gnome-shell
0 upgraded, 0 newly installed, 1 to remove and 0 not upgraded.
1 not fully installed or removed.
After this operation, 2,245kB disk space will be freed.
Do you want to continue [Y/n]? y
(Reading database ...
dpkg: warning: files list file for package `gnome-shell' missing, assuming package has no files currently installed.
(Reading database ... 213322 files and directories currently installed.)
Removing gnome-shell ...


I don't know if I actually removed gnome-shell but I can add and remove programs now.

rp88
June 22nd, 2010, 08:40 PM
I also had the same problem. Here is what i did to fix it.

sudo gedit /var/lib/dpkg/info/gnome-shell.postrm

in that file there is a line: remove|purge) glib-compile-schemas /usr/share/glib-2.0/schemas ;;

replace that line with: install) glib-compile-schemas /usr/share/glib-2.0/schemas ;;

Save and close it.

Then run: sudo apt-get purge gnome-shell

Da CalebMan
June 24th, 2010, 12:34 PM
Dude, it's illegal to be that smart ;)

Thanks man, you're a life-saver :D

~STEELBANANA

starnixsa
June 25th, 2010, 05:43 PM
@rp88

Thanks, that fixed it! :)