How to analyze web server logs

Moebuntu

Well-known member
Registered
Joined
Jul 1, 2016
Messages
103
Points
18
I am new to hosting sysadmin and web system analytis, my website is running as well but i feel its having problems with codes or server configs. I want to know how to analyze web server logs to fix problems for my web hosting and web systems. Can anyone share me any tips?
 

Moebuntu

Well-known member
Registered
Joined
Jul 1, 2016
Messages
103
Points
18
I am using Apache web server, I tried to view logs file and found hundreds of lines in each log file.
Do I need to learn web server or web system to analyze and fix problems from web server logs?
 

LJSHost

Well-known member
Hosting Provider
Registered
Joined
Jul 5, 2016
Messages
1,031
Points
63
To analyze web server logs you need to know what your looking for. What problems are you experiencing ?
 

racksandcloud

Well-known member
Registered
Joined
May 18, 2017
Messages
89
Points
0
You can check the apache logs, MySQL logs, installation logs, /var/log/messages or dmesg and etc to analyze the issue of your server but you should be familiar with these logs/system administration to understand the issues from these logs. You may buy a dedicated or VPS with server management plan if you are not much familiar with system administration.
 

24x7CSM

Well-known member
Registered
Joined
Sep 27, 2016
Messages
263
Points
28
The output you get in the logs are not all errors , some are warnings. So make sure you are going through it carefully fixing the things. The apache error logs is not only the place where you should looks for as if you are running PHP website , you need to make sure you have enabled all the required PHP extensions , have compiled them with apache. PHP.ini is where you can configure the additional things.
 

HostechSupport

Active member
Registered
Joined
Jan 19, 2013
Messages
68
Points
8
Mostly, in Linux or UNIX system, logs are created under /var/log directory, you may see very important log files such as apache, auth, mysql, kernel, bootstrap, dmeg, apt and etc.

Application log

The Application log comprises events logged by applications or programs. say for eg. a database program might record a file error in the application log.

Apache: /var/log/apache

Samba: /var/log/samba

Mail: /var/log/

Mysql: /var/log/
 

hostguy

Member
Registered
Joined
Sep 9, 2020
Messages
49
Points
6
You can use below command to check Apache logs:
cat /var/log/apache2/error_log
This command will open complete file with error logs.

But if you want to search for particular user or something then you can add grep in this command like this:
cat /var/log/apache2/error_log | grep "user"
 
Older Threads
Latest Threads
Replies
1
Views
23
Replies
0
Views
175
Replies
1
Views
37
Replies
2
Views
81
Recommended Threads
Similar Threads
Replies
1
Views
23
Replies
0
Views
52
Replies
7
Views
3,135
Replies
0
Views
3,202

Latest postsNew threads

Latest Hosting OffersNew Reviews

Sponsors

Tag Cloud

You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an alternative browser.

Top