Re: [GENERAL] (Perl) script to set up an instance for regression tests

2006-12-13 Thread Florian Weimer
* Tom Lane:

> Florian Weimer <[EMAIL PROTECTED]> writes:
>> For regression tests, I'd like to automatically set up a fresh
>> PostgreSQL instance.  Has anybody automated the task (initdb, setting
>> a password, choosing a port at random, starting the server, and after
>> running the tests, stopping the server and deleting all the
>> directories)?
>
> "make check"?

Ah, pg_regress.sh is indeed a good start.  Silly me.  Thanks.

>> $ fakeroot /usr/lib/postgresql/8.1/bin/postgres -D . postgres
>> "root" execution of the PostgreSQL server is not permitted.
>> This is a major problem when autobuilding Debian packages. 8-(
>
> Surely you don't build random packages as root.

It's just fakeroot, a user-space emulation of UID=0, using pre-loaded
dynamic shared objects.  Although "fakeroot id -u" returns "0", you
cannot actually execute any operations that require privileges you
haven't got.

-- 
Florian Weimer<[EMAIL PROTECTED]>
BFK edv-consulting GmbH   http://www.bfk.de/
Kriegsstraße 100  tel: +49-721-96201-1
D-76133 Karlsruhe fax: +49-721-96201-99

---(end of broadcast)---
TIP 5: don't forget to increase your free space map settings


Re: [GENERAL] (Perl) script to set up an instance for regression tests

2006-12-12 Thread Tom Lane
Florian Weimer <[EMAIL PROTECTED]> writes:
> For regression tests, I'd like to automatically set up a fresh
> PostgreSQL instance.  Has anybody automated the task (initdb, setting
> a password, choosing a port at random, starting the server, and after
> running the tests, stopping the server and deleting all the
> directories)?

"make check"?

> $ fakeroot /usr/lib/postgresql/8.1/bin/postgres -D . postgres
> "root" execution of the PostgreSQL server is not permitted.
> This is a major problem when autobuilding Debian packages. 8-(

Surely you don't build random packages as root.

regards, tom lane

---(end of broadcast)---
TIP 2: Don't 'kill -9' the postmaster


[GENERAL] (Perl) script to set up an instance for regression tests

2006-12-12 Thread Florian Weimer
For regression tests, I'd like to automatically set up a fresh
PostgreSQL instance.  Has anybody automated the task (initdb, setting
a password, choosing a port at random, starting the server, and after
running the tests, stopping the server and deleting all the
directories)?  I know, it's a straightforward Perl script, but perhaps
someone else has already written it. 8-)

And:

$ fakeroot /usr/lib/postgresql/8.1/bin/postgres -D . postgres
"root" execution of the PostgreSQL server is not permitted.
[...]

This is a major problem when autobuilding Debian packages. 8-(

-- 
Florian Weimer<[EMAIL PROTECTED]>
BFK edv-consulting GmbH   http://www.bfk.de/
Kriegsstraße 100  tel: +49-721-96201-1
D-76133 Karlsruhe fax: +49-721-96201-99

---(end of broadcast)---
TIP 5: don't forget to increase your free space map settings