From: Olaf Hering <olaf@aepfle.de>
To: xen-devel@lists.xensource.com
Subject: recursive error in xen-hotplug-common.sh
Date: Wed, 15 Dec 2010 20:30:39 +0100 [thread overview]
Message-ID: <20101215193039.GA9053@aepfle.de> (raw)
Current xen-unstable does not have backend/vbd/1/768/params for some
reason. This causes xenstore_read() in xen-hotplug-common.sh to call
fatal(). fatal() calls xenstore_write(). If xenstore-write happens to
fail, fatal() is called once again. Now the block script is busy.
I have added the set -x output, preceded by the env and set output:
SUBSYSTEM=xen-backend
XENBUS_TYPE=vbd
DEVPATH=/devices/xen-backend/vbd-1-768
ACTION=add
PWD=/
UDEV_LOG=3
XENBUS_PATH=backend/vbd/1/768
UDEVD_EVENT=1
XENBUS_BASE_PATH=backend
SHLVL=1
SEQNUM=1478
_=/usr/bin/env
ACTION=add
BASH=/bin/bash
BASH_ARGC=([0]="1")
BASH_ARGV=([0]="add")
BASH_LINENO=([0]="0")
BASH_SOURCE=([0]="/etc/xen/scripts/block")
BASH_VERSINFO=([0]="3" [1]="2" [2]="51" [3]="1" [4]="release" [5]="x86_64-suse-linux-gnu")
BASH_VERSION='3.2.51(1)-release'
DEVPATH=/devices/xen-backend/vbd-1-768
DIRSTACK=()
EUID=0
GROUPS=()
HOSTNAME=stein-schneider
HOSTTYPE=x86_64
IFS=$' \t\n'
MACHTYPE=x86_64-suse-linux-gnu
OPTERR=1
OPTIND=1
OSTYPE=linux-gnu
PATH=/usr/local/bin:/bin:/usr/bin:/usr/X11R6/bin:.
PIPESTATUS=([0]="0")
PPID=5717
PS4='+ '
PWD=/
SEQNUM=1478
SHELL=/bin/bash
SHELLOPTS=braceexpand:hashall:interactive-comments
SHLVL=1
SUBSYSTEM=xen-backend
TERM=dumb
UDEVD_EVENT=1
UDEV_LOG=3
UID=0
XENBUS_BASE_PATH=backend
XENBUS_PATH=backend/vbd/1/768
XENBUS_TYPE=vbd
_=echo
++ dirname /etc/xen/scripts/block
+ dir=/etc/xen/scripts
+ . /etc/xen/scripts/block-common.sh
+++ dirname /etc/xen/scripts/block
++ dir=/etc/xen/scripts
++ . /etc/xen/scripts/xen-hotplug-common.sh
++++ dirname /etc/xen/scripts/block
+++ dir=/etc/xen/scripts
+++ . /etc/xen/scripts/hotplugpath.sh
++++ SBINDIR=/usr/sbin
++++ BINDIR=/usr/bin
++++ LIBEXEC=/usr/lib/xen/bin
++++ LIBDIR=/usr/lib64
++++ SHAREDIR=/usr/share
++++ PRIVATE_BINDIR=/usr/lib64/xen/bin
++++ XENFIRMWAREDIR=/usr/lib/xen/boot
++++ XEN_CONFIG_DIR=/etc/xen
++++ XEN_SCRIPT_DIR=/etc/xen/scripts
++++ XEN_LOCK_DIR=/var/lock
+++ . /etc/xen/scripts/logging.sh
+++ . /etc/xen/scripts/xen-script-common.sh
++++ set -e
+++ . /etc/xen/scripts/locking.sh
++++ LOCK_SLEEPTIME=1
++++ LOCK_SPINNING_RETRIES=5
++++ LOCK_RETRIES=100
++++ LOCK_BASEDIR=/var/run/xen-hotplug
+++ export PATH=/usr/bin:/usr/sbin:/usr/lib/xen/bin:/usr/lib64/xen/bin:/sbin:/bin:/usr/bin:/usr/sbin:/usr/local/bin:/bin:/usr/bin:/usr/X11R6/bin:.
+++ PATH=/usr/bin:/usr/sbin:/usr/lib/xen/bin:/usr/lib64/xen/bin:/sbin:/bin:/usr/bin:/usr/sbin:/usr/local/bin:/bin:/usr/bin:/usr/X11R6/bin:.
+++ export LANG=POSIX
+++ LANG=POSIX
++++ set
++++ grep '^LC_'
++++ cut -d= -f1
+++ unset
+++ trap sigerr ERR
+++ log debug add XENBUS_PATH=backend/vbd/1/768
+++ local level=debug
+++ shift
+++ logger -p daemon.debug -- /etc/xen/scripts/block: add XENBUS_PATH=backend/vbd/1/768
++ findCommand add
++ for arg in '"$@"'
++ expr index add =
++ command=add
++ return
++ '[' add '!=' add ']'
++ XENBUS_PATH=backend/vbd/1/768
++ xenstore_read_default backend/vbd/1/768/type MISSING
++ xenstore-read backend/vbd/1/768/type
++ echo MISSING
+ t=MISSING
+ case "$command" in
++ xenstore_read_default backend/vbd/1/768/physical-device MISSING
++ xenstore-read backend/vbd/1/768/physical-device
++ echo MISSING
+ phys=MISSING
+ '[' MISSING '!=' MISSING ']'
+ '[' -n MISSING ']'
++ xenstore_read backend/vbd/1/768/params
+++ xenstore-read backend/vbd/1/768/params
xenstore-read: couldn't read path backend/vbd/1/768/params
+++ true
++ local v=
++ '[' '' '!=' '' ']'
++ fatal 'xenstore-read backend/vbd/1/768/params failed.'
++ xenstore_write backend/vbd/1/768/hotplug-error 'xenstore-read backend/vbd/1/768/params failed.' backend/vbd/1/768/hotplug-status error
++ log debug 'Writing backend/vbd/1/768/hotplug-error' 'xenstore-read backend/vbd/1/768/params failed.' backend/vbd/1/768/hotplug-status 'error to xenstore.'
++ local level=debug
++ shift
++ logger -p daemon.debug -- /etc/xen/scripts/block: 'Writing backend/vbd/1/768/hotplug-error' 'xenstore-read backend/vbd/1/768/params failed.' backend/vbd/1/768/hotplug-status 'error to xenstore.'
++ xenstore-write backend/vbd/1/768/hotplug-error 'xenstore-read backend/vbd/1/768/params failed.' backend/vbd/1/768/hotplug-status error
xenstore-write: could not write path backend/vbd/1/768/hotplug-error
++ fatal 'Writing backend/vbd/1/768/hotplug-error' 'xenstore-read backend/vbd/1/768/params failed.' backend/vbd/1/768/hotplug-status 'error to xenstore failed.'
++ xenstore_write backend/vbd/1/768/hotplug-error 'Writing backend/vbd/1/768/hotplug-error xenstore-read backend/vbd/1/768/params failed. backend/vbd/1/768/hotplug-status error to xenstore failed.' backend/vbd/1/768/hotplug-status error
++ log debug 'Writing backend/vbd/1/768/hotplug-error' 'Writing backend/vbd/1/768/hotplug-error xenstore-read backend/vbd/1/768/params failed. backend/vbd/1/768/hotplug-status error to xenstore failed.' backend/vbd/1/768/hotplug-status 'error to xenstore.'
++ local level=debug
++ shift
++ logger -p daemon.debug -- /etc/xen/scripts/block: 'Writing backend/vbd/1/768/hotplug-error' 'Writing backend/vbd/1/768/hotplug-error xenstore-read backend/vbd/1/768/params failed. backend/vbd/1/768/hotplug-status error to xenstore failed.' backend/vbd/1/768/hotplug-status 'error to xenstore.'
++ xenstore-write backend/vbd/1/768/hotplug-error 'Writing backend/vbd/1/768/hotplug-error xenstore-read backend/vbd/1/768/params failed. backend/vbd/1/768/hotplug-status error to xenstore failed.' backend/vbd/1/768/hotplug-status error
xenstore-write: could not write path backend/vbd/1/768/hotplug-error
++ fatal 'Writing backend/vbd/1/768/hotplug-error' 'Writing backend/vbd/1/768/hotplug-error xenstore-read backend/vbd/1/768/params failed. backend/vbd/1/768/hotplug-status error to xenstore failed.' backend/vbd/1/768/hotplug-status 'error to xenstore failed.'
++ xenstore_write backend/vbd/1/768/hotplug-error 'Writing backend/vbd/1/768/hotplug-error Writing backend/vbd/1/768/hotplug-error xenstore-read backend/vbd/1/768/params failed. backend/vbd/1/768/hotplug-status error to xenstore failed. backend/vbd/1/768/hotplug-status error to xenstore failed.' backend/vbd/1/768/hotplug-status error
++ log debug 'Writing backend/vbd/1/768/hotplug-error' 'Writing backend/vbd/1/768/hotplug-error Writing backend/vbd/1/768/hotplug-error xenstore-read backend/vbd/1/768/params failed. backend/vbd/1/768/hotplug-status error to xenstore failed. backend/vbd/1/768/hotplug-status error to xenstore failed.' backend/vbd/1/768/hotplug-status 'error to xenstore.'
++ local level=debug
....
Olaf
next reply other threads:[~2010-12-15 19:30 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-12-15 19:30 Olaf Hering [this message]
2010-12-16 10:38 ` recursive error in xen-hotplug-common.sh Ian Campbell
2010-12-16 11:17 ` Olaf Hering
2010-12-16 17:58 ` Ian Jackson
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20101215193039.GA9053@aepfle.de \
--to=olaf@aepfle.de \
--cc=xen-devel@lists.xensource.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.