
17th December 2009, 20:13
|
|
Junior Member
|
|
Join Date: Nov 2009
Posts: 14
Thanks: 5
Thanked 0 Times in 0 Posts
|
|
Help with ispconfig 3 perfect ubuntu and urchin
I am trying to set up urchin profiles for the sites I have hosted with my ispconfig server. The main thing I need to do is change log settings.
This line was added to apache2/apche2.conf file:
LogFormat "%v 135594252 t \"r\" >s b \"{Referer}i\" \"{User-Agent}i\" \"{Cookie}i\"" special
but I can't find the vhost info.
From the urchin docs:
Examine the <VirtualHost> entry you wish to enable this logging for.
Insert a # in front of any existing TransferLog or CustomLog entries to deactivate it/them, and insert the following (editing the pathname appropriately for your environment):
CustomLog /www/serverlogs/www.urchin.com_cookie_log special
My question is where can I find the site specific logs?
What file has the log config for the individual sites.
I am sorry if this is basic. I am still new to the linux world.
FYI Urchin is installed on a win2k3 machine.
Thanks for reading
Dave
Last edited by dxh; 17th December 2009 at 20:18.
|

21st December 2009, 21:16
|
|
Junior Member
|
|
Join Date: Nov 2009
Posts: 14
Thanks: 5
Thanked 0 Times in 0 Posts
|
|
Does anyone have any experience setting up urchin profiles for sites running under ispconfig3? I really just need to customize log format and location for all the vhosts (sites) that are running on my ispconfig machine. Here is what google says:
Quote:
Procedure
Configuring Apache or Microsoft IIS to properly log for Urchin
Apache:
Note: Apache uses an NCSA-type log format. By default, Apache generally logs in "common" log format.
For optimal reporting, Urchin requires the "combined" log format with cookies enabled.
Decide if you are going to use cookies and the Urchin Tracking Module (UTM),
or IP-based visitor tracking. UTM-based tracking is the only way to get true unique visitor reporting.
Use "vi" or other text editor to open your httpd.conf file.
Locate the LogFormat entry or entries.
Comment out the existing LogFormat (if any) by inserting a # in front of any lines
that do not have them already. This deactivates those lines.
Insert one of these lines, depending on whether you wish to use the Urchin Traffic Monitor (UTM)
or not. Be sure that the line is entered into your configuration file as a single line, without carriage returns:
Non-UTM (IP or IP+UserAgent tracking)
LogFormat "%l 135594252 t \"r\" >s b \"{Referer}i\" \"{User-Agent}i\"" special
Urchin Traffic Monitor (UTM):
LogFormat "%v 135594252 t \"r\" >s b \"{Referer}i\" \"{User-Agent}i\" \"{Cookie}i\"" special
Examine the <VirtualHost> entry you wish to enable this logging for. Insert a # in
front of any existing TransferLog or CustomLog entries to deactivate it/them,
and insert the following (editing the pathname appropriately for your environment):
CustomLog /www/serverlogs/www.urchin.com_cookie_log special
Note the "special" text at the end of the line. This is the name of this particular CustomLog,
as specified in the LogFormat entry above. You can name your log format anything you
like; "special" is a common choice for non-standard formats.
Write/quit the edit of httpd.conf.
IMPORTANT: run this program to check your syntax:
apachectl configtest
You should get syntax ok. If not, check the httpd.conf file and fix any errors.
Restart Apache. The preferred method is with this script (included with Apache):
apachectl restart
Check the logging. Open a browser and hit the site in question a few times. Examine the log file
(as specified in #6 above.) You should see a several hits being written to the log. For standard
"combined" log format, a log line will look similar to this:
64.40.51.27 www.urchin.com - [28/Aug/2002:15:11:01 -0700] "GET /images/urchin_header_logo.gif HTTP/1.1" 200 3017 "http://www.urchin.com/" "Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.0)"
If you have configured the UTM on the site, a log line will look similar to this
(note the additional cookie field with the embedded UTM information):
64.40.51.27 www.urchin.com - [28/Aug/2002:15:11:01 - 0700] "GET /images/urchin_header_logo.gif HTTP/1.1" 200 3017 "http://www.urchin.com/" "Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.0)" "__utm1= 459278579.1030573053; __utm2=1030573053; __utm3=1030573053"
|
|

22nd December 2009, 15:47
|
|
Super Moderator
|
|
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 41,665
Thanks: 1,896
Thanked 2,592 Times in 2,443 Posts
|
|
I've never worked with Urchin...
|

22nd December 2009, 22:54
|
|
Junior Member
|
|
Join Date: Dec 2009
Posts: 4
Thanks: 0
Thanked 3 Times in 3 Posts
|
|
dxh
Here is what I done to get this working:
I edit /etc/apache2/apache2.conf
And add this line:
LogFormat "%h %v %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\" \"%{Cookie}i\"" urchin
Above:
# Include the virtual host configurations:
So the /etc/apache2/apache2.conf looks like this:
LogFormat "%h %v %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\" \"%{Cookie}i\"" urchin
# Include the virtual host configurations:
Include /etc/apache2/sites-enabled/
Next I go to the ISPConfig 3 panel and from tab sites i chose with site i want to edit:
I chose Options tab
And add this in the text box Apache directives:
CustomLog /var/log/ispconfig/httpd/domain.com/urchin.log urchin
And then hit Save button.
Now my log in the urchin format is /var/log/ispconfig/httpd/domain.com/urchin.log
Then
chmod 755 /var/log/ispconfig/httpd/bnight.com/
So the urchin daemon can read the log.
That`s it.
I hope that this will work for you.
Last edited by bnight; 22nd December 2009 at 23:10.
|
|
The Following User Says Thank You to bnight For This Useful Post:
|
dxh (22nd December 2009)
|

22nd December 2009, 23:19
|
|
Junior Member
|
|
Join Date: Nov 2009
Posts: 14
Thanks: 5
Thanked 0 Times in 0 Posts
|
|
You are my personal savior this holiday season
This worked like a charm.
Last edited by dxh; 23rd December 2009 at 00:27.
|

23rd December 2009, 00:54
|
|
Junior Member
|
|
Join Date: Nov 2009
Posts: 14
Thanks: 5
Thanked 0 Times in 0 Posts
|
|
darn, I was adding an apache directive to another site in ispconfig and I made a typo. Hitting save seemed to kill apache and now I get a fail when trying to restart it.
What did I do? or better
Is there a way to fix it.
Thanks
|

23rd December 2009, 01:12
|
|
Junior Member
|
|
Join Date: Nov 2009
Posts: 14
Thanks: 5
Thanked 0 Times in 0 Posts
|
|
For now I reverted to a snapshot. Not sure what I did.
|

23rd December 2009, 09:51
|
|
Junior Member
|
|
Join Date: Dec 2009
Posts: 4
Thanks: 0
Thanked 3 Times in 3 Posts
|
|
OK so here is what you can do to fix this one:
First remove the lines from ISPConfig 3 options and hit save.
Then if the apache2 don`t start
Edit: /etc/apache2/sites-available/domain.com.vhost
And remove the lines that you add with the typo error.
Then restart apache.
/etc/init.d/apache2 restart
And this is it.
|
|
The Following User Says Thank You to bnight For This Useful Post:
|
dxh (23rd December 2009)
|

23rd December 2009, 18:43
|
|
Junior Member
|
|
Join Date: Nov 2009
Posts: 14
Thanks: 5
Thanked 0 Times in 0 Posts
|
|
Thanks for all your help. I am working and urchin profiles are running.
Just out of curiosity: what log settings do you use for the apache logs in urchin?
I use w3c for my IIS sites, and for now I am using auto for apache sites. Not sure if there is a better choice.
Either way, thank you for all your help in getting this working. Places like this make moving to open source a reality for the folks like me
|

23rd December 2009, 18:47
|
|
Junior Member
|
|
Join Date: Dec 2009
Posts: 4
Thanks: 0
Thanked 3 Times in 3 Posts
|
|
Dave i don`t use Urchin just setup one on some test environment to see how it works and help you. I use auto for the logs from apache and it works like a charm.
Have a nice christmas,
Hristofor
|
|
The Following User Says Thank You to bnight For This Useful Post:
|
dxh (23rd December 2009)
|
| Thread Tools |
|
|
| Display Modes |
Linear Mode
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
All times are GMT +2. The time now is 08:36.
|
|
Recent comments
1 day 6 hours ago
1 day 11 hours ago
1 day 12 hours ago
1 day 13 hours ago
1 day 15 hours ago
1 day 19 hours ago
1 day 20 hours ago
1 day 22 hours ago
2 days 11 hours ago
2 days 13 hours ago