Installation Error

Asked by dev.konverje

Hi,

I have a small problem. I was trying to install hddtemp via synaptic, and while installation, my computer lost power.
Prior to the powercut, I did manage to complete the steps wherein debconf asks you if you want is to start as a daemon at startup, and at which, IP and port should it be active. Before the installation could complete, I lost power.

After the powercut and booting up, Synaptic gave me an error saying that hddtemp was not installed properly, please run 'sudo dpkg --configure -a' to fix the issue. I did try that to no avail.
the following is the error that dpkg reports.

dpkg (subprocess): unable to execute installed post-installation script: Exec format error
dpkg: error processing hddtemp (--configure):
 subprocess installed post-installation script returned error exit status 2
Errors were encountered while processing:
 hddtemp
E: Sub-process /usr/bin/dpkg returned an error code (1)

I cannot install, reinstall, remove or purge it at the moment.

Is there any workaround for it.

Question information

Language:
English Edit question
Status:
Solved
For:
Ubuntu hddtemp Edit question
Assignee:
No assignee Edit question
Solved by:
dev.konverje
Solved:
Last query:
Last reply:
Revision history for this message
delance (olivier-delance) said :
#1

Open Synaptic, localize package and try "install again".

Revision history for this message
dev.konverje (dev-konverje) said :
#2

no this doesn't solve my problem.

the following is the output

Setting up hddtemp (0.3-beta15-45) ...
dpkg (subprocess): unable to execute installed post-installation script: Exec format error
dpkg: error processing hddtemp (--configure):
 subprocess installed post-installation script returned error exit status 2
Errors were encountered while processing:
 hddtemp
E: Sub-process /usr/bin/dpkg returned an error code (1)

Revision history for this message
delance (olivier-delance) said :
#3

The simplest. Under Synaptic, uninstall and install again.

Revision history for this message
dev.konverje (dev-konverje) said :
#4

no matter what i try, whether thru synaptic or thru apt-get, the same error is thrown up by dpkg.

I believe, that i have to replace a file manually , and then remove either thru apt-get or synaptic.

Or the only option is may be to remove the entire package manually, force apt-get some how to realise that is no more present and then maybe install it properly using synaptic.

What i need to know is which files to remove or change to make it look hddtemp doesn't exist on the system.
or after looking up the error generated by dpkg, maybe the contents of the post-installation script that is installed after installing

p.s. the daemon doesn't even start during boot up, as it not completely installed..

Revision history for this message
dev.konverje (dev-konverje) said :
#5

I managed to fix the problem myself.

I deleted the invalid files that dpkg was trying to read from /var/lib/dpkg/info/hddtemp*

then i used synaptic to remove hddtemp and install again.