openvpnのログにタイムスタンプを追加
openvpnのログ(/var/log/openvpn.log)では、デフォルトではタイムスタンプが無効になっています。これはLinuxのsystemdサービス設定でタイムスタンプの出力を抑制するオプション(--suppress-timestamps)が有効になっていることが原因です
このオプションを無効にすれば、タイムスタンプが表示されます。下記の手順はRockyLinux 9で実施しています
$ sudo vim /etc/systemd/system/multi-user.target.wants/openvpn-server@server.service #ExecStart=/usr/sbin/openvpn --status %t/openvpn-server/status-%i.log --status-version 2 --suppress-timestamps --cipher AES-256-GCM --data-ciphers AES-256-GCM:AES-128-GCM:AES-256-CBC:AES-128-CBC --config %i.conf ExecStart=/usr/sbin/openvpn --status %t/openvpn-server/status-%i.log --status-version 2 --cipher AES-256-GCM --data-ciphers AES-256-GCM:AES-128-GCM:AES-256-CBC:AES-128-CBC --config %i.conf
変更が終わったら、systemdのデーモンをリロードしてOpenVPNサービスを再起動します。
$ sudo systemctl daemon-reload $ sudo systemctl restart openvpn-server@server.service

