O'Reilly logo

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

GeoServer Beginner's Guide - Second Edition

Book Description

This step-by-step guide will teach you how to use GeoServer to build custom and interactive maps using your data.

About This Book

  • Exploit the power of GeoServer to provide agile, flexible, and low -cost community projects
  • Share real-time maps quickly
  • Boost your map server's performance using the power and flexibility of GeoServer

Who This Book Is For

If you are a web developer with knowledge of server side scripting, have experience in installing applications on the server, and want to go beyond Google Maps by offering dynamically built maps on your site with your latest geospatial data stored in MySQL, PostGIS, MySQL, or Oracle, this is the book for you.

What You Will Learn

  • Install GeoServer quickly
  • Access dynamic real-time geospatial data that you can easily integrate into your own web-based application
  • Create custom styles for lines, points, and polygons for great-looking maps
  • Command GeoServer remotely using REST
  • Tune your GeoServer instance for performance
  • Move GeoServer into production
  • Learn advanced topics to extend GeoServer's capabilities

In Detail

GeoServer is an opensource server written in Java that allows users to share, process, and edit geospatial data. This book will guide you through the new features and improvements of GeoServer and will help you get started with it. GeoServer Beginner's Guide gives you the impetus to build custom maps using your data without the need for costly commercial software licenses and restrictions. Even if you do not have prior GIS knowledge, you will be able to make interactive maps after reading this book.

You will install GeoServer, access your data from a database, and apply style points, lines, polygons, and labels to impress site visitors with real-time maps. Then you follow a step-by-step guide that installs GeoServer in minutes. You will explore the web-based administrative interface to connect to backend data stores such as PostGIS, and Oracle. Going ahead, you can display your data on web-based interactive maps, use style lines, points, polygons, and embed images to visualize this data for your web visitors. You will walk away from this book with a working application ready for production.

After reading GeoServer Beginner's Guide, you will be able to build beautiful custom maps on your website using your geospatial data.

Style and approach

Step-by-step instructions are included and the needs of a beginner are totally satisfied by the book. The book consists of plenty of examples with accompanying screenshots and code for an easy learning curve.

Downloading the example code for this book. You can download the example code files for all Packt books you have purchased from your account at http://www.PacktPub.com. If you purchased this book elsewhere, you can visit http://www.PacktPub.com/support and register to have the code file.

