[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Who changed



Hi
I use the who command in my .zlogin for counting how many times I'm logged in.
who | awk '$1 == "'$USER'"' | wc -l

previously the output was something like
user tty1
user pts/2
so user was 2 times logged in

However the who output seems to be changed in:

NAME       LINE         TIME             IDLE          PID COMMENT  EXIT
           system boot  2017-01-03 15:56
user     - tty1         2017-01-03 15:58 01:52        1067
           run-level 5  2017-01-03 15:59
           pts/2        2017-01-03 17:22             14868 id=ts/2  term=0 exit=0

Does anybody knows an alternative so I can count my loggins again

Thanks

Reply to: