Search Postgresql Archives

Re: Job scheduling in Postgre

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Dec 4, 2008 at 4:21 PM, A. Kretschmer
<andreas.kretschmer@xxxxxxxxxxxxxx> wrote:
> am  Thu, dem 04.12.2008, um 10:50:38 -0500 mailte Robert Treat folgendes:
>> On Tuesday 02 December 2008 07:11:02 A. Kretschmer wrote:
>> > am  Tue, dem 02.12.2008, um 16:45:16 +0500 mailte IPS folgendes:
>> > > I have certain jobs  to be executed automatically at a given interval of
>> > > time in the postgre SQL database. Is their any utility/feature available
>> > > in Postgre to do so.
>> >
>> > No, use the scheduler from the OS, CRON for example (UNIX).
>> >
>>
>> There is a database level schedular called (iirc) pgAgent, which comes bundled
>> with pgAdmin. I think it's so well hidden because it comes as a part of a
>
> How does it work? Independent from the OS? On the server, within
> PostgreSQL?

It runs as a service on Windows or daemon on *nix, and connects to a
pgagent schema in a database which may or may not be on the same
machine.

You can define jobs using pgAdmin (the definitions of which are stored
in the database) which consist of one or more SQL or batch/shell
steps. A job can be targetted at a particular server, so you can
ensure batch steps run on a Windows box, and shell on a unix, or can
be run by the first (or only) pgAgent instance that picks it up. SQL
steps currently target a specific database, and in future releases
will be able to target databases on alternate servers - a feature
required for use with hot standby servers.

Each job can have one or more schedules attached to it. Schedules are
defined in a vaguely cron-like way, and include date/time based
exception rules (so you can do things like 'run every day except for
the 25/12/2008'.

See http://www.pgadmin.org/docs/1.8/pgagent.html for more info, and screenshots.

-- 
Dave Page
EnterpriseDB UK:   http://www.enterprisedb.com

-- 
Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux