#!/bin/rc
# remote command for single slave invoked by "mrun"
bind /mnt/term/usr /usr
cd /usr/none
echo sys is $sysname
dom=`{ndb/query sys $sysname dom}
dom=`{ndb/query sys $sysname dom}
if(! ~ $dom ?*)
	dom=$sysname
t=host/$sysname
if(test -e $t)
	rm -rf $t
a=`{ls /tmp}
if(! ~ $a ?*)
	echo clean /tmp >>$t
if not
	echo dirty /tmp >>$t
touch /tmp/t >[2] /dev/null
if(! ~ $status ?*)
	echo writable /tmp >>$t
if not
	echo protected /tmp >>$t
ramfs >[2] /dev/null
if(! ~ $status ?*)
	echo ramfs OK >>$t
if not
	echo ramfs NG >>$t
# check if python is OK
./prun >> $t >[2] /dev/null
if(~ $status ?*)
	echo Python is NG >> $t
