Solved

How to extract concurrent users checking access_log file

Posted on 2004-08-05
8
332 Views
Last Modified: 2012-06-27
I was wondering, how can I  find out how many concurrent users are accesing my webserver?
I've been checking around some log analyzers, but even the better ones dont give me thi stats. Any advice?
Thanks.
0
Comment
Question by:gmartelli
  • 4
  • 4
8 Comments
 
LVL 51

Expert Comment

by:ahoffmann
ID: 11729644
> .. how many concurrent users ..
how do you define a "user"?
i.g. this is impossible, or in paricular: there is no 99.999% reliable method to do it.
0
 

Author Comment

by:gmartelli
ID: 11729664
Ok, how many Different IP addresses would do :).
Lets say, which is the top distincts IPs in a 1 minute period.
The point is, I need to figure out a concurrence, ANY measure of concurrence will help...and I only have the access log file to do it.
0
 
LVL 51

Expert Comment

by:ahoffmann
ID: 11729865
awk '($5~/GET$/){print $3" "$4}' /var/log/httpd/access_log | awk -F: '($1=="16"&&$2=="15"){print}'

# replace 16 by your hour, and 15 by your minute
# to be improved in many ways (and adapted to you logfile format
0
Migrating Your Company's PCs

To keep pace with competitors, businesses must keep employees productive, and that means providing them with the latest technology. This document provides the tips and tricks you need to help you migrate an outdated PC fleet to new desktops, laptops, and tablets.

 

Author Comment

by:gmartelli
ID: 11729892
Hum, how about in ANY minute? I mean, I want to find the top one, if I knew it, It would be quite easy to find out the total count of users in it :)
0
 
LVL 51

Accepted Solution

by:
ahoffmann earned 500 total points
ID: 11730205
what is "ANY" minute? 1 or 17 or 42 or ..
or do you mean somthing like:
 awk '($5~/GET$/){print $3" :"$4}' /var/log/httpd/access_log | awk -F: '{print $1":"$2" "$NF}'|sort -u
0
 

Author Comment

by:gmartelli
ID: 11730221
You get the points, I realized  getting into the realm of analytical SQL (which is what I'm checking now). I meant "the most user accesses in any given minute", meaning I dont know which minute i'm checking, its like a window aggregate (yah, deep magic but seems like Oracle will make things a bit easier for me :)


Thanks
0
 
LVL 51

Expert Comment

by:ahoffmann
ID: 11730451
Oracle? hmm, sounds like breaking a fly on the wheel ;-)
Anyway, thanks for grading, hope it helps you anyway
KISS - keep it stupid simple
0
 

Author Comment

by:gmartelli
ID: 11730603
The problem is not the answer, but the question :)
Thanks for the help
0

Featured Post

Use Case: Protecting a Hybrid Cloud Infrastructure

Microsoft Azure is rapidly becoming the norm in dynamic IT environments. This document describes the challenges that organizations face when protecting data in a hybrid cloud IT environment and presents a use case to demonstrate how Acronis Backup protects all data.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
setting up tomcat for external access 4 75
Enabling compression in WARP Framework template 5 92
Best IDE for PHP starters 11 134
More Than One Website On Same DMZ Server 3 85
If you've heard about htaccess and it sounds like it does what you want, but you're not sure how it works... well, you're in the right place. Read on. Some Basics #1. It's a file and its filename is .htaccess (yes, with a dot in the front). #…
In Solr 4.0 it is possible to atomically (or partially) update individual fields in a document. This article will show the operations possible for atomic updating as well as setting up your Solr instance to be able to perform the actions. One major …
Established in 1997, Technology Architects has become one of the most reputable technology solutions companies in the country. TA have been providing businesses with cost effective state-of-the-art solutions and unparalleled service that is designed…
In an interesting question (https://www.experts-exchange.com/questions/29008360/) here at Experts Exchange, a member asked how to split a single image into multiple images. The primary usage for this is to place many photographs on a flatbed scanner…

839 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question