Index of /servers

[ICO]NameLast modifiedSizeDescription

[PARENTDIR]Parent Directory  -  
[TXT]CHANGES.txt2019-10-19 14:34 132  
[TXT]README.html2019-10-19 14:34 7.3K 
[TXT]README.txt2019-10-19 14:34 5.5K 
[DIR]cache/2019-10-19 14:34 -  
[DIR]css/2019-10-19 14:34 -  
[IMG]favicon.ico2019-10-19 14:34 894  
[DIR]images_q3mon/2019-10-19 14:34 -  
[TXT]index.html2019-10-19 14:34 443  
[DIR]local_cache/2019-10-19 14:34 -  
[TXT]q3mon-browser.pl2019-10-19 14:34 43K 
[TXT]q3mon-config.pl2021-03-24 15:08 7.6K 
[TXT]q3mon-nm.pl2019-10-19 14:34 1.7K 
[TXT]q3mon-spy.pl2019-10-19 14:34 25K 
[DIR]q3mon_includes/2019-10-19 14:34 -  
[TXT]strace.txt2019-10-19 14:34 168K 

Q4Mon - Installation and Instructions

Q3mon - QUAKE 3 BROWSER / MONITOR

The $0.11 guide.


Q3mon is a port of Q4mon, which was, in turn, derived from the late q3mon.pl and Qsmon. Q4mon began as a simple q4 monitor but had since developed into a powerful game browser and search engine. Since quake 3 is still alive n kickin I figured it wouldn't be a waste of time to port Q4mon to support quake 3 queries. It uses qstat to query quake servers and then formats the results for your web server. My html and perl skills are somewhat questionable, so you may have to poke around a little until it's configured to your liking.

Q3mon now has a home and is available for anyone who wants to use it: http://www.qxmon.net/

Enjoy!
slackX (http://www.dev1ance.net)


 

REQUIREMENTS:

- A web server which allows .cgi/.pl execution
- qstat v2.11 for q3mon version 2.4a or later
- qstat v2.09 - v2.10 for any other older version
http://www.qstat.org/ or CVS at http://sourceforge.net/projects/qstat/

INSTALLATION:

- Extract q3mon-xxx.tar.gz
- cd into to the extracted html directory. Move the entire q3mon directory somewhere accessible to your web server and its visitors.
- Allow cgi or pl execution for this directory in your web server's config. Apache users: You may use an 'Options ExecCGI' or alternatively 'AddHandler cgi-script .pl' (not as secure).
- Change q3mon-browser.pl and q3mon-spy.pl's permissions so that it may be executed by the web server. Apply changes for the images_q3mon, css, q3mon_includes files/directories as well so that they are readable.

(Optional)
Time::HiRes
- For 'server listing time' to be displayed in microseconds, you'll need to install the Time::HiRes perl module and enable $use_hires in q3mon-config.pl. Time::HiRes can be downloaded from cpan: http://search.cpan.org/~jhi/Time-HiRes-1.82/HiRes.pm
Geo::IP
- Searching / sorting by country, or displaying a server's country flag requires that you have the Geo::IP Perl module installed. If you want to enable this feature in q3mon then you must enable $use_geoip in q3mon-config.pl.

CONFIGURATION:

q3mon-config.pl:

- Follow the instructions documented inside the script.

q3mon-browser.pl:

- Edit the shebang (#!/usr/bin/perl) so that it points to your perl executable (if necessary).

q3mon-spy.pl:

- Edit the shebang (#!/usr/bin/perl) so that it points to your perl executable (if necessary)

update_cachefile.pl:

- See 'Caching the Master Server' below


Caching the Master Server

Caching the master server is a very good idea and should certainly be enabled if you have access to crontab or some sort of task scheduler on your web server. Basically what this will do is store all known q3 servers and their info (from monster.idsoftware.com) to a file on your host's hard drive. So instead of waiting 30+ seconds to query the q3master every time you push the 'get new list' button, q3mon will already have all the info available and can process the results immediately. The only downside is that the server lists will not be real-time, they can only be as new as the time it takes between updating the cache file. Which leads us to...

Enabling Local Cache:
- cd into the local_cache directory which was originally extracted. Move the included q3mon directory somewhere on your hard drive. ie: /usr/local/q3mon or c:\q3mon.
- Edit update_cachefile.pl found in the q3mon/bin directory and change the first 'require' line to point to your q3mon-config.pl. This must be an absolute path.
- Now edit the $browser_cache value found in the q3mon-config.pl which you probably have moved to your web earlier. This will be the filename (not directory) that update_cachefile.pl will create, and the file which q3mon-browser.pl will read.
- Set your task scheduler to execute update_cachefile.pl. I personally recommend 10 minutes intervals because qstat must query the master server multiple times for each point release; this may suck up your bandwidth and cause some lag depending on your connection speed.

Linux users should edit the perl header (#!/usr/bin/bash) appropriately, especially if you don't execute the script with 'perl /somepath/update_cachefile.pl'

Crontab example (5 minute updates):
*/5 * * * * /usr/bin/perl /usr/local/q3mon/bin/update_cachefile.pl > /dev/null 2>&1

Disabling Local Cache:
- Edit q3mon-config.pl and set the $browser_cache value to ' '. Ex: our $browser_cache = ' ';
- Delete update_cachefile.pl and the cache folder.



USAGE:

Q3mon is actually 2 tools in 1. Simply delete q3mon-browser.pl if you don't need the server browser. When q3mon-browser.pl is missing, q3mon-spy will no longer display the "- go to server browser -" link. q3mon-spy works just fine independently.

- Pointing your browser to http://yoursite/yourq3monPath/q3mon-spy.pl will monitor each server listed in $quake3servers.
- Pointing your browser to http://yoursite/yourq3monPath/q3mon-browser.pl will bring you to the server browser page.
- If $MaxGets is enabled you may also use q3mon-spy to display custom servers. Separate each by commas.

Examples:
http://yoursite/yourq3monPath/q3mon-spy.pl?70.85.224.178:28004
http://yoursite/yourq3monPath/q3mon-spy.pl?70.85.224.178:28004,70.86.90.109:28004

Map Images:
Level shots can easily be added. Simply save a custom map's levelshot as a jpeg (.jpg not .jpeg) in your images_q3mon/maps/ directory. The filename must match that of the map name. You may want to do this as new maps are released.


That should be about it. Feel free to poke around with the code, never stopped me :P All I ask is that you do not remove or edit the footer credits.