Server :: Logrotate For Logs That Change Filenames

Nov 26, 2010

Say that a certain server process generates log files and names them according to the current date; e.g.

server.nov-20.2010.log
server.nov-21.2010.log
server.nov-22.2010.log
server.nov-23.2010.log

i'd like to have logrotate compress the logs that are older than 3 days. Is this possible with logrotate, or do i just schedule a cron job to bzip everything under the folder older than 3 days?

View 1 Replies


ADVERTISEMENT

Software :: Logrotate.conf Settings Global / Apply To What Is In Logrotate.d/

Jan 18, 2011

Is the logrotate.conf settings global/apply to what is in logrotate.d/? I have olddir /var/log/old_logs in logrotate.conf but logrotate is not placing old rsyslogs in /var/log/old_logs for logrotate.d/rsyslog

View 5 Replies View Related

Server :: Ubuntu 6.06 Syslog Crashes After Logrotate?

Aug 23, 2010

I have a postfix mailserver that works fine except for the logrotate.

syslog.conf
mail.* -/var/log/mail.log
logrotate.conf
/var/log/mail.log {

[Code]....

So when cron does the logrotate, there is a new logfile but its empty. After i restart the syslogd it gets back to its normal logging.

What am i missing? All this works with CentOS, why is Ubuntu such a pain...

View 3 Replies View Related

Fedora :: Change Certain Letters In Filenames To Uppercase?

May 22, 2010

I'm working on changing some badly named files, lots of them. I have a little script I use to change uppercase to lowercase:

[Code]....

Bear in mind all these files have appropriate numbers in the front of each filename. I need help to change ONLY the first letter after each underscore to an uppercase letter. I'm sure this can be done but I've done so much searching in forums and with Google/linux until I'm scrambled.

View 2 Replies View Related

Server :: Logrotate For HTTPD Breaks HTTP Sessions

Dec 22, 2010

We started hosting some very large content on our site, and the usage patterns in cacti have revealed that the HTTP sessions through our load-balancers drop off dramatically right at midnight.

The logrotate process runs right at midnight, and issues a reload command through the service tool (CentOS 5.5):
Code:
$ cat /etc/logrotate.d/httpd
/data/websites/logs/*_log /var/log/httpd/*log {
missingok
daily
dateext
compress
rotate 7
sharedscripts
postrotate
/sbin/service httpd reload > /dev/null 2>/dev/null || true
endscript
}

Looking at the init script reveals that the reload section is suppose to trigger a HUP of the httpd process:
Code:
reload() {
echo -n $"Reloading $prog: "
if ! LANG=$HTTPD_LANG $httpd $OPTIONS -t >&/dev/null; then
RETVAL=$?
echo $"not reloading due to configuration syntax error"
failure $"not reloading $httpd due to configuration syntax error"
else
killproc -p ${pidfile} $httpd -HUP
RETVAL=$?
fi
echo
}

In which, Apache should reload it's configuration and start the new logfile without breaking current sessions. However that clearly isn't what is going on. I'm tempted to edit the logrotate script to trigger a HUP directly by cat'ing the PID file directly. Is this normal behavior for Apache when signaled with a HUP?

View 1 Replies View Related

Server :: Logrotate Rotating Daily When Should Rotate Weekly?

Mar 18, 2010

I have an Ubuntu server, and I have a special script on logrotate.d to rotate the samba_audit logs:

/var/log/auditsamba/auditoria.log {
weekly
rotate 12
missingok

[code]....

View 14 Replies View Related

Server :: Tools - Squid Accounts - To Create - Change - Modify Users Of Squid And To View Their Logs

May 23, 2010

My squid server works fine in fedora 11 system . Is there any web like interface for admins to create,change,modify users of squid and to view their logs.

View 1 Replies View Related

Software :: Bash - Rename Filenames With Corresponding Filenames?

Dec 1, 2009

I got a filename called like this:

beach---------20090808-110000.ogg
beach---------20090808-120000.ogg

It's like this:

name----------YYYYMMDD-hhmmss.ogg

Now Im splitting these hourly files into 1 minute files. I get then this output sofar properly:

beach---------20090808-110000_00.mp3
beach---------20090808-110000_01.mp3
beach---------20090808-110000_02.mp3
and so on....

the 00, 01, 02 and up are the minutes it has splitted it. Now I need a script, after it did this, to rename the file names into this:

beach---------20090808-110000.mp3
beach---------20090808-110100.mp3
beach---------20090808-110200.mp3
beach---------20090808-110300.mp3

View 4 Replies View Related

Ubuntu :: Bulk Change Filenames To "cat Names-list.txt"

Mar 29, 2010

I'm looking for something like:

Code: for x in *.mkv; do rename "$x" "${line_from_filenames.txt}.mkv"; done; ls -1 ~/kids/movies/*.mkv
00.20080903fckdlowp.mkv
01.20080911fckdl2fd.mkv
02.20080925fckdlgrs.mkv
03.20081026fckdlbh7.mkv
04.20081206fckdli90.mkv
05.20090214fckdmkni.mkv
[Code]....

View 7 Replies View Related

Debian :: Aptitude Doesn't Find Change Logs

May 1, 2014

For some time now I've been unable to see changelogs for packages to be upgraded in Wheezy,even trying with different mirrors in sources.list all I'm getting is this:

Code: Select allaptitude changelog iceweasel
Err Changelog of iceweasel                                                                                                     
E: Changelog download failed: 404  Not Found [IP: 185.31.16.185 80]
Err Changelog of iceweasel                                                                                                     
E: Changelog download failed: 404  Not Found [IP: 185.31.16.185 80]
E: Couldn't find a changelog for iceweasel

[Code] ....

Is there maybe some specific reasons why I can't get changelogs before applying the updates? I know I can review them afterwards,it's just that I would find convenient to have a look before updating.

View 14 Replies View Related

Server :: Apache Incorrectly Handling Requests For Numeric PHP Filenames?

Nov 14, 2009

I'm working on a thorny mod_rewrite problem. I have a mac connected to my LAN running MAMP (Mac/Apache/MySQL/PHP). I request a non-existent file:

Code:
http://192.168.1.2:8888/careers/db/1.html
I see this in the mod_rewrite log file:

Code:
192.168.1.102 - - [14/Nov/2009:13:46:07 --0800] [192.168.1.2/sid#807df8][rid#8ec850/initial] (2) init rewrite engine with requested uri /careers/db/1.html
192.168.1.102 - - [14/Nov/2009:13:46:07 --0800] [192.168.1.2/sid#807df8][rid#8ec850/initial] (1) pass through /careers/db/1.html
Note that the requested uri is /careers/db/1.html

If I change just the file extension on my request to PHP like so:

Code: [URL]

Then the request uri is totally different now. Here's the rewrite log:

Code:
192.168.1.102 - - [14/Nov/2009:13:47:23 --0800] [192.168.1.2/sid#807df8][rid#8fc850/initial] (2) init rewrite engine with requested uri /Applications/MAMP/htdocs/careers/
192.168.1.102 - - [14/Nov/2009:13:47:23 --0800] [192.168.1.2/sid#807df8][rid#8fc850/initial] (1) pass through /Applications/MAMP/htdocs/careers/
Note that the requested uri now has a full path which does not include the actual filename, /Applications/MAMP/htdocs/careers/

What the heck? More info. If I request [URL], I can actually access p1.php. The requested uri is /careers/db/p1.php. The problem appears to be because the filename starts with a number. I can also request [URL] and get thru to 1.php with requested uri /careers/db//1.php. Does mod_rewrite think /1 refers to a backreference or something? Why can apache handle the html file request properly and not the php file request?

View 8 Replies View Related

Server :: Monitor Server Snmp Read From Logs Parsed Possible?

Jul 21, 2009

I would like to monitor a RedHat via snmp. I would like to make available data via snmp. The data that I would like to graph are only present in logs file. Is it possible to parse data from applicative logs and have them available for my cacti server via snmp? I already monitor CPU, mem, and others with cacti using the standard MIB.What would be the logical step I would need to achieve that?

View 1 Replies View Related

Server :: How To Analysis IBM DSA Logs

Oct 24, 2010

I Have RHEL4 running on IBM X3550 server, we request IBM support regarding issues with this server, they will request for IBM DSA logs. The logs are quite extensive and cover almost all server config & can identify hardware issues with drivers...etc. I want to know if there is a way to analysis those logs offline without sending them to IBM support?

View 3 Replies View Related

General :: Logrotate Httpd Log Files ?

Jan 11, 2010

I need to logrotate logs in directories in /var/log/httpd/.

There are 4 directories in /var/log/httpd/... these directories are /var/log/httpd/access/ /var/log/httpd/debug/ /var/log/httpd/error/ /var/log/httpd/required/

Each of the access, required, error and debug directories have around 20 to 30 access log files of different locations for example:mumbai-access.log, pune-access.log etc..same is the case for 'error' dir 'required' dir and 'debug' dir in /var/log/httpd/

I need to clean up the logfiles in all the 4 directories access, error, debug and required...

I have made a custom logrotate file as follows:

Is the above config correct?

Am I missing something? Will this logrotate the files in /var/log/httpd/access, /var/log/httpd/error, /var/log/httpd/required and /var/log/httpd/error ?

Do i need to include following line in postrotate " /bin/kill -HUP `cat /var/run/httpd.pid 2>/dev/null` 2> /dev/null || true" ?

View 3 Replies View Related

Software :: Logrotate Download Site

Jul 10, 2009

I am looking for a good site to download logrotate for RHEL.

View 1 Replies View Related

Software :: Logrotate Duplicate Log Entry

Jan 1, 2011

having a problem with logrotate. it's complaing about a duplicate log entry but there isn't a duplicate log entry that i can see.

View 4 Replies View Related

CentOS 5 :: Segmentation Faults With Yum, Logrotate, And Others?

Dec 4, 2010

Recently I noticed that on my Centos 5.4 system, yum no longer works and is giving segmentation faults. I can run "yum --help" and it works, but if I try to run something like "yum upgrade php" it will fault. I also noticed that other things are seg faulting as well, like /usr/sbin/logrotate and /usr/bin/certwatch.

I am guessing there is some sort of common library that needs fixing, but I have no idea what. I've read other posts about the yum segmentation fault and have tried various steps provided but so far no luck in getting it to work again. It used to work, and I rarely change this system so I'm not sure what could have caused it.

View 2 Replies View Related

CentOS 5 :: Logrotate And Size Of Log Files

May 18, 2011

I have CentOS 5. From sometime logrotate is not working and maillog for example is very big. It is the same for all logfiles. I run "logrotate -d -f /etc/logrotate.conf" but nothing happened. Cron seams to work as I see it with ps -ef |grep cron

View 2 Replies View Related

General :: Q2 Patching Logs Of Particular Server ?

Jun 10, 2011

How to get the Q2 patching logs of particular server (Linux 2.6.9-100.EL)

View 1 Replies View Related

Hardware :: How To Find Logs In Hp-ux Server

Jan 11, 2010

how to find logs in hp-ux server why it get unexpected shut..down is any hardware failure or or its been hard boot

View 3 Replies View Related

Server :: Define How Old Logs Should Rsyslog Keep

Aug 25, 2010

I was wondering how could I specify for how long the logs will be kept. Rsyslog doesn't have such an option (at least I didn't find it).Do I have to use logrotate for this, or is there some other option?

View 1 Replies View Related

Server :: How To Check Logs For Previous Day

Oct 5, 2010

how to check maillogs for previous days. wht is command to check log for yesturday in sendmail8.14 .fedora os i know /var/log/maillog.this gives o/p for today but wht abut yesturday.?

View 10 Replies View Related

Server :: Security Logs With Message ID?

Mar 9, 2011

Iam looking security specific event ID on Linux .hear are thousnds of event ID in Microsoft Windows/XP and VISTA etc. Similar way looking for Linux,unix ,Solaries,AIX etc event ID. I would to correlate and implement with Arcsight.

View 2 Replies View Related

Server :: Unable To See All The Logs Forwarded To Box?

Apr 19, 2011

We are forwarding logs (perl script executed logs) to one Red Hat Linux box. We have to get 97 logs for each time the script runs. But we see inconsistent number of logs coming to Linux box. Like one time we got 56, other time 3 , other time 43.. like this.. We are sure that 97 logs are being forwarded. Checked the Rsyslog.config filer any filters and couldn't see any filter dropping them. When we run the tcpdump, we can see 97 connections, but logs are not there in specified location.

View 1 Replies View Related

Server :: How To Setup Logs In Vsftpd

Oct 20, 2010

how to setup logs in Vsftpd? I have default configuration in CentOS but its not log`ing

View 1 Replies View Related

General :: Logrotate - Purpose Of Rotate And Postrotate?

Jul 10, 2010

I have been trying out in learning with logrotate command and logrotate configuration file )logrotate.conf custom logfile for an process is 'test.log'

Code:

#cat /etc/logrotate.d/test
/var/log/test.log {
rotate 4

[code]....

whenever the log file (test.log) exceeds 100M a new file will be created with the file name as test.'date'.'gz'(new file is created with a current date and in a compressed format of gz) and also with permission mentioned above). I really dont know what is the role of rotate( will this be carried on only for next 4times i mean upto 400MB; (4times*file reaches 100MB)? and also what could be the purpose of postrotate?

View 5 Replies View Related

Ubuntu Servers :: How IPAddress Can Hit Server Yet Not Appear In ANY Logs

Oct 31, 2010

Since Port 80 and 443 are the only ports I have open, how is it that an IPAddress can hit my server yet not appear in ANY logs ?

View 9 Replies View Related

General :: Collect All Logs Of Unix Server?

Dec 26, 2010

I am installing RHEL 5.5 to be a syslog server to collects logs from servers (HP-UX, Linux, Windows and Cisco Network Devices). and i can now collect logs from my windows PC on syslog linux server by using Datagram SyslogAgent software. can collect logs from HP-UX 11.23 server. and i configuring the Unix server as in the steps below:

1. Log in as root

2. Go to /etc/syslog.conf

3. Add a line: *.*<tab>@<Sentinel Server IP Address>

*.* @10.15.1.5

4. Save and Close

# netstat -na | grep 514

tcp 0 0 *.514 *.* LISTEN
udp 0 0 *.514 *.*

[code]....

View 1 Replies View Related

Server :: Access Logs In Squid Proxy?

Feb 24, 2011

i am monitoring access log messages in squid proxy server,can it possible to get date,time,day in access logs is it possible

View 2 Replies View Related

Server :: Configuring Syslog And Exporting Of Logs?

Jan 17, 2011

configure syslog server on ubuntu now i want to export logs of windows and ubuntu desktop to the syslog server

View 6 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved