Upgrade failing

openhab 2.1.0 on raspbery pi 3
was working all good. played around with voice binding earlier in day.
decided to make upgrade; it failed with segmentation error; tried to use habpanel - can ZWave items are working, but not MQTT ones. Checked openhab.log file and it is full of errors.
Also following bundles in Resolve state, not starting: scheduler service; Xtext; Sound support; Basic UI Fragment; Paper UI Theme;
Tried remove /var/cache/apt/archives/python-samba_2%3a4.2.14+dfsg-0+deb8u9_armhf.deb
and
sudo dpkg -i --force-overwrite
and same result :frowning:

The following packages will be upgraded:
  python-samba
1 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
49 not fully installed or removed.
Need to get 0 B/851 kB of archives.
After this operation, 73.7 kB disk space will be freed.
Segmentation fault
(Reading database ... 45607 files and directories currently installed.)
Preparing to unpack .../python-samba_2%3a4.2.14+dfsg-0+deb8u9_armhf.deb ...
Segmentation fault
dpkg: warning: subprocess old pre-removal script returned error exit status 139
dpkg: trying script from the new package instead ...
Segmentation fault
dpkg: error processing archive /var/cache/apt/archives/python-samba_2%3a4.2.14+dfsg-0+deb8u9_armhf.deb (--unpack):
 subprocess new pre-removal script returned error exit status 139
Segmentation fault
dpkg: error while cleaning up:
 subprocess installed post-installation script returned error exit status 139
Errors were encountered while processing:
 /var/cache/apt/archives/python-samba_2%3a4.2.14+dfsg-0+deb8u9_armhf.deb
Updating FireMotD available updates count ...

Crashing my head - is the root cause python-samba related? how to get over or workaround it (I’m not using samba shares anyways)? or how to better debug? Thank You!

I guess you have the same problem, a bad sd card:

Put a backup on a new sd card and see what happens.

probably…it has to be first time one day :smiley:

I had a image burned earlier in day (probably from the original sd beeing corrupt already - if that’s the case). So, wrote that image on a new SD card, put in raspbery, loaded - trying to upgrade and getting same segmentation fault error for python-samba. don’t have proper backup/restore strategy yet, but have some results from few backup scripts. will probably give up with this “segmentation fault” and try restoring on a fresh install.

Take a look at Amanda

or raspiBackup

or integrated scripts:

1 Like

Somehow did not manage it w Amana w first try. Have to go through the doc more careful.

oh, and didn’t realize the backup/restore script must be already in the package. perfect, will give it a try! Thank you for helping with reading the docs;)

The docs have been rewritten, should be easier now.