Table of Contents

  1. Preface
    1. What this book covers
    2. What you need for this book
    3. Who this book is for
    4. Conventions
    5. Reader feedback
    6. Customer support
      1. Downloading the example code
      2. Downloading the color images of this book
      3. Errata
      4. Piracy
      5. Questions
  2. GIS Fundamentals
    1. What is GIS about?
    2. The foundation of any GIS - spatial data
    3. Measuring the world
      1. Moving on to the planet with decimal degree coordinates
      2. Projecting a sphere on a plane
    4. Understanding coordinate systems
      1. Commonly used coordinate systems
        1. Universal Transverse Mercator system
        2. Web Mercator
      2. Spatial Reference Identifier (SRID)
      3. Exploring the EPSG registry
    5. Representing geometrical shapes
    6. Modelling the real world with raster data
    7. Representing the world
      1. Exploring OpenStreetMap
    8. Adding more colors to your maps
      1. Choropleth maps
      2. Proportional maps
        1. Making your thematic map
    9. Summary
  3. Getting Started with GeoServer
    1. Installing required components
      1. Checking presence of Java on your windows machine
      2. Checking the presence of Java on your Linux machine
      3. Installing JRE on your server
      4. Installing Tomcat on your server
    2. Configuring Tomcat as a service on Linux Mint
    3. Installing GeoServer
    4. Deploying GeoServer on Tomcat
    5. Implementing basic security
    6. Improving security settings
    7. Understanding the GeoServer release cycle
    8. Upgrading your installation
    9. Summary
  4. Exploring the Administrative Interface
    1. Understanding the interface
    2. The About & Status section
      1. The Server Status link
      2. The GeoServer Logs section
      3. The Contact Information section
      4. The About GeoServer section
      5. Manually reloading the configuration
    3. The Data section
      1. The OpenLayers preview
        1. The KML preview
    4. The Services section
      1. WMTS
      2. WMS
      3. WFS
      4. WCS
        1. Limiting the SRS list from WMS
    5. Settings
      1. Changing your logging configuration
    6. Tile Caching
    7. The Security panel
      1. The Settings panel
      2. Users, Groups, and Roles
      3. Data
      4. Catalog security
      5. Services security
    8. Demos
      1. Exploring Demo requests
      2. Filtering the projection list
    9. Summary
  5. Adding Your Data
    1. Configuring your data
    2. Configuring vector data sources
      1. Java properties files
        1. Adding properties files
      2. Using shapefile
        1. Adding shapefiles
      3. Using PostGIS
        1. Installing PostgreSQL and PostGIS
        2. Loading data in PostGIS and publishing them in GeoServer
    3. Configuring raster data sources
      1. ArcGrid
      2. GeoTiff
      3. Gtopo30
      4. ImageMosaic
      5. WorldImage
    4. Adding a raster
    5. Exploring additional data sources
      1. Using Oracle
        1. Adding Oracle support in GeoServer
      2. Loading data in Oracle
    6. Summary
  6. Accessing Layers
    1. Web services
    2. WMS formats
      1. OpenLayers
        1. Exploring the OpenLayers options
    3. Working with tiles
    4. Exploring further Web Map Service output formats
      1. The AtomPub format
      2. The GIF format
      3. The GeoRSS format
      4. The JPEG format
      5. The KML (Plain) format
      6. The KMZ (Compressed) format
      7. The PDF format
      8. The PNG format
      9. The SVG format
      10. The TIFF format
    5. Web Feature service
      1. The CSV format
      2. The GeoJSON format
        1. Parsing GeoJSON
      3. Shapefile
    6. Extra output options
    7. The TEXT/HTML format
      1. Using the GetFeatureInfo freemarker template
    8. ImageMap
    9. Using the WMS Reflector
    10. Summary
  7. Styling Your Layers
    1. Understanding Styled Layer Descriptor (SLD)
    2. Editing styles
      1. Installing the CSS module
    3. Exploring the standard structure of a style
      1. Exploring GeoServer bundled styles
    4. Loading data for styling
    5. Working with point symbols
      1. Creating a simple point style
      2. Adding a stroke value
      3. Dealing with angles and transparency
      4. Composing simple shapes
      5. Using external graphics
      6. Composing your symbol
    6. LineString symbols
      1. Creating a simple line style
      2. Adding a border and a centerline
      3. Using hatching
      4. Using dashed lines
      5. Mixing dashing lines and markers
    7. Working with polygon symbols
      1. Creating a simple polygon style
      2. Using a graphic filling
      3. Using hatching with polygons
    8. Adding labels
      1. Labeling points
      2. Labeling lines
      3. Labeling polygons
    9. Thematic mapping
      1. Classifying roads
    10. Setting visibility
      1. Enhancing thematic roads maps
    11. Putting it all together
      1. Grouping layers
    12. Styling with CSS
      1. Creating a style with CSS
    13. Summary
  8. Creating Simple Maps
    1. Exploring the Google Maps API
      1. Adding a GeoServer layer as overlay
      2. Adding a GeoServer layer as a base layer
    2. Using OpenLayers
      1. Integrating GeoServer and OpenLayers
      2. Using tiled WMS
      3. Mixing WMS and WFS
    3. Exploring Leaflet
      1. Creating a basic map with Leaflet
    4. Summary
  9. Performance and Caching
    1. Exploring GeoWebCache
    2. Configuring GeoWebCache
    3. Configuring Disk Quota
    4. Setting Caching Defaults
      1. Direct integration
      2. WMS-C
      3. TMS and WMTS
    5. Default layers options
      1. Default Cached Gridsets
      2. Configuring gridsets
        1. Creating a custom gridset
    6. Configuring Tile Layers
      1. Configuring layers and layer groups for caching
    7. Using tiles with OpenLayers
    8. Seeding a layer
    9. Using an external GeoWebCache
    10. Summary
  10. Automating Tasks - GeoServer REST Interface
    1. Introducing REST
    2. Using REST
    3. Installing the Requests library
    4. Managing data
      1. Working with workspaces and namespaces
      2. Managing workspaces
    5. Using data stores
      1. Managing data stores
    6. Using feature types
      1. Adding a new shapefile
      2. Adding a PostGIS table
    7. Publishing data
      1. Working with Styles
      2. Adding a new style
    8. Working with Layers
      1. Managing Layers
    9. Administer GeoServer with REST
      1. Managing global settings
      2. Reloading configuration
      3. Managing services
    10. Summary
  11. Securing GeoServer Before Production
    1. Basic Security Settings
      1. Enabling strong encryption
      2. Changing the master password
    2. Defining users, groups, and roles
      1. User definition
      2. Group definition
      3. The Users/Groups services
      4. Roles definition
      5. Creating users and groups
      6. Defining roles
    3. Accessing data and services
    4. Securing layers
    5. Summary
  12. Tuning GeoServer in a Production Environment
    1. Tuning Java
      1. Configuring Java runtime parameters
    2. Installing native JAI
    3. Removing unused services
    4. Enabling the Marlin rasterizer
    5. Setting a proxy
    6. Avoiding service faults
      1. Configuring a cluster
    7. Summary
  13. Going Further - Getting Help and Troubleshooting
    1. Going beyond maps
    2. Delivering vector data
    3. Retrieving vector data
    4. Delivering raster data
    5. Retrieving raster data
    6. Advanced configuration - Database connection pooling
      1. Creating a connection pool
    7. Advanced configuration - Monitoring GeoServer
      1. Installing and configuring the monitoring extension
    8. Getting help
    9. Summary