nt size goesdown from ~200Mb to
> > ~100Mb. I also notices some relations to running acroread 7 with large PDF
> > files (which might also need shared memory for its operation). I had the
> > exact same problem on the same box when I was running FreeBSD 4.10 (which
> > I
ng acroread 7 with large PDF
> files (which might also need shared memory for its operation). I had the
> exact same problem on the same box when I was running FreeBSD 4.10 (which
> I attributed at first to a bad disk, which was replaced when I upgraded
> from 4.10 to 6.1).
Isn't
A few more points I forgot to mention. Nothing in /var/log/messages or
dmesg. I just tried opening acroread on a 5Mb file and started scrolling
fast in it. The machine froze at 18:37:26, the clock blipped at 18:39:25
and went back to normal at 18:41:35, which means over four minutes of
freeze.
. The vmware process resident size goes down from ~200Mb to
~100Mb. I also notices some relations to running acroread 7 with large PDF
files (which might also need shared memory for its operation). I had the
exact same problem on the same box when I was running FreeBSD 4.10 (which
I attributed at
On Tue, Aug 16, 2005 at 03:10:34PM +0200, Joost Bekkers wrote:
> On Tue, Aug 16, 2005 at 04:51:15PM +0400, Dmitry Agaphonov wrote:
> > Hello,
> >
> >
> > I have user A from group G creating shared memory M with permissions
> > 0060. After this, A fails to
On Tue, Aug 16, 2005 at 04:51:15PM +0400, Dmitry Agaphonov wrote:
> Hello,
>
>
> I have user A from group G creating shared memory M with permissions
> 0060. After this, A fails to attach M due to permission denied.
> However, another user B from the same group G successfully
Hello,
I have user A from group G creating shared memory M with permissions
0060. After this, A fails to attach M due to permission denied.
However, another user B from the same group G successfully attaches M.
User A manages to attach only if permissions 0600 added for M.
Why the system
On Fri, Aug 27, 2004 at 05:18:50PM +0200, Dmitry Karasik wrote:
> I've been playing with shared memory in jails, and very soon found
> out that one jail's segments are visible (didn't check the accesibility
> thoroughly) in another, which IMO is against the very idea
On 27 Aug 2004 Dmitry Karasik wrote:
>
> Hi hackers,
>
> I've been playing with shared memory in jails, and very soon found
> out that one jail's segments are visible (didn't check the accesibility
> thoroughly) in another, which IMO is against the very idea of t
Hi hackers,
I've been playing with shared memory in jails, and very soon found
out that one jail's segments are visible (didn't check the accesibility
thoroughly) in another, which IMO is against the very idea of the jail.
( The exact problem is that postgresqls, when run in ja
On Friday 29 August 2003 20:31, Lev Walkin wrote:
> zera holladay wrote:
> > When one uses the term "shared memory" while
> > discussing Unix, then what is generally the meaning of
> > that term? I have read that some Unixes have "shared
> > memory&q
zera holladay wrote:
When one uses the term "shared memory" while
discussing Unix, then what is generally the meaning of
that term? I have read that some Unixes have "shared
memory" for "shared objects."
However, I believe the term "shared memory"
When one uses the term "shared memory" while
discussing Unix, then what is generally the meaning of
that term? I have read that some Unixes have "shared
memory" for "shared objects."
However, I believe the term "shared memory" more
generically refers
> For that reason, when you mprotect an area of non-shared, anonymous
> memory to no access and then back to writable, Linux has no way of
> knowing that the memory wasn't set for COW before you make it
> unwritable. It goes ahead and makes all the pages in the area COW.
>
> That means that if I
Hi. I've noticed that in FreeBSD, the struct vm_map_entry has an
eflags member that can have the MAP_ENTRY_COW bit set.
In the vm_map_protect function, which is used by mprotect, it looks
like this bit is used to determine whether or not to set the page
table entries for write access or not:
"Luoqi Chen" <[EMAIL PROTECTED]> writes:
[Ed writes]
>> That means that if I do this:
>>
>> for (i = 0; i < n; ++i) {
>> assert(!mprotect(p, pgsiz, PROT_NONE));
>> assert(!mprotect(p, pgsiz, PROT_READ|PROT_WRITE|PROT_EXEC));
>> p[i] = i & 0xff;
>> }
>>
>> ... I get n mi
On Thu, Aug 07, 2003, Ed L Cashin wrote:
> "Luoqi Chen" <[EMAIL PROTECTED]> writes:
>
> [Ed writes]
> >> That means that if I do this:
> >>
> >> for (i = 0; i < n; ++i) {
> >> assert(!mprotect(p, pgsiz, PROT_NONE));
> >> assert(!mprotect(p, pgsiz, PROT_READ|PROT_WRITE|PROT_EXEC));
sw/mm/
If they're unrelated, you'll have to use SysV.
Charles
-Original Message-
From: fergus [mailto:[EMAIL PROTECTED]]
Sent: Saturday, August 18, 2001 4:57 AM
To: hackers
Subject: shared memory models/techniques
hope this is an ok place to post this.
as far as i can tell the
hope this is an ok place to post this.
as far as i can tell there are three ways to share memory between processes -
using mmap, ipc shared mem or skip it using threads instead.
is this right?
basically i have a server process accepting many connections & i was using
threads, however, it doesn'
FreeBSD 4+
I had something like 8192 processes in mind and same goes for max open files
I'd like 256M shared memory...
William Carlsson
Second Line Support
Teligent Nordic AB
P.O. Box 213
S-149 21 Nynäshamn
SWEDEN
Telephone: +4
On Fri, Dec 08, 2000 at 01:01:16PM +0100, William Carlsson - Teligent Nordic, AB -
Sweden wrote:
> Isn't all kern.* read only?
> Seems like it can't be changed more than it's in theory changeable
>
> Something like the maximum nuber of files and processes, that is suposed to
> be
> soft configur
Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]]On Behalf Of Mikko Tyolajarvi
Sent: den 7 december 2000 18:54
To: [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]
Subject: Re: Shared Memory
In local.freebsd.hackers you write:
>Could anyone enlighten me on how to set the amount of
In local.freebsd.hackers you write:
>Could anyone enlighten me on how to set the amount of shared memory?
If you mean the wretched System V IPCs, the parameters are in LINT.
Search for "SHM".
>I'd like that info for FreeBSD 2.2.2, 3.x, 4.x
The parameters only have descri
Could anyone enlighten me on how to set the amount of shared memory?
I'd like that info for FreeBSD 2.2.2, 3.x, 4.x
Thanks...
William Carlsson
Second Line Support
Teligent Nordic AB
P.O. Box 213
S-149 21 Nynäshamn
SWEDEN
Tele
et it run once a day, just as a little proactive
housekeeping.
For the record, here are the kernel options I use with this kernel:
options SYSVSHM #SYSV-style shared memory
options SYSVMSG #SYSV-style message queues
options SYSVSEM
ps one
> program is leaking?
SysV shared memory segments are defined to stick around until some
appropriately-privileged user process deletes them.
I was thinking recently that it might be nice to extend that API so a
process creating such a segment could ask the kernel to reference-count
it
t get
forgotten in the shadow of Perl.
However, it seems strange that you're getting non-attached memory
segments. Surely it is the job of the kernel to clean up after processes
(if they're badly programmed and don't do it themselves)? Perhaps one
program is leaking?
My system has bee
stake had been to think that the system was running out
of actual shared memory pages, but successive increases of the maximum
pages had no effect. The actual problem, as you've rightly pointed out,
was that each process was running out of shared memory segments...
Incidentally, how many pages doe
umber of shared segments per process.
> I'm currently running FreeBSD 4.0-RELEASE.
>
> Several questions;
>
> 1. If I upgrade to 4.1-STABLE (which I will be soon), will the shared
> memory issue disappear?
I have 5.0 and 4.1 machines with the same SHM* tuning above.
All work f
blem.
> >
>
>The same with me.
>
> >
> > I added
> >
> > options SHMMAXPGS=16385
> > options SHMMAX=(SHMMAXPGS*PAGE_SIZE+1)
> >
> > to my new kernel and recompiled.
> >
>
>I tried this without success.
>
> >
> > However,
have since
> tried several recompiles of the kernel to fix the problem.
>
The same with me.
>
> I added
>
> options SHMMAXPGS=16385
> options SHMMAX=(SHMMAXPGS*PAGE_SIZE+1)
>
> to my new kernel and recompiled.
>
I tried this without success.
>
> However, under
fix the problem.
I added
options SHMMAXPGS=16385
options SHMMAX=(SHMMAXPGS*PAGE_SIZE+1)
to my new kernel and recompiled.
However, under XFree86 4.0, I still seem to be getting shared memory
issues.
Compupic refuses to start under GNOME issuing
X Error of failed request: BadAccess (attem
On Wed, 16 Aug 2000, Peter Jeremy wrote:
> >Here's a simple test-and-set function for the 386 (tested and works):
> Actually, this isn't particularly good coding. It isn't SMP-safe.
you caught me! I'm a lousy assembly programmer!
Actually, that code is so old it predates SMP by a bit ...
Here's the kind of thing I have in mind, wrapped around the pthreads
mutexes. This replaces default pthread mutexes (those with no special
attributes) with possibly fast ones. I haven't done any real timing but
I've verified that a program I have works and runs a lot faster with
these wrappers.
way to ensure they are in a shared region without sharing
pages happening to contain mutexes with that attribute of the new
process space with the old one.
Assuming unique mutexes after a fork unless they happen to be in
a shared region, you could create a mutex in shared memory, apply
pthread_mut
On Tue, 15 Aug 2000 10:30:25 -0600 (MDT), Ronald G Minnich <[EMAIL PROTECTED]> wrote:
>The idea is simple: tset is the fastest, but you only want to spin so
>long. Then you want to drop into the kernel, and wait for someone to wake
>you up.
Agreed.
>Here's a simple test-and-set function for the
|> you can have a Linda-like pool of work requests to |hand out to a swarm of
| worker bees.
| ^^^
| Could you please decode this for me? :)
This page talks about Linda, check out the "Linda Basics" section and read about
tuples.
http://www.sca.com/ltutorial.html
Peter Dufault wrote:
> you can have a Linda-like pool of work requests to hand out to a swarm of worker
>bees.
^^^
Could you please decode this for me? :)
Thanks,
Gary
To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the bod
> On Tue, 15 Aug 2000, Jonas Bulow wrote:
>
> > After doing some more thinking about the cmpxchgl-lock, it's quite hard
> > to use it together with a technique involving the kernel.
>
> well, no I don't think it is. I used to use it a lot, see my earlier post
> from today.
One point to keep i
On Tue, 15 Aug 2000, Jonas Bulow wrote:
> After doing some more thinking about the cmpxchgl-lock, it's quite hard
> to use it together with a technique involving the kernel.
well, no I don't think it is. I used to use it a lot, see my earlier post
from today.
ron
To Unsubscribe: send mail
John Polstra wrote:
>
> In article <[EMAIL PROTECTED]>, Jonas Bulow
> <[EMAIL PROTECTED]> wrote:
> > John Polstra wrote:
> Actually I thought about this some more, and I'm not all that sure
> it's possible. I haven't actually _tried_ it, but I think you'd end
> up needing a low-level mutex aroun
OK, here's a note from long ago, when this came up before.
Dated: Tue Jul 2 10:48:16 1996
The idea is simple: tset is the fastest, but you only want to spin so
long. Then you want to drop into the kernel, and wait for someone to wake
you up. This thing was quite fast on freebsd, even four year
In article <[EMAIL PROTECTED]>, Jonas Bulow
<[EMAIL PROTECTED]> wrote:
> John Polstra wrote:
>
> > I think the ideal solution would first try to lock the
> > test-and-set lock, maybe spinning on it just a few times. If that
> > failed it would fall back to using a system-call lock such as
> > flo
John Polstra wrote:
> Jonas Bulow wrote
> > Maybe I havn't been thinking enough but wouldn't this lock mechanism
> > be a good choice to use for mmaped:memory accessed by multiple
> > processes?
>
> It depends on the amount of contention you expect. The code in
> lockdflt.c was designed for a ve
Wes Peters wrote:
>
> Jonas Bulow wrote:
> >
> > Ronald G Minnich wrote:
> > >
> > > I don't know about the "bsd" or whatever way. If you're doing real
> > > parallel programming and want real performance, you'll use a test-and-set
> > > like function that uses the low-level machine instructions
> > > I don't know about the "bsd" or whatever way. If you're doing real
> > > parallel programming and want real performance, you'll use a test-and-set
> > > like function that uses the low-level machine instructions for same.
> >
> > That is exacly what I'm looking for! I found it to be overkil
Jonas Bulow wrote:
>
> Ronald G Minnich wrote:
> >
> > I don't know about the "bsd" or whatever way. If you're doing real
> > parallel programming and want real performance, you'll use a test-and-set
> > like function that uses the low-level machine instructions for same.
>
> That is exacly what
On Sat, 12 Aug 2000, Jonas Bulow wrote:
> John Polstra wrote:
> > If you want the "BSD way" you should probably create a 0-length
> > temporary file somewhere and use the flock(2) system call on it. The
> > file itself isn't important; it's just something to lock.
>
> I don't see any reason to
In article <[EMAIL PROTECTED]>,
Jonas Bulow <[EMAIL PROTECTED]> wrote:
> John Polstra wrote:
> > If you want the "BSD way" you should probably create a 0-length
> > temporary file somewhere and use the flock(2) system call on it. The
> > file itself isn't important; it's just something to lock.
John Polstra wrote:
> If you want the "BSD way" you should probably create a 0-length
> temporary file somewhere and use the flock(2) system call on it. The
> file itself isn't important; it's just something to lock.
I don't see any reason to do system calls just because I want to do an
atomic o
Ronald G Minnich wrote:
> On Fri, 11 Aug 2000, John Polstra wrote:
> > In article <[EMAIL PROTECTED]>,
> > Jonas Bulow <[EMAIL PROTECTED]> wrote:
> > > Jonas Bulow wrote:
> > > >
> > > > What is the "BSD-way" of access to shar
On Fri, 11 Aug 2000, John Polstra wrote:
> In article <[EMAIL PROTECTED]>,
> Jonas Bulow <[EMAIL PROTECTED]> wrote:
> > Jonas Bulow wrote:
> > >
> > > What is the "BSD-way" of access to shared memory (mmap:ed) secure (avoid
> > > ra
In article <[EMAIL PROTECTED]>,
Jonas Bulow <[EMAIL PROTECTED]> wrote:
> Jonas Bulow wrote:
> >
> > What is the "BSD-way" of access to shared memory (mmap:ed) secure (avoid
> > race conditions, etc)? Right now I'm using posix semaphores but I woul
Jonas Bulow wrote:
>
> What is the "BSD-way" of access to shared memory (mmap:ed) secure (avoid
> race conditions, etc)? Right now I'm using posix semaphores but I would
> like to know if there is a substitute like the way kqueue is for
> select/poll.
Hmm, I thi
What is the "BSD-way" of access to shared memory (mmap:ed) secure (avoid
race conditions, etc)? Right now I'm using posix semaphores but I would
like to know if there is a substitute like the way kqueue is for
select/poll.
To Unsubscribe: send mail to [EMAIL PROTECTED]
with "
Please help me with the simple 'Shared Memory' example.. I cant use fork, many
different
applications may speaking to one 'server' application..
This small function can run as the memory server (pass bogus parameters) and as a
client
in another terminal (dont pass any pa
On Mon, Feb 28, 2000 at 12:50:13PM -0800, Brooks Davis wrote:
> On a -current system as of a week or two ago (as well as a 3.3-RC and a
> 2.2.8-STABLE box) I've found that mprotect fails with with EACCES when
> trying to make a shared memory segment that was created user read/wri
The mprotect manual page on Digital Unix specifies that it conforms to the
XPG4-UNIX standard.
Charles
To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message
when
> > trying to make a shared memory segment that was created user read/write
> > read-only. It works find if I malloc the memory instead and making the
> > shm segment write-only or inaccessible works fine as well. Is this
> > expected behavior? If so it'
* Brooks Davis <[EMAIL PROTECTED]> [000228 13:23] wrote:
> On a -current system as of a week or two ago (as well as a 3.3-RC and a
> 2.2.8-STABLE box) I've found that mprotect fails with with EACCES when
> trying to make a shared memory segment that was created user read/wr
On a -current system as of a week or two ago (as well as a 3.3-RC and a
2.2.8-STABLE box) I've found that mprotect fails with with EACCES when
trying to make a shared memory segment that was created user read/write
read-only. It works find if I malloc the memory instead and making th
To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message
don't use shmget if you can. Use mmap'ed files. The SYSV shm interface is
incredibly dumb.
ron
To Unsubscribe: send mail to majord...@freebsd.org
with "unsubscribe freebsd-hackers" in the body of the message
don't use shmget if you can. Use mmap'ed files. The SYSV shm interface is
incredibly dumb.
ron
To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message
:I've been learning to program using shared memory and messages. As I write
:and debug, I often have to crash a running process which stalls. Of
:course, there is a problem with my code but that's all part of the
:learning process. The actual problem is that, after a few ctrl-c'
I've been learning to program using shared memory and messages. As I write
and debug, I often have to crash a running process which stalls. Of
course, there is a problem with my code but that's all part of the
learning process. The actual problem is that, after a few ctrl-c's, the
:I've been learning to program using shared memory and messages. As I write
:and debug, I often have to crash a running process which stalls. Of
:course, there is a problem with my code but that's all part of the
:learning process. The actual problem is that, after a few ctrl-c'
I've been learning to program using shared memory and messages. As I write
and debug, I often have to crash a running process which stalls. Of
course, there is a problem with my code but that's all part of the
learning process. The actual problem is that, after a few ctrl-c's, the
68 matches
Mail list logo