Skip to contentSkip to conversation

SHM Not working in 2.4.0-prerelease

DISCUSSION Shawn Starr 4 participants 5 messages Jan 3, 2001 – Jan 4, 2001

lore
Share & tools
lore
#0 lore raw

I have created the shm directory in /dev

drwxrwxrwt 1 root root 0 Jan 3 09:51 shm/

in my fstab i have:

shmfs /dev/shm shm defaults 0 0

when I display with top:

Mem: 62496K av, 61248K used, 1248K free, 0K shrd, 1868K
buff
Swap: 64252K av, 20016K used, 44236K free 27900K
cached

[spstarr@coredump /etc]$ free
total used free shared buffers
cached
Mem: 62496 61264 1232 0 1248
28848

There's no shared memory being used?

mount
...
shmfs on /dev/shm type shm (rw)

the shmfs is mounted. Is there any configuration i need to get shm memory activiated?

Thanks,

Shawn Starr.

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [email protected]
Please read the FAQ at http://www.tux.org/lkml/

#1 lore raw
Quoted 8 lines · Shawn Starr

[spstarr@coredump /etc]$ free
total used free shared buffers
cached
Mem: 62496 61264 1232 0 1248
28848

There's no shared memory being used?

[...]

Quoted 2 lines

the shmfs is mounted. Is there any configuration i need to get shm memory activiated?

The 'shared' field in /proc/meminfo (source for 'top' and 'free') has nothing to do with {SysV,POSIX} shared memory. The 'shared' field referred to memory that was used by more than one process (shared libraries, shared text segments etc). As I understand it, under 2.4 the 'shared' field is very expensive to calculate, so we don't--the zero value is there to avoid breaking programs that parse /proc/meminfo.

-Doug
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [email protected]
Please read the FAQ at http://www.tux.org/lkml/

#2 lore raw
Quoted 2 lines
Quoted 2 lines

[spstarr@coredump /etc]$ free
total used free shared buffers

...

Quoted 5 lines
Quoted 2 lines

the shmfs is mounted. Is there any configuration i need to get shm memory activiated?

The 'shared' field in /proc/meminfo (source for 'top' and 'free') has nothing to do with {SysV,POSIX} shared memory.

Hey, that would be a good use for the field.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [email protected]
Please read the FAQ at http://www.tux.org/lkml/

#3 lore raw
Quoted 10 lines · Albert D. Cahalan
Quoted 2 lines
Quoted 2 lines

[spstarr@coredump /etc]$ free
total used free shared buffers

...

Quoted 5 lines
Quoted 2 lines

the shmfs is mounted. Is there any configuration i need to get shm memory activiated?

The 'shared' field in /proc/meminfo (source for 'top' and 'free') has nothing to do with {SysV,POSIX} shared memory.

Hey, that would be a good use for the field.

Not a bad idea. Then we could tell free etc to subtract this from the +/- cached free numbers...

I will look into this.

Christoph

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [email protected]
Please read the FAQ at http://www.tux.org/lkml/

#4 lore raw
In reply to Shawn Starr

ahh ok, so everythings fine then. It would be nice though to see that value perhaps in future they'll be a way.

Thanks,

Shawn.

Quoted 24 lines · Doug McNaught
Quoted 8 lines · Shawn Starr

[spstarr@coredump /etc]$ free
total used free shared buffers
cached
Mem: 62496 61264 1232 0 1248
28848

There's no shared memory being used?

[...]

Quoted 2 lines

the shmfs is mounted. Is there any configuration i need to get shm memory activiated?

The 'shared' field in /proc/meminfo (source for 'top' and 'free') has nothing to do with {SysV,POSIX} shared memory. The 'shared' field referred to memory that was used by more than one process (shared libraries, shared text segments etc). As I understand it, under 2.4 the 'shared' field is very expensive to calculate, so we don't--the zero value is there to avoid breaking programs that parse /proc/meminfo.

Quoted 1 line

-Doug

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [email protected]
Please read the FAQ at http://www.tux.org/lkml/