8

Where can the pfsense log files be located and viewed?

I have searched the documentation and it doesn't indicate the log files location for the various components of pfsense.

9

In the nanobsd 2.0.3 release at least, they are found by going to:

  • cd /var/log (not plural logs ;)
  • clog system.log | less
    • Replace system.log with name of any log in the directory.
    • Because these log files are not regular text files, but are actually binary circular logs, then the clog utility is used to view them and | less pipes the output to less so that you can scroll up and down through the logs using page up/down keys. Press q to exit.
  • When you are done viewing logs and want to return from the shell prompt back to the pfsense menu, type exit at the command prompt.
  • 1
    This answer is almost too beginner-friendly for someone I'd trust with console access to a pfSense device. – mwfearnley Oct 9 '17 at 13:56
  • 1
    @mwfearnley Guess you don't have to worry since no one here is asking you for access. That said, circular logs aren't super common that I'd expect everyone to be familiar with them off the cuff. – AaronLS Oct 10 '17 at 14:08
  • Yes, the clog info is helpful. – mwfearnley Oct 10 '17 at 14:21
  • Looking back, my initial comment wasn't very constructive.. Giving the location (indirectly) and advising to use clog / less are very useful. But using cd to change directories should be known already, and is actually not needed, since you can do clog /var/log/system.log directly. Also, just to say this is information still works up to at least v2.4 on FreeBSD. – mwfearnley Dec 14 '18 at 12:35
2

pfSense stores its log files in the /var/log directory.

The logs are not stored in the standard text-based format. Instead they are stored in a 'circular logging' format. Use the clog tool to view the logs. You can use it similarly to the tail command. i.e. clog -f /var/log/system.log will display the entire log and then continue to 'follow' it.

0

Simpler way of looking at logs - log into the pfsense web console and Select 'Edit File' within 'Diagnostics'. Here you can browse the directory /var/log/system.log.

Example:

pfsense logs

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.