Shell script for user login information.

Hi Gurus,

I need help in writing a script which should say which user has used or logged in in the server from past one month using FTP or TELNET and the output should be of the form

Username Service NumberofTimes Date.

Thanks in Advance.

---------- Post updated at 04:01 PM ---------- Previous update was at 04:00 PM ----------

Addition to the thread Duration of logins should be from past one month.

Thank you,

---------- Post updated at 05:17 PM ---------- Previous update was at 05:16 PM ----------

last -R command to get all details