• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 544
  • Last Modified:

How do you configure logrotate with syslog-ng?

Hello,

I just recently installed and configured syslog-ng to create and log individual log files for my routers. Although the logging is working fine, I noticed that the log files are growing larger by the day. How do you configure logrotate so that the files are replaced on a weekly basis with empty log files? The log files are located in the directory /var/www/html/syslog. I'm using Fedora Core.

0
Abarros22
Asked:
Abarros22
  • 4
  • 4
2 Solutions
 
fosiul01Commented:
have you logrotate installed ?
check this one
http://dailypackage.fedorabook.com/index.php?/archives/40-Wednesday-Why-Log-rotation.html
if go to
cd /etc/logrotate.d

you will see a file call syslog

check what path it got in their

you  should be able to change from their
0
 
woolmilkporcCommented:
Hi,

here is a nice howto:

http://wiki.egee-see.org/index.php/SyslogNG#Log_File_Rotation

and here is logrotate's manpage:

http://linux.die.net/man/8/logrotate

HTH

wmp


0
 
Abarros22Author Commented:
Hello,

Thanks for the information. I was able to configure log rotation. However, before I close out the question, I would like to know if syslog-ng affects the functionality of the original syslogd. In other words, is syslogd still going to function as if syslog-ng had never been installed? Are all the local or original processes going to be logged normally?
0
Configuration Guide and Best Practices

Read the guide to learn how to orchestrate Data ONTAP, create application-consistent backups and enable fast recovery from NetApp storage snapshots. Version 9.5 also contains performance and scalability enhancements to meet the needs of the largest enterprise environments.

 
fosiul01Commented:
yes, syslogd will work as normal, syslg-ng will just hold log from other linux pc
its just to centralized log thats all for better security and review log files
0
 
woolmilkporcCommented:
syslog-ng is a replacement for syslogd. As long as syslog-ng is up and running, syslogd will not work, which has to do with access to /dev/... files and listening ports.
Once syslog-ng is stopped (and perhaps uninstalled) you can continue using syslogd as you did before.

wmp
0
 
woolmilkporcCommented:
fosiul01, have you ever tried that?
0
 
fosiul01Commented:
ommm sorry if i say anything wrong
but sylog-ng is running on my server

suppose secure log form other pc is storing in /var/log/secure in sylog-ng server

along with normal log

if syslog damon does not work then how its happenning ??

0
 
woolmilkporcCommented:
syslog-ng does normal local processing, too
0
 
fosiul01Commented:
ommmmm
then i will have to check tomorrow,

either i am mixing syslog-ng with syslog server

or
 i am running syslog-ng but i stoped syslog server ...

Again, @author, I am sorry if i give any wrong informaiton about syslog damon and sylog-ng damon...
0

Featured Post

Efficient way to get backups off site to Azure

This user guide provides instructions on how to deploy and configure both a StoneFly Scale Out NAS Enterprise Cloud Drive virtual machine and Veeam Cloud Connect in the Microsoft Azure Cloud.

  • 4
  • 4
Tackle projects and never again get stuck behind a technical roadblock.
Join Now