Did some more work on the logging system, and changed the error reporting on the global DB.