On Tue, 16 Mar 2010, Milan Obuch wrote:

On Tuesday 16 March 2010 14:55:43 Milan Obuch wrote:

some time ago I built a multi network monitor using older version with
Marko Zec's vimage patch. I am trying to port it to 8-STABLE (newer
features, easier maintenance...) with partial success.

Basically, I use shared memory as common data area across more vimages in
order to be able to generate quick summaries from in-memory data. I was not
able to get it running under freshly compiler 8-STABLE, error message is

shmget: Function not implemented

Has anybody any idea? Patch to test to enable use of shared memory in vnet


Forget to add...

In my code, I use

if ((shmid = shmget(shmkey,sizeof(mdc),IPC_CREAT | 0640)) == -1)

to create a shared segment and

if ((shmid = shmget(shmkey,sizeof(mdc),0)) == -1)

to get an id for already created segment.

Both are failing under non-root vimage jail, but it works under main host. At
first I thought shared memory is not yet virtualized, but ipcs display
existing segments in both root/main host and vnet jail.ipcrm, however, works
only in non-jailed host...

ipcrm: shmid(131072): : Function not implemented

if you create a jail with a vnet you want to give it
        jail - i -c vnet allow.sysvipc ..

and then things should start to work at leat in the non-virtualized
way (global namespace across all jails).


Bjoern A. Zeeb         It will not break if you know what you are doing.
freebsd-virtualization@freebsd.org mailing list
To unsubscribe, send any mail to 

Reply via email to