--- vif-common.sh-orig 2007-03-05 21:51:53.000000000 +0000 +++ vif-common.sh 2007-03-06 10:34:27.000000000 +0000 @@ -31,13 +31,27 @@ exit 1 fi + case "$command" in add | remove) exit 0 ;; + online) + if [ -d /etc/xen/domU-up.d/ ]; then + name=`xenstore-read ${XENBUS_PATH}/domain` + run-parts --arg="${name}" /etc/xen/domU-up.d/ + fi + ;; + offline) + if [ -d /etc/xen/domU-down.d/ ]; then + name=`xenstore-read ${XENBUS_PATH}/domain` + run-parts --arg="${name}" /etc/xen/domU-down.d/ + fi + ;; esac + # Parameters may be read from the environment, the command line arguments, and # the store, with overriding in that order. The environment is given by the # driver, the command line is given by the Xend global configuration, and