Results 1 to 5 of 5

Thread: Force ufw firewall to log only to a specific log file?

  1. #1
    Join Date
    Oct 2010
    Beans
    9

    Force ufw firewall to log only to a specific log file?

    How can I make ufw log only to a specific log file, such as "/var/log/ufw.log"?

    The ufw man page says "Logged packets use the LOG_KERN syslog facility." This seems to redundantly fill up "/var/log/ufw.log", /var/log/kern.log and /var/log/messages with identical ufw log entries. I have ufw logging set to low. There doesn't seem to be any more log configuration options, either via the ufw command line or the handful of ufw configuration files I found.

  2. #2
    wojox is offline I Ubuntu, Therefore, I Am
    Join Date
    Apr 2009
    Beans
    8,630

    Re: Force ufw firewall to log only to a specific log file?

    Try and run

    Code:
    cat /var/log/messages | grep UFW
    You turned it on right?

    Code:
    sudo ufw logging on

  3. #3
    Join Date
    Oct 2010
    Beans
    9

    Re: Force ufw firewall to log only to a specific log file?

    Quote Originally Posted by wojox View Post
    You turned it on right?
    Yes... logging is definitely working. Like I said, currently it's logging to multiple files, filling up messages and kern.log with identical entries as ufw.log.

    I want to only log to ufw.log.

  4. #4
    Join Date
    Oct 2010
    Beans
    9

    Re: Force ufw firewall to log only to a specific log file?

    *bump*

    I've been Googling and I haven't really found anything helpful other than a couple others complaining about the same thing.

  5. #5
    Join Date
    Jan 2008
    Beans
    11
    Distro
    Ubuntu 10.10 Maverick Meerkat

    Re: Force ufw firewall to log only to a specific log file?

    This might be helpful:

    http://vincom2.wordpress.com/2010/04...erate-logfile/

    I tested it and it works.

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •