From: dbs900@anu.edu.au (David Singleton)
Subject: Re: Process <-> Shared Memory
Date: 20 Mar 2001 08:22:50 +1000 [thread overview]
Message-ID: <3ab678aa$1@clarion.carno.net.au> (raw)
In-Reply-To: 3AB63FEF.D4896273@hotmail.com
In article <3AB63FEF.D4896273@hotmail.com>, Mario Stargard <mstargard@hotmail.com> writes:
|> ipcs -a tells you how many processes are attached (NATTCH) to the
|> shared memory segment, who the creating pid (CPID) was and the last pid
|> (LPID) to attach to the segment. This doesn't tell you the pids of the
|> currently attached processes, which is what I'm looking for.
|> Thanks, though.
|>
|> Mario
|>
Just to make it clear what Mario and I are after, /proc/pid/map under
Solaris returns an array of
typedef struct prmap {
uintptr_t pr_vaddr; /* virtual address of mapping */
size_t pr_size; /* size of mapping in bytes */
char pr_mapname[PRMAPSZ]; /* name in /proc/pid/object */
offset_t pr_offset; /* offset into mapped object, if any */
int pr_mflags; /* protection and attribute flags */
int pr_pagesize; /* pagesize for this mapping in bytes */
int pr_shmid; /* SysV shared memory identifier */
} prmap_t;
which conveniently gives the required info as the last component.
The only clue I have found is that the address in the corresponding struct
under Tru64 is very small - not something to rely on :^)
------
David.Singleton@anu.edu.au ANU Supercomputer Facility
Phone: +61 2 6125 4389 Australian National University
Fax: +61 2 6125 8199 Canberra, ACT, 0200, Australia
next prev parent reply other threads:[~2001-03-19 22:22 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2001-03-14 19:19 Process <-> Shared Memory Mario Stargard
2001-03-15 1:42 ` David Singleton
2001-03-16 17:39 ` Mario Stargard
2001-03-18 13:03 ` Vic Abell
2001-03-19 13:02 ` Jörg Bochert
2001-03-19 17:20 ` Mario Stargard
2001-03-19 22:22 ` David Singleton [this message]
2001-03-19 17:35 ` Serguei Patchkovskii
read-only archive
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox