Questions tagged [log-files]

A log file is a file, often in clear text, which is generated by a software process to record some specific details about the workings of this process.

A log file is a file which is generated by a software process to record some specific details (events) about the workings of this process. Most logfiles are plain, human-readable text files, some however are using a binary format to conserve space and need specific treatment for post-processing. (Example: Unix login history in utmp/wtmp format)

A log file can be categorized into several types:

  1. Access log which records information related to the usage of the service provided by this process.
  2. Error log which records error conditions.
  3. Info/Debug log which records more detailed information as compared with other logs.
  4. Transaction log to document a chain of events, this often is required to be immutable to avoid later tampering.
  5. redo logs, containing the complete information to replay a chain of actions, often used where incomplete data transactions would lead to inconsistent data, for example in file systems or databases.

The main two goals of creating and maintaining log files are:

  1. Finding and debugging problems.
  2. Gathering usage information.

Depending on the frequence of events and the level of detail, logfiles may be growing very quickly, and usually require a strategy for managing their growth.

Depending on special reqirements, log-files may go to specialized devices to meet criteria of speed or immutability.

1103 questions
19
votes
6 answers

How can I move /var/log directory

On our production server there is a small drive for the root mount point /, /var/log is taking too much space and I have to manually delete some files. How can I move /var/log/ to let's say /home/log WITHOUT REBOOTING? Here is the thing I thought: $…
Razique
  • 2,276
  • 1
  • 19
  • 23
18
votes
4 answers

How to view mariadb log?

I am using new relic to monitor the performance of my server. Recently I noticed a very strange problem where for every 3 hours, the server will be down for 1 minute. And in the new relic report, during the server down time, there were sudden spike…
dev-jim
  • 313
  • 1
  • 2
  • 8
18
votes
11 answers

Any freeware IIS log analyzer?

It would be nice to use ASP.NET, but PHP is ok too, and should be hosted in IIS6. EDIT: the logs are from our intranet site.
alexandrul
  • 1,435
  • 2
  • 19
  • 25
18
votes
4 answers

What are these files ,can I delete them manually?

[root@jiaoyou mysql]# pwd /var/lib/mysql [root@jiaoyou mysql]# ls -ls 338256 -rw-rw---- 1 mysql mysql 346030080 2010-04-22 08:08 ibdata1 626812 -rw-rw---- 1 mysql mysql 641222072 2010-01-26 07:17 mysql-bin.000008 316892 -rw-rw---- 1 mysql mysql…
apache
  • 3,227
  • 7
  • 27
  • 25
17
votes
8 answers

"Catch-All" access log with Apache Virtual Hosts?

I have many virtual hosts set up on a web server, each one having its own error and access log. The relevant lines of httpd.conf are something like this: ErrorLog /var/log/httpd-error.log LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\"…
pix0r
  • 291
  • 1
  • 2
  • 6
17
votes
3 answers

How to get less to seek faster with large log files?

I am often dealing with incredibly large log files (>3 GB). I've noticed the performance of less is terrible with these files. Often I want to jump do the middle of the file, but when I tell less to jump forward 15 M lines it takes minutes.. The…
UsAaR33
  • 1,096
  • 3
  • 11
  • 20
16
votes
4 answers

How to use find command to delete files matching a pattern?

I'm trying to write a bash command that will delete all files matching a specific pattern - in this case, it's all of the old vmware log files that have built up. I've tried this command: find . -name vmware-*.log | xargs rm However, when I run the…
Dan Monego
  • 285
  • 1
  • 2
  • 7
16
votes
2 answers

Managing CBS.log files on Windows 2008R2?

Whilst auditing disk space on our Windows 2008R2 farm we noticed that some servers had quite large C:\Windows\Logs\CBS\CBS.log files (~1.5GB). I was under the impression that this particular log file would be periodically compressed into…
Kev
  • 7,877
  • 18
  • 81
  • 108
16
votes
2 answers

How can I rotate many log files into a different subdirectory per rotation?

I have a directory with many log files, all of which I would like to rotate daily. For organizational purposes I would like to be able to move the rotated logs into a different directory (or subdirectory) named by date, keeping the last week of…
Dave Forgac
  • 3,546
  • 7
  • 37
  • 48
16
votes
1 answer

manually rotating logfile with rsyslogd

I want to force logfile rotation using logrotate -f /var/log/syslog, but it's only return tones of: error: syslog:1 unknown option 'May' -- ignoring line error: syslog:1 unexpected text I know that on this system rsyslogd is running. How to rotate…
kbec
  • 953
  • 1
  • 9
  • 10
16
votes
4 answers

Logrotate Successful, original file goes back to original size

Has anyone had any issues with logrotate before that causes a log file to get rotated and then go back to the same size it originally was? Here's my findings: Logrotate Script: /var/log/mylogfile.log { rotate 7 daily compress …
drewrockshard
  • 1,763
  • 4
  • 20
  • 27
16
votes
3 answers

logrotate does not compress /var/log/messages

Over time I noticed some logs in /var/log such as auth, kern and messages were getting huge. I made logrotate entries for them: $ cat /etc/logrotate.d/auth.log /var/log/kern.log { rotate 5 daily } $ cat /etc/logrotate.d/kern.log…
Mike Mazur
  • 6,133
  • 2
  • 20
  • 13
14
votes
5 answers

Where are windows 10 defender offline scan logs/results?

I can't find any events or log files, are there such records somewhere or WD reports only if it finds something? Windows 10 pro, drive is encrypted with bitlocker (might affects somehow?)
bdimych
  • 141
  • 1
  • 1
  • 3
14
votes
2 answers

IIS logs show sc-win32-status=64 but only through some networks

I have an ASP.NET application running on a client server (W2k3, IIS6, .NET 2.0). FWIW, this is a Test instance, it hasn't been moved into Production yet. So it is not running under SSL, load balancing, etc. When I access one of the pages on their…
wweicker
  • 505
  • 2
  • 4
  • 13
14
votes
8 answers

Linux monitor logs and email alerts?

I have a server with a faulty power button that likes to reboot itself. Usually there are warning signs, like the acpid log file in /var/log starts spamming garbage for about 10hrs or so. Is there an easy way I can have something monitor the acpid…
Physikal
  • 570
  • 2
  • 9
  • 22
1 2
3
73 74