Artificial intelligent assistant

motd - UNIX - AIX - different welcome screens for diff users is it possible to segregate different motd files for different users ? So Admin gets a different message and others diff one....

After a long search, I came up with the idea:

edit the /etc/profile and add the below loop to the end but before TRAP..


#!/bin/ksh
ROOTY=$(whoami)
if [ ${ROOTY} != root ] ; then
for i in `who am i |awk {'print $1'}`
do
RID=$i
UNIXADM=$(sudo cat /home/root/unixusers | grep -Fx $RID | wc -l)
if [ ${UNIXADM} == 1 ] ; then
cat /etc/motd.unixusers
fi
done
fi


where /home/root/unixusers will be the user list /etc/motd.unixusers is the user specific motd

xcX3v84RxoQ-4GxG32940ukFUIEgYdPy ee8de8e1833b65451cf30bf80d20e292