Re: Client history

Bo Berglund <[email protected]>
Newsgroups gmane.network.openvpn.user
Message-ID <[email protected]>
On Tue, 20 Feb 2024 11:29:36 +0000, Peter Davis via Openvpn-users
<[email protected]> wrote:

>Hi,
>Thanks again.
>Can you make the report be saved to a file?

Are you trolling me?

What do you think this does? :

LOG_FILE="/etc/openvpn/log/server-events.log"
echo "$LOG_TIMESTAMP - $common_name connected with IP $trusted_ip" >>
"$LOG_FILE"

Solution:

1) LOG_FILE is declared as a filename
2) echo "$LOG_TIMESTAMP - $common_name ..." >> "$LOG_FILE"

The second command adds the new info to the end of the defined file

What is it you do not understand?
Or are you a troll?


-- 
Bo Berglund
Developer in Sweden
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.