[Ultrapossum-cvs 925] demo/uml 1.16,1.17,boot

Back to archive index

Masato Taruishi taru****@users*****
2004年 10月 19日 (火) 13:59:04 JST


===================================================================
RCS file: demo/uml/boot,v
retrieving revision 1.16
retrieving revision 1.17
diff -u -r1.16 -r1.17
--- demo/uml/boot	2004/10/19 03:59:01	1.16
+++ demo/uml/boot	2004/10/19 04:59:04	1.17
@@ -28,7 +28,8 @@
   eval `ultrapossum-config term`
   exit 1
 fi
-trap "eval `ultrapossum-config term`" 0
+
+trap "if test "x$pid" != "x"; then kill $pid; fi; /bin/rm -f $log; eval `ultrapossum-config term`" 0
 
 root=$UMLDIR/$1/hda
 
@@ -47,5 +48,16 @@
   exit 0
 fi
 
-screen -d -m -S ultrapossum-$1 $MODULEDIR/uml/uml-run $1 su -c "$linux ubd0=$root con0=fd:0,fd:1 con=pts mem=$UML_MEM eth0=tuntap,$host_if,,$host eth1=mcast,,$UML_MULTICASTADDR umid=$1 uml_dir=$UMLDIR/$1 | logger -t $1" $UML_USER
+log=$UMLDIR/$1/fifo
+
+if ! test -e "$log"; then
+  mkfifo -m 600 $log
+  chown $UML_USER $log
+fi
+
+logger -t $1 -f $log &
+pid=$!
+
+
+screen -d -m -S ultrapossum-$1 $MODULEDIR/uml/uml-run $1 su -c "$linux ubd0=$root con0=fd:0,fd:1 con=pts mem=$UML_MEM eth0=tuntap,$host_if,,$host eth1=mcast,,$UML_MULTICASTADDR umid=$1 uml_dir=$UMLDIR/$1 | tee $log" $UML_USER
 



Ultrapossum-cvs メーリングリストの案内
Back to archive index