pg.ddx.io pgsql-admin@postgresql.org mailing list archive
help / color / mirror / Atom feedrunning pgsql 7 under Jail'ed virtual machine on FreeBSD 4.2
6+ messages / 4 participants
[nested] [flat]
* running pgsql 7 under Jail'ed virtual machine on FreeBSD 4.2
@ 2001-01-04 22:04 Dave VanAuken <dave@hawk-systems.com>
2001-01-05 01:41 ` Re: running pgsql 7 under Jail'ed virtual machine on FreeBSD 4.2 Matt Beauregard <matt@designscape.com.au>
2001-01-05 04:30 ` Re: running pgsql 7 under Jail'ed virtual machine on FreeBSD 4.2 The Hermit Hacker <scrappy@hub.org>
2001-01-05 18:50 ` Re: running pgsql 7 under Jail'ed virtual machine on FreeBSD 4.2 Alex Pilosov <alex@pilosoft.com>
0 siblings, 3 replies; 6+ messages in thread
From: Dave VanAuken @ 2001-01-04 22:04 UTC (permalink / raw)
To: pgsql-general@postgresql.org
Have a FreeBSD 4.2 box... have created two Virtual machines with the
jail process.
Apache and PHp configure and execute fine, but am having some
configuration and execution problems with pgsql... not sure if I am
missing something or if pgsql just cannot deal with being in the jail
and sharing the sysv memory
Attempting to manually start the postmaster produces the following:
%postmaster -i
IpcMemoryCreate: shmget failed (Function not implemented) key=5432010,
size=144, permission=700
This type of error is usually caused by an improper
shared memory or System V IPC semaphore configuration.
For more information, see the FAQ and platform-specific
FAQ's in the source directory pgsql/doc or on our
web site at http://www.postgresql.org.
IpcMemoryIdGet: shmget failed (Function not implemented) key=5432010,
size=144, permission=0
IpcMemoryAttach: shmat failed (Function not implemented) id=-2
FATAL 1: AttachSLockMemory: could not attach segment
%
Have modified the sysctl.conf file to allow usage of sysv memory, but
as it is already shared from the host machine, this may be causing
pgsql to barf on it.
Searching for jail faq's and posts regarding this matter produces some
close, but not helpful posts regarding chroot'ed environments.
Any insights, requests for details, and assistance are appreciated.
Dave
^ permalink raw reply [nested|flat] 6+ messages in thread
* Re: running pgsql 7 under Jail'ed virtual machine on FreeBSD 4.2
2001-01-04 22:04 running pgsql 7 under Jail'ed virtual machine on FreeBSD 4.2 Dave VanAuken <dave@hawk-systems.com>
@ 2001-01-05 01:41 ` Matt Beauregard <matt@designscape.com.au>
2 siblings, 0 replies; 6+ messages in thread
From: Matt Beauregard @ 2001-01-05 01:41 UTC (permalink / raw)
To: Dave VanAuken <dave@hawk-systems.com>; +Cc: pgsql-general@postgresql.org
On Thu, Jan 04, 2001 at 05:04:50PM -0500, Dave VanAuken wrote:
> Have a FreeBSD 4.2 box... have created two Virtual machines with the
> jail process.
> Apache and PHp configure and execute fine, but am having some
> configuration and execution problems with pgsql... not sure if I am
> missing something or if pgsql just cannot deal with being in the jail
> and sharing the sysv memory
>
> Attempting to manually start the postmaster produces the following:
>
> %postmaster -i
> IpcMemoryCreate: shmget failed (Function not implemented)
> key=5432010,
Perhaps you could mail freebsd-questions@freebsd.org and find out if
there are any issues with shared memory inside a jail. My first guess
as to what the error message means is that it's not supported.
--
Matt Beauregard
Information Technology Operations, DesignScape
Ph: +61 2 9361 4233 Fx: +61 2 9361 4633
^ permalink raw reply [nested|flat] 6+ messages in thread
* Re: running pgsql 7 under Jail'ed virtual machine on FreeBSD 4.2
2001-01-04 22:04 running pgsql 7 under Jail'ed virtual machine on FreeBSD 4.2 Dave VanAuken <dave@hawk-systems.com>
@ 2001-01-05 04:30 ` The Hermit Hacker <scrappy@hub.org>
2001-01-05 14:11 ` RE: running pgsql 7 under Jail'ed virtual machine on FreeBSD 4.2 Dave VanAuken <dave@hawk-systems.com>
2 siblings, 1 reply; 6+ messages in thread
From: The Hermit Hacker @ 2001-01-05 04:30 UTC (permalink / raw)
To: Dave VanAuken <dave@hawk-systems.com>; +Cc: pgsql-general@postgresql.org
read the jail man page:
jail.sysvipc_allowed
This MIB entry determines whether or not processes within a jail
have access to System V IPC primitives. In the current jail imple-
mentation, System V primitives share a single namespace across the
host and jail environments, meaning that processes within a jail
would be able to communicate with (and potentially interfere with)
processes outside of the jail, and in other jails. As such, this
functionality is disabled by default, but can be enabled by setting
this MIB entry to 1.
On Thu, 4 Jan 2001, Dave VanAuken wrote:
> Have a FreeBSD 4.2 box... have created two Virtual machines with the
> jail process.
> Apache and PHp configure and execute fine, but am having some
> configuration and execution problems with pgsql... not sure if I am
> missing something or if pgsql just cannot deal with being in the jail
> and sharing the sysv memory
>
> Attempting to manually start the postmaster produces the following:
>
> %postmaster -i
> IpcMemoryCreate: shmget failed (Function not implemented) key=5432010,
> size=144, permission=700
> This type of error is usually caused by an improper
> shared memory or System V IPC semaphore configuration.
> For more information, see the FAQ and platform-specific
> FAQ's in the source directory pgsql/doc or on our
> web site at http://www.postgresql.org.
> IpcMemoryIdGet: shmget failed (Function not implemented) key=5432010,
> size=144, permission=0
> IpcMemoryAttach: shmat failed (Function not implemented) id=-2
> FATAL 1: AttachSLockMemory: could not attach segment
> %
>
> Have modified the sysctl.conf file to allow usage of sysv memory, but
> as it is already shared from the host machine, this may be causing
> pgsql to barf on it.
>
> Searching for jail faq's and posts regarding this matter produces some
> close, but not helpful posts regarding chroot'ed environments.
>
> Any insights, requests for details, and assistance are appreciated.
>
> Dave
>
>
Marc G. Fournier ICQ#7615664 IRC Nick: Scrappy
Systems Administrator @ hub.org
primary: scrappy@hub.org secondary: scrappy@{freebsd|postgresql}.org
^ permalink raw reply [nested|flat] 6+ messages in thread
* RE: running pgsql 7 under Jail'ed virtual machine on FreeBSD 4.2
2001-01-04 22:04 running pgsql 7 under Jail'ed virtual machine on FreeBSD 4.2 Dave VanAuken <dave@hawk-systems.com>
2001-01-05 04:30 ` Re: running pgsql 7 under Jail'ed virtual machine on FreeBSD 4.2 The Hermit Hacker <scrappy@hub.org>
@ 2001-01-05 14:11 ` Dave VanAuken <dave@hawk-systems.com>
0 siblings, 0 replies; 6+ messages in thread
From: Dave VanAuken @ 2001-01-05 14:11 UTC (permalink / raw)
To: pgsql-general@postgresql.org
As listed in the initial post immediately following the screen output,
I have already set the sharing in the sysctl.conf file, the same error
is being generated.
Dave
-----Original Message-----
From: pgsql-general-owner@postgresql.org
[mailto:pgsql-general-owner@postgresql.org]On Behalf Of The Hermit
Hacker
Sent: Thursday, January 04, 2001 11:30 PM
To: Dave VanAuken
Cc: pgsql-general@postgresql.org
Subject: Re: running pgsql 7 under Jail'ed virtual machine on FreeBSD
4.2
read the jail man page:
jail.sysvipc_allowed
This MIB entry determines whether or not processes within a
jail
have access to System V IPC primitives. In the current jail
imple-
mentation, System V primitives share a single namespace
across the
host and jail environments, meaning that processes within a
jail
would be able to communicate with (and potentially interfere
with)
processes outside of the jail, and in other jails. As such,
this
functionality is disabled by default, but can be enabled by
setting
this MIB entry to 1.
On Thu, 4 Jan 2001, Dave VanAuken wrote:
> Have a FreeBSD 4.2 box... have created two Virtual machines with
the
> jail process.
> Apache and PHp configure and execute fine, but am having some
> configuration and execution problems with pgsql... not sure if I am
> missing something or if pgsql just cannot deal with being in the
jail
> and sharing the sysv memory
>
> Attempting to manually start the postmaster produces the following:
>
> %postmaster -i
> IpcMemoryCreate: shmget failed (Function not implemented)
key=5432010,
> size=144, permission=700
> This type of error is usually caused by an improper
> shared memory or System V IPC semaphore configuration.
> For more information, see the FAQ and platform-specific
> FAQ's in the source directory pgsql/doc or on our
> web site at http://www.postgresql.org.
> IpcMemoryIdGet: shmget failed (Function not implemented)
key=5432010,
> size=144, permission=0
> IpcMemoryAttach: shmat failed (Function not implemented) id=-2
> FATAL 1: AttachSLockMemory: could not attach segment
> %
>
> Have modified the sysctl.conf file to allow usage of sysv memory,
but
> as it is already shared from the host machine, this may be causing
> pgsql to barf on it.
>
> Searching for jail faq's and posts regarding this matter produces
some
> close, but not helpful posts regarding chroot'ed environments.
>
> Any insights, requests for details, and assistance are appreciated.
>
> Dave
>
>
Marc G. Fournier ICQ#7615664 IRC Nick:
Scrappy
Systems Administrator @ hub.org
primary: scrappy@hub.org secondary:
scrappy@{freebsd|postgresql}.org
^ permalink raw reply [nested|flat] 6+ messages in thread
* Re: running pgsql 7 under Jail'ed virtual machine on FreeBSD 4.2
2001-01-04 22:04 running pgsql 7 under Jail'ed virtual machine on FreeBSD 4.2 Dave VanAuken <dave@hawk-systems.com>
@ 2001-01-05 18:50 ` Alex Pilosov <alex@pilosoft.com>
2001-01-05 20:08 ` RE: running pgsql 7 under Jail'ed virtual machine on FreeBSD 4.2 Dave VanAuken <dave@hawk-systems.com>
2 siblings, 1 reply; 6+ messages in thread
From: Alex Pilosov @ 2001-01-05 18:50 UTC (permalink / raw)
To: Dave VanAuken <dave@hawk-systems.com>; +Cc: pgsql-general@postgresql.org
Here's the story about pgsql and jail:
1. FreeBSD shared memory is _really_ shared across all jail VMs. I think
its not going to change, as this seems like a great way for processes to
exchange data...But I could be wrong. :)
2. Postgres uses some funky math to determine which shmid to use for
different memory allocations it needs. The problem with that it has no
idea about jails and will not generate a different shmid for different
processes, so postgres processes end up stepping on each other's toes.
See include/storage/ipc.h, definition of SystemPortAddressGetIPCKey, and
you'll understand what I mean.
To properly fix this, I think this should be done:
Another (optional) backend parameter which should determine offset
(hardcoded now to 17491) for allocation of different shmids...
comments? TODO?
On Thu, 4 Jan 2001, Dave VanAuken wrote:
> Have a FreeBSD 4.2 box... have created two Virtual machines with the
> jail process.
> Apache and PHp configure and execute fine, but am having some
> configuration and execution problems with pgsql... not sure if I am
> missing something or if pgsql just cannot deal with being in the jail
> and sharing the sysv memory
>
> Attempting to manually start the postmaster produces the following:
>
> %postmaster -i
> IpcMemoryCreate: shmget failed (Function not implemented) key=5432010,
> size=144, permission=700
> This type of error is usually caused by an improper
> shared memory or System V IPC semaphore configuration.
> For more information, see the FAQ and platform-specific
> FAQ's in the source directory pgsql/doc or on our
> web site at http://www.postgresql.org.
> IpcMemoryIdGet: shmget failed (Function not implemented) key=5432010,
> size=144, permission=0
> IpcMemoryAttach: shmat failed (Function not implemented) id=-2
> FATAL 1: AttachSLockMemory: could not attach segment
> %
>
> Have modified the sysctl.conf file to allow usage of sysv memory, but
> as it is already shared from the host machine, this may be causing
> pgsql to barf on it.
>
> Searching for jail faq's and posts regarding this matter produces some
> close, but not helpful posts regarding chroot'ed environments.
>
> Any insights, requests for details, and assistance are appreciated.
>
> Dave
>
>
^ permalink raw reply [nested|flat] 6+ messages in thread
* RE: running pgsql 7 under Jail'ed virtual machine on FreeBSD 4.2
2001-01-04 22:04 running pgsql 7 under Jail'ed virtual machine on FreeBSD 4.2 Dave VanAuken <dave@hawk-systems.com>
2001-01-05 18:50 ` Re: running pgsql 7 under Jail'ed virtual machine on FreeBSD 4.2 Alex Pilosov <alex@pilosoft.com>
@ 2001-01-05 20:08 ` Dave VanAuken <dave@hawk-systems.com>
0 siblings, 0 replies; 6+ messages in thread
From: Dave VanAuken @ 2001-01-05 20:08 UTC (permalink / raw)
To: pgsql-general@postgresql.org
Knew about #1... and I'm not holding my breath for change gicing where
the development on that angle is heading.
In the installation directory for the jail i don't have the /storage
directory, or for that matter the ipc.h file anywhere in the pgsql
tree (both in the jail and host installations). The version installed
was 7.0.2
What about hacking supplimentary installations and hardcoding new
offsets for each subsequent installation of pgsql (can't even look
into that until i detemine where the ipc.h code now exists).
Appreciate the input... the best description so far from the pgsql
pov regarding the situation... have been working almost entirely from
the fbsd pov up until not and running out of options. May be a wash
for using pgsql in this situation.
Dave
-----Original Message-----
From: pgsql-general-owner@postgresql.org
[mailto:pgsql-general-owner@postgresql.org]On Behalf Of Alex Pilosov
Sent: Friday, January 05, 2001 1:50 PM
To: Dave VanAuken
Cc: pgsql-general@postgresql.org
Subject: Re: running pgsql 7 under Jail'ed virtual machine on FreeBSD
4.2
Here's the story about pgsql and jail:
1. FreeBSD shared memory is _really_ shared across all jail VMs. I
think
its not going to change, as this seems like a great way for processes
to
exchange data...But I could be wrong. :)
2. Postgres uses some funky math to determine which shmid to use for
different memory allocations it needs. The problem with that it has no
idea about jails and will not generate a different shmid for different
processes, so postgres processes end up stepping on each other's toes.
See include/storage/ipc.h, definition of SystemPortAddressGetIPCKey,
and
you'll understand what I mean.
To properly fix this, I think this should be done:
Another (optional) backend parameter which should determine offset
(hardcoded now to 17491) for allocation of different shmids...
comments? TODO?
On Thu, 4 Jan 2001, Dave VanAuken wrote:
> Have a FreeBSD 4.2 box... have created two Virtual machines with
the
> jail process.
> Apache and PHp configure and execute fine, but am having some
> configuration and execution problems with pgsql... not sure if I am
> missing something or if pgsql just cannot deal with being in the
jail
> and sharing the sysv memory
>
> Attempting to manually start the postmaster produces the following:
>
> %postmaster -i
> IpcMemoryCreate: shmget failed (Function not implemented)
key=5432010,
> size=144, permission=700
> This type of error is usually caused by an improper
> shared memory or System V IPC semaphore configuration.
> For more information, see the FAQ and platform-specific
> FAQ's in the source directory pgsql/doc or on our
> web site at http://www.postgresql.org.
> IpcMemoryIdGet: shmget failed (Function not implemented)
key=5432010,
> size=144, permission=0
> IpcMemoryAttach: shmat failed (Function not implemented) id=-2
> FATAL 1: AttachSLockMemory: could not attach segment
> %
>
> Have modified the sysctl.conf file to allow usage of sysv memory,
but
> as it is already shared from the host machine, this may be causing
> pgsql to barf on it.
>
> Searching for jail faq's and posts regarding this matter produces
some
> close, but not helpful posts regarding chroot'ed environments.
>
> Any insights, requests for details, and assistance are appreciated.
>
> Dave
>
>
^ permalink raw reply [nested|flat] 6+ messages in thread
end of thread, other threads:[~2001-01-05 20:08 UTC | newest]
Thread overview: 6+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2001-01-04 22:04 running pgsql 7 under Jail'ed virtual machine on FreeBSD 4.2 Dave VanAuken <dave@hawk-systems.com>
2001-01-05 01:41 ` Matt Beauregard <matt@designscape.com.au>
2001-01-05 04:30 ` The Hermit Hacker <scrappy@hub.org>
2001-01-05 14:11 ` Dave VanAuken <dave@hawk-systems.com>
2001-01-05 18:50 ` Alex Pilosov <alex@pilosoft.com>
2001-01-05 20:08 ` Dave VanAuken <dave@hawk-systems.com>
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox