xbianonpi / xbian

XBMC on Raspberry Pi, Bleeding Edge
https://xbian.org
GNU General Public License v3.0
294 stars 44 forks source link

Error: sysfs is not existing volume #567

Closed bellini666 closed 10 years ago

bellini666 commented 10 years ago

The full log:

The following packages will be upgraded:
  xbian-package-config-shell xbian-package-xbmc-scripts xbian-update
3 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
Need to get 650 kB of archives.
After this operation, 0 B of additional disk space will be used.
Do you want to continue [Y/n]? y
Get:1 http://xbian.brantje.com/ stable/main xbian-package-xbmc-scripts armhf 1.0.8-3 [25,8 kB]
Get:2 http://xbian.brantje.com/ stable/main xbian-package-config-shell armhf 2.1.7-7 [555 kB]
Get:3 http://xbian.brantje.com/ stable/main xbian-update armhf 1.0.2-101a [69,6 kB]
Fetched 650 kB in 4s (144 kB/s)    
Error: sysfs is not existing volume.
E: Problem executing scripts DPkg::Pre-Invoke '[ ! -e /etc/default/xbian-snap ] || . /etc/default/xbian-snap; [ $ENABLEDAPT = yes ] || exit 0; z=$(findmnt -n | grep -m1 . | awk '{print $2}'); z=${z#*\[\/}; export z=${z%%\/*}; if [ -x /usr/sbin/btrfs-auto-snapshot ]; then btrfs-auto-snapshot snapshot -k $KEEPAPT -l apt-run $z ;  fi ;'
E: Sub-process returned an error code

To reproduce this you have to:

1) Upgrade xbian and reboot 2) After that reboot, upgrade it again. The error will happen.

So, it's a problem trying to upgrade the system on the reboot after the previous upgrade boot.

The workaround has been to reboot again in that situation so the error will vanish.

bellini666 commented 10 years ago

Btw, I'm on stable+staging

mk01 commented 10 years ago

xbian-update 101 or 102 (definitely part of last 103) should have fixed this as discussed already here:

https://github.com/xbianonpi/xbian/issues/551#issuecomment-45683728

the relevant file is /etc/apt/apt.conf.d/06xbian-btrfs and change is

findmnt -n | grep -m1 .

changed to

findmnt -n / 
mk01 commented 10 years ago

also there is important point that only systems with kernels 3.14 and higher are affected where the wrapper workaround is used in order for findmnt to work.

(wrapper is forcing raw output thus "/" is not on top anymore)

bellini666 commented 10 years ago

@mk01 yes I can confirm that the issue is really resolved!

I'm going to close it for you! :)

alexsalex commented 3 years ago

Totally fresh install

root@CarMC:/home/xbian# lsb_release -a
No LSB modules are available.
Distributor ID: Debian
Description:    Debian GNU/Linux 11 (bullseye)
Release:    11
Codename:   bullseye

Do you want to continue? [Y/n]
E: Problem executing scripts DPkg::Pre-Invoke '[ -e /etc/default/xbian-snap ] && . /etc/default/xbian-snap; [ $ENABLEDAPT = yes ] || exit 0; z=$(findmnt -n / | awk '{print $2}'); z=${z#*\[\/}; echo $z | grep -q '\]' && z=${z%%\/*}; which xbian-snapper >/dev/null && xbian-snapper -k $KEEPAPT -l apt-run $z;'
E: Sub-process returned an error code