From ChekMate Security Group
1] Stats.cfg config options
STATSERV_NICK -Sets the nickname of the StatServ bot. If not specified, defaults to statserv
eg: STATSERV_NICK stats -Set statserv bot to appear as 'stats'
STATSERV_USER -Sets the username portion of the statserv bot
eg: STATSERV_USER stats -Sets the statserv bot to have the username/ident portion set to stats
STATSERV_HOST -Sets the hostname that statserv appears to come from
eg: STATSERV_HOST stats.microsoft.com -sets the statserv bot to apear to connect from stats.microsoft.com
LAG_NOTICE -Specifies if a server is lagged out longer than this period, to broadcast a message
eg: LAG_NOTICE 60 -Any server that doesn't respond to a ping within 60 seconds gets broadcast out that its lagging
HTML_STATS -Enable StatServ to output a HTML file to the filesystem with some statistics
eg HTML_STATS -If define, enables this option
HTML_PATH -Where to write the HTML file to. Include path and filename. Make sure you have permissions to write to this directory/file
eg: HTML_PATH /var/www/html/stats/index.html -Write the statistics file to this location.
2] Available Commands
SERVER -Display a list of all servers that statserv has ever known about, or individual server information
MAP -Display a Network map of all connect servers
NETSTATS -Display Statistics about the network
DAILY -Display Statistics about the network for Today only
TLD -Find out what country a TLD represents
TLDMAP -Display a breakdown of users and what countries they come from
OPERLIST -Display a list of operators
BOTLIST -Display a list of online bots (only if your IRCD supports a BOT flag)
VERSION -Display the version of the currently running statserv
Commands available to Administrators:
FORCEHTML -Force a update of the HTML file
RESET -Delete all stats, and start from scratch
STATS -Delete/copy server information
3] Server Command
/msg statserv server
Returns:
=StatServ= Error, the Syntax is Incorrect. Please Specify a Server
=StatServ= Server Listing:
=StatServ= Server: stats.dynam.ac (*)
=StatServ= Server: services.dynam.ac (*)
=StatServ= Server: Server.IRC.net (*)
=StatServ= Server: blha.com (*)
=StatServ= Server: Server2.IRC.net (*)
=StatServ= ***** End of List (* indicates Server is online at the moment) *****
/msg statserv server <servername>
Returns:
=StatServ= Statistics for services.dynam.ac since [Mar (Thu 21) 2002 08:47 [PM/SGT]]
=StatServ= Current Users: 7 (70%)
=StatServ= Maximum Users: 7 at [Mar (Thu 21) 2002 08:47 [PM/SGT]]
=StatServ= Current Opers: 5
=StatServ= Maximum Opers: 5 at [Mar (Thu 21) 2002 08:47 [PM/SGT]]
=StatServ= IRCop Kills: 0
=StatServ= Server Kills: 0
=StatServ= Lowest Ping: 0 at [Jan (Thu 01) 1970 07:30 [AM/SGT]]
=StatServ= Higest Ping: 0 at [Jan (Thu 01) 1970 07:30 [AM/SGT]]
=StatServ= Current Ping: 0
=StatServ= services.dynam.ac has never split from the Network.
=StatServ= ***** End of Statistics *****
4] Map Command
/msg statserv map
Returns:
=StatServ= [NAME] [USERS/MAX] [OPERS/MAX] [LAG/MAX]
=StatServ= stats.dynam.ac [ 2/2 ] [ 0/0 ] [ 0/0 ]
=StatServ= _Server.IRC.net [ 1/1 ] [ 0/1 ] [ 0/0 ]
=StatServ= | _services.dynam.ac [ 7/7 ] [ 5/5 ] [ 0/0 ]
=StatServ= | | _blha.com [ 0/0 ] [ 0/0 ] [ 0/1 ]
=StatServ= | _Server2.IRC.net [ 0/0 ] [ 0/0 ] [ 0/1 ]
=StatServ= --- End of Listing ---
5] Netstats Command
/msg statserv netstats
Returns:
=StatServ= Network Statistics:-----
=StatServ= Current Users: 10
=StatServ= Maximum Users: 10 [[Mar (Thu 21) 2002 08:47 [PM/SGT]]]
=StatServ= Current Channels 0
=StatServ= Maximum Channels 2 [[Mar (Fri 22) 2002 09:46 [PM/SGT]]]
=StatServ= Current Opers: 5
=StatServ= Maximum Opers: 6 [[Mar (Thu 21) 2002 08:47 [PM/SGT]]]
=StatServ= Users Set Away: 0
=StatServ= Current Servers: 5
=StatServ= Maximum Servers: 5 [[Mar (Thu 21) 2002 08:47 [PM/SGT]]]
=StatServ= --- End of List ---
6] Daily Command
/msg statserv daily
Returns:
=StatServ= Daily Network Statistics:
=StatServ= Maximum Servers: 5 [Mar (Wed 27) 2002 12:31 [PM/SGT]]
=StatServ= Maximum Users: 10 [Mar (Wed 27) 2002 12:31 [PM/SGT]]
=StatServ= Maximum Chans: 0 [Jan (Thu 01) 1970 07:30 [AM/SGT]]
=StatServ= Maximum Opers: 5 [Mar (Wed 27) 2002 12:31 [PM/SGT]]
=StatServ= All Daily Statistics are reset at Midnight
=StatServ= End of Information.
7] Tld Command
/msg statserv tld <domain>
Returns:
-> *statserv* tld sg
=StatServ= Singapore (sg)
8] Tldmap Command
/msg statserv tldmap
Returns:
=StatServ= Top Level Domain Statistics:
=StatServ= net 9 (90%) -> Generic Top Level Domain (net) ---> Daily Total: 33
=StatServ= num 1 (10%) -> UnResolved (num) ---> Daily Total: 25
=StatServ= End of List
9] OperList Command
/msg statserv operlist
Returns:
=StatServ= For Help: /msg StatServ HELP OPERLIST
=StatServ= On-Line IRCops:
=StatServ= [ 1] OperServ +ioSqd services.dynam.ac 200
=StatServ= [ 2] SS +iSqd services.dynam.ac 200
=StatServ= [ 3] ChanServ +oSqd services.dynam.ac 200
=StatServ= [ 4] StatServ +d stats.dynam.ac 200
=StatServ= [ 5] HelpServ +Sqd services.dynam.ac 200
=StatServ= [ 6] MemoServ +oSqd services.dynam.ac 200
=StatServ= [ 7] NeoStats +d stats.dynam.ac 200
=StatServ= [ 8] Global +ioSqd services.dynam.ac 200
=StatServ= [ 9] NickServ +oSqd services.dynam.ac 200
=StatServ= [10] Fish -a Server.IRC.net 185
=StatServ= End of Listing.
/msg statserv operlist noaway
Returns:
=StatServ= On-Line IRCops (Not Away):
=StatServ= [ 1] OperServ +ioSqd services.dynam.ac 200
=StatServ= [ 2] SS +iSqd services.dynam.ac 200
=StatServ= [ 3] ChanServ +oSqd services.dynam.ac 200
=StatServ= [ 4] StatServ +d stats.dynam.ac 200
=StatServ= [ 5] HelpServ +Sqd services.dynam.ac 200
=StatServ= [ 6] MemoServ +oSqd services.dynam.ac 200
=StatServ= [ 7] NeoStats +d stats.dynam.ac 200
=StatServ= [ 8] Global +ioSqd services.dynam.ac 200
=StatServ= [ 9] NickServ +oSqd services.dynam.ac 200
=StatServ= End of Listing.
/msg statserv operlist <server>
Returns:
=StatServ= On-Line IRCops on Server server.irc.net
=StatServ= [ 1] Fish -a Server.IRC.net 185
=StatServ= End of Listing.
10] BotList Command
/msg statserv botlist
Returns:
=StatServ= On-Line Bots:
=StatServ= End of Listing.
11] Version Command
/msg statserv version
Returns:
=StatServ= StatServ Version Information
=StatServ= -------------------------------------
=StatServ= StatServ Version: 3.1 Compiled Mar 27 2002 at 12:22:27
=StatServ= http://www.neostats.net
=StatServ= -------------------------------------
=StatServ= HTML Stats is: /var/www/html/stats/index.html
12] Forcehtml Command
/msg statserv forcehtml
Returns:
<StatServ> Fish Forced the NeoStats Statistics HTML file to be updated with the most current statistics
13] Reset Command
/msg statserv reset
Returns:
<StatServ> Fish Wants me to RESET the databases.. here goes..
14] Stats Command
/msg statserv stats list
Returns:
=StatServ= Statistics Database:
=StatServ= [1 ] stats.dynam.ac
=StatServ= [2 ] services.dynam.ac
=StatServ= [3 ] Server.IRC.net
=StatServ= [4 ] blha.com
=StatServ= [5 ] Server2.IRC.net
=StatServ= End of List.
/msg statserv stats del <servername>
Returns:
=StatServ= Removed blha.com from the database.
/msg statserv stats copy <name> <newname>
=StatServ= Copied Server data from <name> to <newname>
15] HTML Syntax
By Default, StatServ uses a file called index.tpl in your data directory as the template for your output.
Currently, the template system is very basic, and will output tables containing the information requested.
All Template variables are enclosed by "!"
The available template variables are:
!MAP! -Outputs a network Map similar to /msg statserv map in a table format
!SRVLIST! -Outputs a complete list of servers that StatServ has ever seen, which are linked to detailed server information provided by the template variable !SRVLISTDET!
!NETSTATS! -Outputs Network Statistics similar to /msg statserv netstats
!DAILYSTATS! -Outputs the Daily Statistics similar to /msg statserv daily
!DAILYTOPCHAN! -Outputs the top10 channels based on number of members
!TOP10CHAN! -Outputs the top10 channels ever based on number of joins
!TOP10KICKS! -Outputs the top10 kicking channels
!TOP10TOPICS! -Outputs the top10 topic changing channels
!VERSION! -Outputs the version of StatServ/NeoStats
StatServ also puts out some information on when the page was created, and what software created it by default at the end of your HTML page. This option can not be disabled. (Sorry, but its our little advertisment for all the hard work we have done to create NeoStats for you to use!)
A example template is provided for you so you don't have to waste time getting your own template ready. If you wish to create your own template, replace the index.tpl file in the data directory with your version.