ggStats : Game Log Parser

Legacy: MyMineMin

Currently being rebuilt based on what has been learned in this build.

MyMineMin makes it possible to view chat logs, user activity and other data in an easy to understand format via your web browser. Designed to enable server admins to better understand what's going on in their server.

The system exports log data from one or more servers to a central database. From there a web based user interface displays the data in a human readable format. The system can exist on one server or across multiple servers.

YouTube Video (v0.2)

Features

  • Web desktop and mobile browser access
  • Overview, Multi server
  • Chat log
  • Activity Log
  • Player Login Location Map
  • Easily view Whitelist, ban list and ops

Downloads

myMineMin-19.tar.gz myMineMin-19.zip

Requirements

  • Minecraft, tested with vanilla 1.8 and spigot/bukkit (looking for more logs)
  • Web server (developed for Apache, but others should work too), can be on different server to minecraft
  • MySQL database, can be on different server to minecraft
  • PHP
  • PHP - Zlib (default on most installs, required as old logs are compressed)

Installation

Extract the files from the zip. There are 2 programs to install, the exporter script, and the web UI (User Interface).

These instructions assume you know how to run php scripts, upload files to servers, manage mysql databases.

Database

  1. Create the database and update the file config/db.php
  2. Run the SQL in the file install/install.sql on your mysql server, on many web servers you can use phpMyAdmin
  3. Remove the installation directory if it's web accessible
If you are running the exporter and UI on different servers, make sure that those servers can access the database, you may need to add their IP to the list of IPs that can access the database remotely.

Uploading

Single Server
If your web server and minecraft server are on the same server then copy all files across. Remove the install folder.

Multiple Servers
For web servers, move the exporter to individual game servers and export

Exporter

The script for exporting the data to the database is exporter/cron.php

For servers exporting data you will need to configure config/servers.php. This file contains the list of individual minecraft server installs to export. This does not need to be configured on the UI as details are read from the database.

  1. First time, run at the command line with a user that has permission to read the minecraft log files. This will bulk load into the database and expose any errors. This process may take some time.
  2. Run again to get an idea of the time it takes to parse the daily logs, remember most your users will probably play at night so allow more time.
  3. Add exporter/cron.php to cron or other scheduling program at 10 - 60 intervals to suite your needs. Be careful to not have exports overlap, this will cause duplication issues. On many linux systems you can use a program called flock to force one instance only to run at a time.

UI (User Interface)

View the folder through a web browser after the export has run at least once.

Common Issues

Can not access/can not read errors
Either $cfg['directory_minecraft'] is pointing to the wrong directory or the exporter doesn't have read access to the files. For Apache you can either add www-data to your minecraft user group, or allow the files in the minecraft server directory to be read by all users (0775)

It's really slow!!!
Speed depends on the size of the log files and the speed of your web server. Because we are parsing log files every line of the file must be read, so it can take a while with large files.

Where's the Auth?
Currently use a password protected directory which most web servers have. Windows web servers IIS password protect directory and Apache .htaccess. Auth integration is in the works.