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
0
votes
0 answers

Apache access log not logging content-length for data served via PHP

I have a php script that handles files downloads, it sends content-length header properly and the browsers receive it. But in the Apache access log they show up as "-". In the past this used to work, the bytes showed up on the log, but this is no…
Michael Rogers
  • 60
  • 1
  • 3
  • 16
0
votes
1 answer

Meaning of Log File (DDOS)

We are currently facing attacks (probably DDOS) on our server. The incoming network traffic goes from an average of 20Mbps to 1Gbps in just 2-3 minutes. The lines in our log files usually look like: 101.101.101.101 - - [23/Nov/2020:01:01:01 +0200]…
arety_
  • 103
  • 2
0
votes
1 answer

Are firewall logs filled with incoming SSDP requests typical for networks with a Windows 7 box?

While reviewing firewall logs that were sent to me from a Windows 7 box (the box is not a server) on a tiny network, I saw thousands of incoming SSDP UDP entries. The SSDP entries were nearly constant, occurring every 3 seconds (approx 1200 log…
0
votes
0 answers

How to restore the error.log functionality in Apache, bitnami Wappstack?

I am using the Bitnami Wappstack 7.4.10 in windows, with PHP 7.4 and Apache 2.4.46 . By accident I made a script that had an infinite loop that also produced an error in every iteration, so the log file grew to be very large, many gigabytes long. I…
algo
  • 1
0
votes
1 answer

Copying Content from a file to another when a new line is added using poweshell script

I have a file named server1.txt and one more file named server1_copy.txt. In server1.txt, all logs will be added from the application. So whenever a new line is added in the server1.txt, we need to copy that and paste it in the server1_copy.txt. We…
saffron
  • 143
  • 1
  • 3
  • 12
0
votes
1 answer

How do I know who pings my server and keep a log of it?

I believe it is a very newbie question and I am one indeed. On AWS instance, how do I know who pings my server and if is possible to keep a log of it? I added the example output from the answer by @menderes. I hope it helps other newbies like myself…
0
votes
2 answers

I found a Ukranian spammer and have the exact query, IP and access time. What next?

Before I turned on comment moderation, these guys would leave comments meant to steal my Google juice (by getting an inbound link). I can still see them visit... the question is what should I do next? Is there any way to know whether an entire ISP…
reechard
0
votes
1 answer

How to detect PHP's fsockopen on your server logs?

As stated in the Title. How can I detect an incoming connection from PHP's fsockopen method in my web server logs? Which log file records this activity if it gets recorded at all. Server: Ubuntu 16.04 upto 20.04 I've tried Nginx access.logs, but I…
droplet
  • 113
  • 5
0
votes
1 answer

"Snatching & preserving" versions of a file which gets overwritten repeatedly

On a system I'm working on, there are several processes which occasionally write a certain file (we can think about it as a sort of a log, although it's not quite that). Unfortunately, they all write to the same output file, i.e. they overwrite it;…
einpoklum
  • 1,652
  • 3
  • 21
  • 31
0
votes
1 answer

Exiting Virt-top shows error message in server logs

I see message in /var/log/messages after quitting virt-top command : libvirtd: 2020-07-11 12:36:22.206+0000: 3462: error :virNetSocketReadWire:1806 : End of file while reading data: Input/output error Is it a thing to worry ?
Jevin Gala
  • 59
  • 9
0
votes
1 answer

MariaDB 10.4.13 on Fedora 31

Learning MariaDB on Fedora 31. Installed successfully, able to connect; however, cannot seem to get the error log global variables to register. Steps taken: Created maria.log file in /var/log/ Added [mysqlid] log-error = /var/log/maria.log to…
Ami
  • 1
  • 1
0
votes
0 answers

getting all files in a directory via SFTP with a variable appended before file names

I am downloading all files in a directory via SFTP using below syntax: sshpass -p 'mypass' sftp name@$IP:/var/log/* With above one-liner, I'm able to download all files from /var/log But I want the $IP to be appended with each file name being…
Ibraheem
  • 23
  • 1
  • 6
0
votes
1 answer

graphical logfile viewer for fail2ban?

is there a GUI or other nicer way to study fail2ban logs other than command line? my Ubuntu 18.04.4 is behind a router with a range of ports forwarded, including 22 for ssh, so UFW and fail2ban are pretty important. Collapsing repeated entries and…
Marc Compere
  • 461
  • 4
  • 3
0
votes
1 answer

Flushing / Erase PHP Error log on Windows IIS

I have an IIS server that I'm working on. There's a file at C:\Windows\Temp\php-errors.log that I'm using to debug some 500 errors. After abusing the usage a bit (wrote out a bunch of debug output to the file) the file is absurdly long. When I use…
Josh K
  • 454
  • 1
  • 6
  • 18
0
votes
0 answers

Postfix not printing all the status=sent logs in /var/log/maillog?

We have configured a postfix mail server, it takes email IDs from a CSV file, which has 13,500 recipients. The email is sent to all the recipients at a time, but in /var/log/maillog we only get around 5500-7500 entries of delivery status status=…
TPS
  • 55
  • 1
  • 1
  • 8