installation-and-configuration/Configuration
Configuration
There are 2 files to configure for HawkEye. I advise editing them all in Notepad plus plus - it has proper syntax highlighting for YAML format. When editing YAML do NOT use tabs - use spaces at all time or you will get errors.
config.yml
This is located at plugins/HawkEye/config.yml
. This file is used to control how and what HawkEye logs.
general: max-lines: 0 #Maximum number of lines in a single result - leave as 0 for no limit give-user-tool: true # Whether or not to spawn the user a tool tool-block: 17 #Block to be used for the /he tool log-item-drops-on-death: false #When a player dies, log the items they drop cleanse-age: '0' #Max-age of records in the database in the format '5w8d2h9m4s. Set to '0' to turn this feature off. w = week, d = day, h = hour, m = minute, s = second cleanse-period: '10m' #How often old records are deleted from the database delete-data-on-rollback: false #Delete data from the database when it is rolled back log-ip-addresses: true #Log IP addresses in join/quit events or not debug: false #Turn this on if you are getting MySQL issues and then report the output max-radius: 0 #Maximum radius allowed in search and rollback commands mysql: #Place your MySQL server details in here hawkeye-table: hawkeye port: 3306 player-table: hawk_players username: root world-table: hawk_worlds hostname: localhost max-connections: 10 #Do not change unless you have 'too many connection' sql errors password: '' database: minecraft block-filter: #Blocks in this list will not be logged in block-break and block-place events - 33 - 34 command-filter: #Place commands in this section to stop DataLog from logging them - /login - /restartsrv - /register log: #Edit these values to false if you do not wish to log them lava-bucket: true other: true pvp-death: true block-fade: true chat: true quit: true sign-place: true lava-flow: true flint-steel: true button: true command: true block-form: true teleport: true lever: true item-drop: true water-bucket: true block-burn: true block-break: true leaf-decay: true water-flow: true join: true door-interact: true block-place: true open-container: true item-pickup: true explosion: true container-transaction: true mob-death: true other-death: true version: 1.0.0
config.php
This is one of the php files you upload to your web server. You need to edit the variables with your MySQL details and a password for the web app if you desire:
<?php $config = array( //Enter your MySQL database information //Do not change 'dbTable' "dbHost" => "localhost", "dbDbase" => "minecraft", "dbUser" => "root", "dbPass" => "", "dbTable" => "hawkeye", "dbPlayerTable" => "hawk_players", "dbWorldTable" => "hawk_worlds", //Set this to the password you want people to have to use to access the interface //Leave blank for no password "password" => "", //Default radius to search for if user supplies a location "radius" => 30, //Limit the maximum number of results that can be returned. Do not use quotes //Set to 0 for no limit "maxResults" => 0, //Language pack - default is english.php //You can create your own based off the english.php file, //then change the name below to your language file name "langFile" => "english.php", //Log queries to log.txt //Useful to keep track of who is querying what "logQueries" => true ); ?>
Config.yml is outdated, there are serval things that are missing, for example default-here-radius. Thx for fixing
Edit: Also there are still DataLog things at .yml :D
what is
cleanse-period:
@marvinej
i believe its the period of time it checks for old files. the file's age is the cleanse-age. if you set it to 1w, then every 20 mins it checks to see if there are files over 1 week old. if there are, it deletes them, and recreates them. i dont know for sure, but i'm guessing
Hello. My friend is trying to use Hawkeye on his server, but his host (and mine for I have a server there too) does not allow databases like MySQL. I'm somewhat familiar with MySQL, as I have my own web server, and I've given him the information he would need, but when he goes to use Hawkeye he gets this:
Error! Table '[TABLE NAME].hawk_players' doesn't exist
([TABLE NAME] is just a replacement for the actual table name)
When I go into PHPMyAdmin, I see that that is correct, that the plugin didn't automatically create the tables nor their structures. I've pieced through the files and I have found anything about the structure of the tables to attempt to create them myself.
Is there any way this can be helped?
Thanks in advance,
JollyGG (And LigerXT5)
15:41:30 [SEVERE] [HawkEye] Exception: java.lang.NullPointerException 15:41:30 [SEVERE] [HawkEye] Exception: java.lang.NullPointerException 15:41:30 [SEVERE] [HawkEye] Exception: java.lang.NullPointerException
huge spam of this in console ....
@BioBG
same here. nothing different except for changing cleanse-age from '0' to '2w' and cleanse-period from 0 to 6h did i miss something?
ah i think i see what i did wrong. it should be this according to default cleanse-period: 6h cleanse-age: 2w
testing...
ok still no go. no matter what i do i still get this
2011-12-27 18:11:23 [SEVERE] [HawkEye] Error whilst attempting to get connection: com.mysql.jdbc.exceptions.jdbc4.CommunicationsException: Communications link failure The last packet sent successfully to the server was 0 milliseconds ago. The driver has not received any packets from the server. 2011-12-27 18:11:23 [SEVERE] [HawkEye] Error initiating HawkEye database connection, disabling plugin 2011-12-27 18:11:23 [INFO] [HawkEye] Version 1.0.5b disabled!
ok i give up. i think its our current database getting overloaded. ive switched it over to a site www.myfreesql.net for now. issue solved. ill completely flush our database later and hope for the best. ill try to update info for others if i remember to :) happy hawking :D
Yes, what is cleanse-period. It's not it the files above ^^
I keep getting this in the console. I'm currently using Bukkit 1.1 and I've double checked the MySQL credentials multiple times and it is not working.
24.01 18:43:07 [Server] INFO at net.minecraft.server.ThreadServerApplication.run(SourceFile:465) 24.01 18:43:07 [Server] INFO at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:434) 24.01 18:43:07 [Server] INFO at net.minecraft.server.MinecraftServer.w(MinecraftServer.java:550) 24.01 18:43:07 [Server] INFO at net.minecraft.server.MinecraftServer.b(MinecraftServer.java:573) 24.01 18:43:07 [Server] INFO at org.bukkit.craftbukkit.CraftServer.dispatchCommand(CraftServer.java:382) 24.01 18:43:07 [Server] INFO at org.bukkit.craftbukkit.CraftServer.dispatchCommand(CraftServer.java:386) 24.01 18:43:07 [Server] INFO at org.bukkit.command.SimpleCommandMap.dispatch(SimpleCommandMap.java:168) 24.01 18:43:07 [Server] INFO at org.bukkit.command.defaults.ReloadCommand.execute(ReloadCommand.java:22) 24.01 18:43:07 [Server] INFO at org.bukkit.Bukkit.reload(Bukkit.java:188) 24.01 18:43:07 [Server] INFO at org.bukkit.craftbukkit.CraftServer.reload(CraftServer.java:444) 24.01 18:43:07 [Server] INFO at org.bukkit.craftbukkit.CraftServer.enablePlugins(CraftServer.java:174) 24.01 18:43:07 [Server] INFO at org.bukkit.craftbukkit.CraftServer.loadPlugin(CraftServer.java:191) 24.01 18:43:07 [Server] INFO at org.bukkit.plugin.SimplePluginManager.enablePlugin(SimplePluginManager.java:253) 24.01 18:43:07 [Server] INFO at org.bukkit.plugin.java.JavaPluginLoader.enablePlugin(JavaPluginLoader.java:1059) 24.01 18:43:07 [Server] INFO at org.bukkit.plugin.java.JavaPlugin.setEnabled(JavaPlugin.java:231) 24.01 18:43:07 [Server] INFO at uk.co.oliwali.HawkEye.HawkEye.onEnable(HawkEye.java:106) 24.01 18:43:07 [Server] INFO java.lang.InstantiationError: org.bukkit.command.ConsoleCommandSender 24.01 18:43:07 [Server] SEVERE Error occurred while enabling HawkEye v1.0.4 (Is it up to date?): org.bukkit.command.ConsoleCommandSender 24.01 18:43:07 [Server] INFO [HawkEye] Starting database cleanse thread
i get errors like this: on a mac 10.6
this happened
12:50:27 [INFO] [HawkEye] Loading HawkEye v1.0.5b.
12:50:27 [INFO] [HawkEye] Starting HawkEye 1.0.5b initiation process...
12:50:27 [INFO] [HawkEye] Using Permissions for user permissions
12:50:27 [INFO] [HawkEye] Performing update check...
12:50:33 [INFO] [HawkEye] No updates available for HawkEye
12:50:34 [SEVERE] [HawkEye] Error whilst attempting to get connection: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: Unknown database 'minecraft'
12:50:34 [SEVERE] [HawkEye] Error initiating HawkEye database connection, disabling plugin
Hi,
I have a question about cleanse-age:
I have problems to understand this dateformat. Can someone help me?
Could you update this page to show the current defaults, with the matching ordering for easy comparison? Much thanks =)
@jwong98
You need to create a MySql database named 'minecraft'.
Im trying to set up hawkeye but I just cant get it to work! I keep getting this error
12.05 21:23:35 [Server] SEVERE [HawkEye] Error initiating HawkEye database connection, disabling plugin 12.05 21:23:35 [Server] SEVERE [HawkEye] Error whilst attempting to get connection: java.sql.SQLException: Access denied for user 'root'@'localhost' (using password: NO)
Or this error
12.05 21:23:35 [Server] SEVERE [HawkEye] Error initiating HawkEye database connection, disabling plugin 12.05 21:23:35 [Server] SEVERE [HawkEye] Error whilst attempting to get connection: java.sql.SQLException: Access denied for user 'root'@'localhost' (using password: YES)
Ive put a copy of my config file on pastebin
http://pastebin.com/vHqHQsRY
i have a problem with the results
@MetalCar
I have the same problem
for what's painting place? thanks!
same problem with the results, get freezed don't find anything...
Same problem :[
: Access denied for user 'root'@'localhost' (using password: NO)
is an error given when your login for your root is set differently, you need to contact your server provider for this info if you don't remember what your root login is. Some host also don't use localhost for security reasons. Again see your host.
If your using this on a home server and have mysql or whatever installed, see your installation for your default for root. change the file above to fix this.
dbHost" => "localhost", "dbDbase" => "minecraft", "dbUser" => "root", "dbPass" => "", "dbTable" => "hawkeye", "dbPlayerTable" => "hawk_players", "dbWorldTable" => "hawk_worlds",
the stuff he marked in red has to be changed to what yours server is. Hopfully you followed building the database correctly to keep the table names the same. The part where people log in if left blank is fine, however in your root of your database it is not.
Whenever I start the server I get:
[SEVERE] [Hawkeye] Error checking HawkEye tables: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: Specified key was too long, maximum key length is 767 bytes