Time for action – adding MySQL data source
As for Oracle, we are assuming here that you already have a MySQL database available.
Before we add our MySQL data store, let's get some geospatial data inserted into MySQL. Get the
6686_05_mysql_usacounties.sql.zip
file and unzip it. Create a new database in MySQL. Call itgeoserver
.Import
6686_04_mysql_usacounties.sql
into MySQL:mysql --connect_timeout=60 --max_allowed_packet=32MB –u root -p geoserver < 6686_04_mysql_usacounties.sql
To add MySQL support, we need to download an extension. Point your browser to http://geoserver.org/display/GEOS/Stable, locate the Extensions section, and click on the MySQL link to download the ZIP file.
Stop Tomcat service. Extract the ZIP file, select the two
.jar
files, and move them to thewebapps/geoserver/WEB-INF/lib
folder under the Tomcat installation folder.Start Tomcat service and then log in to the GeoServer administration interface. Go to the Data | Stores section and click on Add new store. You can now...