xentaur
annotate files/xenomips.sh @ 12:54c51dea92a2
rerunning dynamips and vtysh after exit
author | igor |
---|---|
date | Fri Sep 14 12:04:44 2007 +0300 (2007-09-14) |
parents | 825cd93472de |
children | de23c23ef4ac |
rev | line source |
---|---|
igor@0 | 1 #!/bin/sh |
igor@0 | 2 |
igor@7 | 3 if grep -qi xenomips /proc/cmdline |
igor@7 | 4 then |
igor@7 | 5 DYNAMIPS_WORKDIR="/xenomips/config" |
igor@7 | 6 DYNAMIPS_ARGS=`cat /proc/cmdline | sed 's/.*xenomips="//; s/".*//'` |
igor@7 | 7 cd "$DYNAMIPS_WORKDIR" |
igor@12 | 8 screen -e '^xx' -d -m sh -c 'while true; do dynamips '$DYNAMIPS_ARGS' ; done' |
igor@7 | 9 else |
igor@7 | 10 /etc/init.d/quagga start |
igor@12 | 11 screen -e '^xx' -d -m sh -c 'while true; do vtysh; done' |
igor@7 | 12 fi |
igor@0 | 13 |