Results 1 to 2 of 2
  1. #1
    Datasponge is offline Member
    Join Date
    Jan 2010
    Rep Power

    Default Making SyslogAppender write to ONLY 1 log


    I'm trying to configure a SyslogAppender to write to only 'syslog'. Currently it writes to our custom log, syslog, messages, local0. Within the syslog config file I set LOCAL0 = syslog. I thought that this would direct it to write to only syslog, but as I stated above it does not. Below is the runtime code I'm using.

    Any help would be greatly appreciated.

    SyslogAppender syslogAppender = new SyslogAppender();
    syslogAppender.setLayout( new PatternLayout("{%d{dd.MM.yyyy}#%d{HH:mm:ss}} {%C.%M} {%c{1}} {%m}%n") );
    LOGGER.removeAllAppenders(); //remove all appenders so we can add only the appender we want next
    LOGGER.addAppender(syslogAppender); //write only to syslog


  2. #2
    Steve11235's Avatar
    Steve11235 is offline Senior Member
    Join Date
    Dec 2008
    Rep Power

Similar Threads

  1. Need help making .jar
    By yoodidoo in forum Eclipse
    Replies: 4
    Last Post: 08-03-2009, 08:57 PM
  2. Replies: 3
    Last Post: 07-15-2009, 06:10 AM
  3. Making the program
    By pheonix in forum Advanced Java
    Replies: 4
    Last Post: 04-18-2009, 06:36 AM
  4. Making a count..
    By Samgetsmoney in forum New To Java
    Replies: 15
    Last Post: 02-18-2009, 02:44 PM
  5. Help log4j SysLogAppender
    By arthik_babu in forum New To Java
    Replies: 0
    Last Post: 11-19-2007, 02:51 PM

Posting Permissions

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