How to Check your PiVPN logs on your Raspberry Pi
If you are running your PiVPN on your Raspberry Pi it is most likely exposed to the internet so that you can use your VPN away from your house. You will definitely want to make sure your Raspberry Pi is up to date with the latest security updates as well as checking your logs periodically to see if anyone has attempted to gain access to your system or worse, to see if anyone has accessed your system.
To use VNC to access our Raspberry Pi Remotely
You will need the following:
I will assume you are running Raspbian on your Raspberry Pi and have already installed PiVPN using the tutorial here. You are most likely running your Raspberry Pi headless if this is your PiVPN server so you will need to SSH into your Raspberry Pi. If you are not running your Raspberry Pi headless you can still run the same commands below in your terminal.
The PiVPN logs will be located here: /var/log/openvpn.log
Open a terminal window or SSH into your Raspberry Pi VPN server and use the following command to allow access to your log file so that you can open it or download it.
sudo chmod 777 /var/log/openvpn.log
You can now navigate to your log file by going to /var/log and open the openvpn.log file. If you are connected to your server over SSH you can quickly view the file using the command below. The problem using the cat command to read the log file is that it may be messy and difficult to read. My recommendation would be to SFTP to your server and download the log file. You can follow my tutorial on how to setup your Raspberry Pi for SFTP here.
Below is an example of what you should be seeing in the log file. It will include IP Addresses of connected devices as well as attempted connections to your VPN server.