• inn server last users script

    From rek2 hispagatos@21:1/5 to All on Thu Apr 18 02:06:02 2024
    for troubleshooting I just wrong a small bash tool
    to see logged in users for the last 2 days, easy to modify

    cat usenet_users.sh
    journalctl -u nnrpd --since "2 days ago" | grep match_user | awk '{
    color_green="\033[32m";
    color_white="\033[97m";
    color_reset="\033[0m";
    bold_on="\033[1m";
    color_red="\033[31m";

    date = $1 " " $2;
    time = $3;
    user = $8;

    printf("%s%-12s %s%-10s %s%-10s %s%s\n",
    color_green, "Date: " date,
    color_white, time,
    bold_on, "User:",
    color_reset, color_red user color_reset);
    }' | uniq


    Happy Hacking
    ReK2

    --
    - {gemini,https}://{,rek2.}hispagatos.org - mastodon: @rek2@hispagatos.space
    - [https|gemini]://2600.Madrid - https://hispagatos.space/@rek2
    - https://keyoxide.org/A31C7CE19D9C58084EA42BA26C0B0D11E9303EC5

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)