Sponsored Content
Homework and Emergencies Homework & Coursework Questions Parse a Web Server Access Log Post 302407184 by codyhazelwood on Wednesday 24th of March 2010 07:06:26 PM
Old 03-24-2010
Parse a Web Server Access Log

1. The problem statement, all variables and given/known data:

Write a parser for a web server access log that will provide the statistics outlined below. Remember to format your output in a neat form. You may complete this assignment with one Awk script or a shell script using a combination of Awk scripts.

Obtain the file located at http://users.csc.tntech.edu/~elbrown/access_log.bz2. For full credit, you must not save this data file to disk. You must process the file by reading directly from the url above using bash commands.

Please submit this problem's script(s) and output combined as a separate zip file. (15 points)

Your script should address each of the following items:

1. List the top 10 web sites from which requests came (non-404 status, external addresses looking in).
2. List the top 10 local web pages requested (non-404 status).
3. List the top 10 web browsers used to access the site. It is not necessary to get fancy and parse out all of the browser string. Simply print out the information that is there. Display the percentage of all browser types that each line represents.
4. List the number of 404 errors that were reported in the log.
5. List the number of 500 errors that were reported in the log.
6. Add any other important information that you deem appropriate.


2. Relevant commands, code, scripts, algorithms:

Awk will be used.

3. The attempts at a solution (include all code and scripts):

I don't have a problem at all with the 1 - 6 part. I understand how to use awk. The problem I'm having is how to parse a .bz2 file without downloading and decompressing it. I don't even have an idea how to begin accessing the file without decompressing it.

4. Complete Name of School (University), City (State), Country, Name of Professor, and Course Number (Link to Course):

Tennessee Technological University, Cookeville, TN, USA, Eric Brown, CSC 2500 Unix Laboratory

Note: Without school/professor/course information, you will be banned if you post here! You must complete the entire template (not just parts of it).
 

5 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

Ways to Access Files on Unix Server via Web

Hi all! I'm a web developer with a question. We have a contractor that is working on a project that requires the user to access a ton of files on the clients Unix server. He has plans to built a VB interface for on site windows users to access those files and wants us to develop a web based... (4 Replies)
Discussion started by: Imhotep1963
4 Replies

2. UNIX for Advanced & Expert Users

remote web server access (apache)

Hi, I have web server (apache) installed in server-1 and i want to view the web pages from diferent servers also while the web server is running only in one server ....(all the servers are connected to office LAN) right now all the servers have apache running......and CPU utilzation is at its... (2 Replies)
Discussion started by: aditya.ece1985
2 Replies

3. UNIX for Advanced & Expert Users

WEB Server Log File Analysis using awk/sed/grep

I'm trying to find a way to show large page sizes (page size in K) from multiple web server log files. Essentially I want to show only rows from a file where a specific column is larger than some value. Has anyone ever done this type of log analysis? If so, a snippet of code would be very... (2 Replies)
Discussion started by: mike_cataldo@ad
2 Replies

4. Web Development

Cannot access Apache web server from Wan side, only Lan side.

I have installed WAMPSERVER 2.0 on my windows vista x64 system but still am having issues with getting the webserver to be seen outside my local network. It is working fine within my local network. Been through several setup tutorials so far, no dice still. For testing purposes I have... (1 Reply)
Discussion started by: davidmanvell
1 Replies

5. Proxy Server

How to use Squid on Linux to control certain IP to access Web Server and certain IP cannot access?

Dear all experts here, :) I would like to install a proxy server on Linux server to perform solely to control the access of Web server. In this case, some of my vendor asked me to try Squid and I have installed it onto my Linux server. I would like know how can I set the configuration to... (1 Reply)
Discussion started by: kwliew999
1 Replies
GIT-WEB--BROWSE(1)						    Git Manual							GIT-WEB--BROWSE(1)

NAME
git-web--browse - Git helper script to launch a web browser SYNOPSIS
git web--browse [OPTIONS] URL/FILE ... DESCRIPTION
This script tries, as much as possible, to display the URLs and FILEs that are passed as arguments, as HTML pages in new tabs on an already opened web browser. The following browsers (or commands) are currently supported: o firefox (this is the default under X Window when not using KDE) o iceweasel o seamonkey o iceape o chromium (also supported as chromium-browser) o google-chrome (also supported as chrome) o konqueror (this is the default under KDE, see Note about konqueror below) o opera o w3m (this is the default outside graphical environments) o elinks o links o lynx o dillo o open (this is the default under Mac OS X GUI) o start (this is the default under MinGW) o cygstart (this is the default under Cygwin) o xdg-open Custom commands may also be specified. OPTIONS
-b <browser>, --browser=<browser> Use the specified browser. It must be in the list of supported browsers. -t <browser>, --tool=<browser> Same as above. -c <conf.var>, --config=<conf.var> CONF.VAR is looked up in the Git config files. If it's set, then its value specifies the browser that should be used. CONFIGURATION VARIABLES
CONF.VAR (from -c option) and web.browser The web browser can be specified using a configuration variable passed with the -c (or --config) command line option, or the web.browser configuration variable if the former is not used. browser.<tool>.path You can explicitly provide a full path to your preferred browser by setting the configuration variable browser.<tool>.path. For example, you can configure the absolute path to firefox by setting browser.firefox.path. Otherwise, git web--browse assumes the tool is available in PATH. browser.<tool>.cmd When the browser, specified by options or configuration variables, is not among the supported ones, then the corresponding browser.<tool>.cmd configuration variable will be looked up. If this variable exists then git web--browse will treat the specified tool as a custom command and will use a shell eval to run the command with the URLs passed as arguments. NOTE ABOUT KONQUEROR
When konqueror is specified by a command line option or a configuration variable, we launch kfmclient to try to open the HTML man page on an already opened konqueror in a new tab if possible. For consistency, we also try such a trick if browser.konqueror.path is set to something like A_PATH_TO/konqueror. That means we will try to launch A_PATH_TO/kfmclient instead. If you really want to use konqueror, then you can use something like the following: [web] browser = konq [browser "konq"] cmd = A_PATH_TO/konqueror Note about git-config --global Note that these configuration variables should probably be set using the --global flag, for example like this: $ git config --global web.browser firefox as they are probably more user specific than repository specific. See git-config(1) for more information about this. GIT
Part of the git(1) suite Git 1.8.5.3 01/14/2014 GIT-WEB--BROWSE(1)
All times are GMT -4. The time now is 02:15 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy