Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
LOGINTAB="/etc/logins.table"
LOGINMAX=`grep '^[ ]*'$LOGNAME $LOGINTAB | tr -s "\011" " " | \
cut -f2 -d' '`
[ -z "${LOGINMAX}" ] && LOGINMAX=8
TTY=`ps -p $$ | grep -v PID | tr -s "\011" " " | cut -f3 -d' '`
echo "You are logging in at line $TTY ..."
LOGINDEV=`/usr/bin/w | grep \^$LOGNAME | grep -v $TTY | \
tr -s "\011" " " | \
cut -f2 -d' ' | tr -s "\012" " "`
if [ $LOGINMAX -ne 0 ]
then
LOGINCNT=`echo $LOGINDEV | wc -w 2> /dev/null`
LOGINCNT=`expr ${LOGINCNT:-0} + 0`
echo "Total number of sessions loggedin $LOGINCNT"
if [ $LOGINCNT -gt $LOGINMAX ]
then
echo $LOGINCNT
# /usr/ucb/logger -p daemon.notice -t PROFILE \
# "Denied login - user <$LOGNAME> - lines $TTY and $LOGINDEV"
echo "You are already logged in [$LOGINDEV] ..."
sleep 3
kill -KILL $$
fi
fi
/usr/bin/cms