WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-bugs

[Xen-bugs] [Bug 1470] Not only status executes network-* start

To: xen-bugs@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-bugs] [Bug 1470] Not only status executes network-* start
From: bugzilla-daemon@xxxxxxxxxxxxxxxxxxx
Date: Fri, 4 Sep 2009 02:17:59 -0700
Delivery-date: Fri, 04 Sep 2009 02:18:19 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <bug-1470-3@xxxxxxxxxxxxxxxxxxxxxxxxxxx/bugzilla/>
List-help: <mailto:xen-bugs-request@lists.xensource.com?subject=help>
List-id: Xen Bugzilla <xen-bugs.lists.xensource.com>
List-post: <mailto:xen-bugs@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-bugs>, <mailto:xen-bugs-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-bugs>, <mailto:xen-bugs-request@lists.xensource.com?subject=unsubscribe>
Reply-to: bugs@xxxxxxxxxxxxxxxxxx
Sender: xen-bugs-bounces@xxxxxxxxxxxxxxxxxxx
http://bugzilla.xensource.com/bugzilla/show_bug.cgi?id=1470





------- Comment #2 from adamc@xxxxxxx  2009-09-04 02:17 -------
I've made some modification in scripts, just added some 'echos' and 'prints'
for debug:

#####################################################################
/usr/lib/xen-3.2-1/bin/xend, l.117:

print 'In /usr/lib/xen-3.2-1/bin/xend, l. 117, sys.argv: %s' % sys.argv

#####################################################################
/usr/lib/xen-3.2-1/lib/python/xen/xend/server/SrvDaemon.py, l.327:

print '/usr/lib/xen-3.2-1/lib/python/xen/xend/server/SrvDaemon.py, l.327, we
are in stop function'

#####################################################################
/usr/lib/xen-3.2-1/lib/python/xen/xend/server/SrvDaemon.py, l.333:

print '/usr/lib/xen-3.2-1/lib/python/xen/xend/server/SrvDaemon.py, l.333, we
are in run function'

#####################################################################
/etc/xen/scripts/xen-script-common.sh, l.22-47:

evalVariables()
{ 
  for arg in "$@"
  do
    if expr 'index' "$arg" '=' '>' '1' >/dev/null
    then
        echo "Function evalVariables in script
/etc/xen/scrits/xen-script-common.sh - \$arg: $arg"
      eval "$arg"
    fi                                                        
  done                                                        
}

findCommand()
{
  for arg in "$@"
  do
    if ! expr 'index' "$arg" '=' >/dev/null
    then
      command="$arg"
        echo "Function findCommand in script
/etc/xen/scripts/xen-script-common.sh \$command: $command"
      return
    fi
  done
}

#####################################################################
/etc/xen/scripts/network-dummy:

#!/bin/sh

dir=$(dirname "$0")
. "$dir/xen-script-common.sh"
echo "${0} args: ${@}"
findCommand "$@"
evalVariables "$@"

exit 0
#####################################################################

I can see the results:
debian:~# /etc/init.d/xend start
Starting XEN control daemon: xend
/etc/xen/scripts/network-dummy args: start
Function findCommand in script /etc/xen/scripts/xen-script-common.sh $command:
start
In /usr/lib/xen-3.2-1/bin/xend, l. 117, sys.argv:
['/usr/lib/xen-3.2-1/bin/xend', 'status']

/etc/xen/scripts/network-dummy args: start
Function findCommand in script /etc/xen/scripts/xen-script-common.sh $command:
start
In /usr/lib/xen-3.2-1/bin/xend, l. 117, sys.argv:
['/usr/lib/xen-3.2-1/bin/xend', 'start']

/etc/xen/scripts/network-dummy args: start
Function findCommand in script /etc/xen/scripts/xen-script-common.sh $command:
start
In /usr/lib/xen-3.2-1/bin/xend, l. 117, sys.argv:
['/usr/lib/xen-3.2-1/bin/xend', 'status']
.

+--------------------------------------------------------------------+

debian:~# /etc/init.d/xend stop
Stopping XEN control daemon: xend
/etc/xen/scripts/network-dummy args: start
Function findCommand in script /etc/xen/scripts/xen-script-common.sh $command:
start
In /usr/lib/xen-3.2-1/bin/xend, l. 117, sys.argv:
['/usr/lib/xen-3.2-1/bin/xend', 'status']

/etc/xen/scripts/network-dummy args: start
Function findCommand in script /etc/xen/scripts/xen-script-common.sh $command:
start
In /usr/lib/xen-3.2-1/bin/xend, l. 117, sys.argv:
['/usr/lib/xen-3.2-1/bin/xend', 'stop']
/usr/lib/xen-3.2-1/lib/python/xen/xend/server/SrvDaemon.py, l.327, we are in
stop function
.

+---------------------------------------------------------------+
As you can see when we stop xenserver, xend gets 'stop' arg, but in network
script we get 'start' arg. (even twice, because there is xend status check
first). Why?


-- 
Configure bugmail: 
http://bugzilla.xensource.com/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

_______________________________________________
Xen-bugs mailing list
Xen-bugs@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-bugs

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-bugs] [Bug 1470] Not only status executes network-* start, bugzilla-daemon <=