From: e64022a@center.osaka-u.ac.jp (MASUTANI Yasuhiro)
Newsgroups: fj.windows.x
Subject: Re: xdmshell (Re: How to record sessions in wtmp for X )
Date: 8 Apr 92 18:03:07 GMT
	<TOM.92Apr8220259@endor.soum.co.jp>
Followup-To: fj.windows.x
Distribution: fj
Organization: Computation Center, Osaka University., JAPAN
In-reply-to: tom@soum.co.jp's message of 8 Apr 92 13:02:59 GMT

$@Bg:eBg3X$N>#C+$G$9!%(J

In article <TOM.92Apr8220259@endor.soum.co.jp> 
tom@soum.co.jp (Tomohiro Endo) writes:

 |/etc/rc $@$+2?$+$+$i!"%G%U%)%k%H$G(J xdm $@$,N)$A>e$,$j!">o$K%3%s%=!<%k$K(J$@$O(J
 |xdm $@$N(J greeting window $@$,=P$F$$$k>uBV!J%m%0%$%s$rBT$C$F$$$k>uBV!K$G!"(J
 |CTRL-R $@$r2!$7$F$7$^$&$H$$(J$@$&$3$H$G$9$+!)(J

$@$O$$!%$=$NDL$j$G$9!%(J

 |$@$&!<$s!"K\Mh$O(J xdm $@$r>o$KF0$+$7$C$Q$J$7$K$7$F!"$+$D%3%s%=!<%k(J$@$bLLE]8+(J
 |$@$5$;$h$&$H$$$&$H$-$O(J CTRL-R $@$NDj5A$rH4$+$J$$$H$$$1$J$$$3$H$K$J$C$F$^$9!#(J
 |$@$H$$$&$h$j!"(JCTRL-R $@$O(J xdmshell $@$N$?$a$KDj5A$5$l$F$$$k$H9M$($?J}$,NI$$(J
 |$@$G$7$g$&!#(J

$@$($C!%$=$&$J$s$G$9$+!%(J

 | >kill -HUP $@$7$J$$8B$j!$(JX$@%5!<%P$O:F5/F0$7$J$$$N$G$7$g$&$+!%$b$7$=$&$@$H(J
 |
 |$@$=$&;W$$$^$9!#B>$K<jCJ$O$J$$$G(J$@$7$g$&!#(J
 |$@!t(J $@KM$O$d$C$F$_$?$3$H$J$$$s$G$9$,!"K\Ev$K$A$c$s$H:F5/F0$7$^$9!)(J

$@$&$^$/$$$C$F$$$k$_$?$$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O4m$J$$$+$i!J(Jroot $@$@$7(J$@!K!"(J
 |$@3F%[%9%HKh$K(J /etc/passwd $@$N%(%s%H%j$r:n$C$?J}$,NI$$$H;W$$$^$9$h!#(J

$@;d$N8@$$$?$+$C$?$N$O$3$N0UL#(J$@$G$9!J$9$$$^$;$s$o$+$j$K$/$$=q$-J}$G!K!%(J
xdm-pid$@$NCf?H$NHV9f$,K\Ev$K(Jxdm$@$N%W%m%;%9$+3NG'$7$F$$$J$$$N$O(J$@<jH4$-$G$7(J
$@$?!%$=$3$G!$2~NIHG$N%9%/%j%W%H$r:n$C$F$_$^$7$?!%(J

------------8$@!c(J---------------------------------------------------------
#! /bin/sh

if [ $LOGNAME != 'xdm' ]; then
	echo "==========================" 1>&2
	echo "      Don't use SU.       " 1>&2
	echo "==========================" 1>&2
	exit 1
fi

if [ `tty` != '/dev/console' ]; then
	echo "==========================" 1>&2
	echo " Please login on CONSOLE. " 1>&2
	echo "==========================" 1>&2
	exit 1
fi

pid=`sed 's/^ *//' /var/adm/xdm-pid`

if ps -c$pid | grep 'xdm$' > /dev/null 2>&1 ; then
	kill -HUP $pid
else
	/usr/X11R5/bin/xdmshell
	clear_colormap
fi
------------8$@!c(J---------------------------------------------------------

$@:G(J$@=i$N(Jif$@$O(Jsu xdm$@$r5q@d$9$k$?$a$N$b$N$G$9!%$3$N%A%'%C%/$NJ}K!$,E,@Z$+$I(J
$@$&$+$O<+?H$,$"$j$^$;$s!%(J

 |$@$b$&(J$@0lB)$H$$$&46$8$G$9$M(J:-)

$@$b$&>/$7$*$D$-$"$$$$$?$@$1$^$9$+(J(^_^;;
--
===============================================================
  $@>#C+!!J]Gn(J                      563 $@Bg:eI\K-Cf;TBT7s;3D.(J1-1
                                  Tel: 06-844-1151 $@Fb@~(J 4506
  $@Bg:eBg3X(J $@4pAC9)3XIt(J $@5!3#9)3X2J(J  Fax: 06-843-9730 $@D>DL(J
Newsgroups: fj.windows.x