Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Not quite sure if I should even be doing this. What I am wanting is I will be dynamically generating my sld file and it looks like when you update the sld in the geoserver admin it does a reload. So I tried to do a reload using the rest api and curl and it does not appear to work.
Here is my Curl

curl -uadmin:password-XPOST http://localhost:8080/geoserver/rest/reload

If there is another way to clear everything so my sld reloads that'd be awesome as well. Just needing to get this working and am not sure why it isn't.

Thank you

share|improve this question
up vote 2 down vote accepted

How often are you doing this? For dynamic SLD files it is usually easier to send the SLD as part of the WMS request (i.e. use SLD not STYLES parameter) rather than changing the file on the server.

share|improve this answer

Which version of GeoServer are you using? If it is before 2.1 you need to manually install the restconfig extension. If 2.1 or later the extension should be installed by default.

I also agree with Ian in that if the the SLD is going to be constantly changing it might be nicer to just specify it on the fly.

share|improve this answer
well then that explains why it isn't working... Trying to get the sld to load on the file, I'm not having much luck. here is what I am doing and it is still loading the style from the wms. var tiled = new OpenLayers.Layer.WMS( "zip3 = Tiled", "http://localhost:8080/geoserver/wms", { layers:'tiger:zip3', styles: null }); map.addLayers([tiled]); tiled.mergeNewParams({sld :'http://localhost/styles/new.sld'}); – arkansasonline Mar 25 '11 at 21:31

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.