Skip to main content

Log messages by facility and level.

Project description

A quick program to write to a specified log facility at a specified log level.

I originally wrote this so I had a way to quickly and easily test my syslog-ng configuration. Of course there were probably already programs that would do this, but for whatever dumb reason, I couldn’t find them. (logger came to mind much later - On the bright side, it gave me the opportunity to mock the Python logging class for my unit test, using Gary Bernhardt’s Dingus library. I also used his Expecter library again. Big thanks to Gary. He’s been my goto for Python + TDD.


Syslogger is in pypi at To install, simply use pip.

` pip install syslogger `

or maybe

` sudo pip install --upgrade syslogger `


syslogger runs from the command line.

` syslogger FACILITY LEVEL [--address ADDRESS] MESSAGE `

where FACILITY is one of:

  • AUTH
  • CRON
  • FTP
  • KERN
  • LPR
  • MAIL
  • NEWS
  • USER
  • UUCP
  • LOCAL0
  • LOCAL1
  • LOCAL2
  • LOCAL3
  • LOCAL4
  • LOCAL5
  • LOCAL6
  • LOCAL7

and LEVEL is one of:

  • INFO

and ADDRESS is the address of the socket that your system logger is listening to (defaults to /dev/log),

and MESSAGE is the message you’d like to log.


If you think syslogger might make your Python logging easier, feel free to use it in your code too.

` from syslogger.syslogger import Syslogger l = Syslogger(level="CRITICAL", facility="AUTH", address="/dev/log") l.log("Hello world, love syslogger") `

Project details

Release history Release notifications

This version
History Node


History Node


History Node


History Node


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Filename, size & hash SHA256 hash help File type Python version Upload date
Syslogger-0.0.4.tar.gz (3.8 kB) Copy SHA256 hash SHA256 Source None Jan 31, 2013

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging CloudAMQP CloudAMQP RabbitMQ AWS AWS Cloud computing Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page