createdb.postgis(1) - Linux man page

Name

createdb.postgis - Create Postgis database in a PostgreSQL server.

Syntax

createdb.postgis [options] database_name

Description

This program create a database for working with Postgis geometries.
Using this program any user with createdb permissions can create a spatial enabled database.

Options

<database_name>
Database to be created.
<options>
All options from createdb(1), except choice of template database, can be used here. Specifying an owner here will not be able to set ownership to the tables originating from the template database used, unless the template owner, that is calling this script, is dba. Otherwise, you could only build databases owned by the template owner.
The most significant option would be --template below.
--template=<templatedb>
Set template name to be <templatedb>
Environment variable: TEMPLATEDB.
--help
Output help information and exit.

Environment

TEMPLATEDB
If $TEMPLATEDB is set, its value is used as the default template name.

Files

The environment variables for template_gis creation, removal and usage may be stored in files, as follows:

/etc/default/postgis
will designate default values for the whole system.
$HOME/.postgis/profile
will designate the values used by the current user by default. Beware, this is the current SYSTEM user, not the dba or the database owner to become. As those values are more user specific, they supersede the ones in the system default file for the current user.

Notes

The order of precedence of the variables definition:

  1. ..
  2. Command line options..
  3. Environment variables..
  4. The user specific profile file.
  5. The system wide default file.
    The builtin (hardwired) values are not a good choice.

    Examples

    To run this program you can simply type:

    # createdb.postgis mypostgis

    Authors

    Alex Bodnaru <alexbodn@012.net.il>
    Roberto Boati <roberto.boati@gmail.com>

    See Also

    createdb.postgis(1), createdb(1), dropdb(1)

    Referenced By

    mktemplate_gis(1), rmtemplate_gis(1)