Google Earth Enterprise Documentation Home | Troubleshooting and error messages
Geecheck: test your GEE Server status
Geecheck is a tool that checks the health and status of a GEE Server installation. With GEE 5.1.x, you can use geecheck to run tests and then view the results in a browser-based dashboard. Results are organized into suites of results so that you can quickly review the status of Fusion, GEE Server, as well as see the output of other tests that you write.
- How geecheck works
- Access test results from GEE Server Admin console
- Run the tests again
- Create your own tests
- Run geecheck on the command line
- Run geecheck in a browser
- About moving tests
How geecheck works
Geecheck is a Python application, geecheck.py
, and is installed in the following location:
/opt/google/gehttpd/cgi-bin
geecheck.py
geecheck_tests/
user_tests/
fusion_tests/
server_tests/
run_geecheck.py
set_geecheck_config.py
geecheck.py
runs and displays the results from any tests located in the subfolders:geecheck_tests/
user_tests/
fusion_tests/
server_tests/
- Tests must follow the naming convention
*_test.py
, for example,dns_test.py
. Test results are organized by the subfolder or suite they belong to, that is, all tests inuser_tests
are categorized under that results heading.
Access test results from GEE Server Admin console
To access geecheck from GEE Server Admin console:
- Go to myserver.mydomainname.com/admin, replacing myserver and mydomainname with your server and domain.
- Sign in with the default credentials:
- Username: geapacheuser
- Password: geeadmin
To reset the username and password:
sudo /opt/google/gehttpd/bin/htpasswd -c
/opt/google/gehttpd/conf.d/.htpasswd geapacheuser
- Click the Settings icon
and select Diagnostics from the menu to display the Geecheck page.
- View the Test Summary and Test Details sections to verify the results of the tests that geecheck ran.
Run the tests again
If you find you need to perform some troubleshooting based on the results of any of your tests and you need to run the tests again to confirm whether you’ve fixed the issue, simply restart GEE Server, then open the Geecheck page again.
- On the command line:
$ sudo /etc/init.d/geserver restart
- Access test results from GEE Server Admin console.
Create your own tests
GEE 5.1 includes some basic tests that you can run but geecheck is a framework that lets you easily plug in your own tests and view the results in a browser or on the command line. Tests should be Python unit tests and must be copied to one of the three test subfolders to be run from geecheck:
geecheck_tests/
user_tests/
fusion_tests/
server_tests/
To get some idea of how you can write your own test, you can study the structure of the sample test, sample_test.py
, provided in the user_tests
subfolder. Use the code as a guide or simply copy and edit it if you are unfamiliar with Python unit tests.
Run geecheck on the command line
You can run geecheck.py
from the command line with options to exclude tests and specify the output. The default settings includes all tests and output text.
Exclude tests:
--no_user_tests
--no_fusion_tests
--no_server_tests
Specify format:
json
text
For example, to output results in JSON format, excluding /user_tests
:
$ /opt/google/gehttpd/cgi-bin python geecheck.py --no_user_tests json
Run geecheck in a browser
To provide browser-based output, geecheck uses a wrapper: /opt/google/gehttpd/cgi-bin/run_geecheck.py
, which runs the geecheck.py
script and makes the output available to browsers here: http://MY_SERVER/cgi-bin/run_geecheck.py
.
The JSON response is used with the following page to make those results readable: http://MY_SERVER/admin/geecheck.html
, which is the page that displays from the Diagnostics selection in the Settings menu icon of the GEE Server Admin console.
About moving tests
You may want to run geecheck from a different location, for example, if you’ve already created a large number of tests in a different directory. Geecheck can be run successfully from a different location with a few simple rules:
- You can move
geecheck_tests
but you need to maintain the subfolder structure for geecheck to run:geecheck_tests/
user_tests/
fusion_tests/
server_tests/
geecheck.py
andset_geecheck_config.py
must be moved withgeecheck_tests/
:geecheck.py
set_geecheck_config.py
geecheck_tests/
run_geecheck.py
looks for test scripts to run. It should not be moved.
Once test scripts have been moved, set_geecheck_config.py
should be run:
$ ./set_geecheck_config.py
This action updates the configuration found at /opt/google/geecheck/conf
, which tells run_geecheck.py
where to look for tests.