Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. Join them; it only takes a minute:

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

how do I install postgis2.0 under win 7 to run just on demand. I dont want to run it permanently as a service. Similary as the (nonspatial) mysql can be run on demand via the xampp-tools (

share|improve this question
up vote 3 down vote accepted

Go to Control Panel > Administrative Tools > Services.

Scroll down the list of services to something like "postgresql-x64-9.1", and double-click it (or inspect it's properties). Change startup type from "Automatic" to "Manual". Now you take control of the "start"/"stop".

If you want to turn PostgreSQL (and PostGIS) "on" or "off", you would need to open this Services dialog, find and select the service and press the "Start Service" button (looks like a "play" button for music players), or press the "Stop Service" button to turn it off.

(Older versions of PostgreSQL used to have some convenient icons in the Start menu to "start"/"stop" this service. I'm sure it wouldn't be too difficult to recreate these icons of convenience if really needed.)

Honestly, this will annoy you more than it will help spare your system's resources. Unless you've tuned your PostgreSQL database, the default resource settings are pretty low. If you inspect your Resource Monitor, you will probably see about 10 postgres.exe process threads consuming an average of 0% of your cpu, and a total of perhaps 20 MB (or about 0.02 GB) of your system's RAM. This is a drop in the bucket of resources of a typical computer that is able to run Windows 7.

share|improve this answer

you always can install PostgreSQL as a service in windows, and start/stop it manually from windows service console.

share|improve this answer

To clarify, XAMPP doesn't run MySQL "on demand", per se, but rather wraps everything in a control panel that allows you to quickly start and stop the service.

That said, if what you want is control over a PostGreSQL service (with PostGIS installed) in the same fashion as MySQL in XAMPP, there does appear to be a way to add PostGreSQL support directly to XAMPP. A few links:

I have not done this myself, so I could not tell you how much success you're likely to have.

share|improve this answer
Nat, with on demand I mean that with xampp I can start and stop the mysql-database as I like. I do not need to run mysql as a permanent service, which uses computerressources all the time. The same thing I would like to do with postgis. the links you gave me only deal with postgres without postgis... – Kurt Jul 2 '12 at 20:34

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.