Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 07 Jul 2003 02:48:41 +0200
From:      Marcin Dalecki <mdcki@gmx.net>
To:        dickey@herndon4.his.com
Cc:        current@freebsd.org
Subject:   Re: /dev/shm
Message-ID:  <3F08C369.8080207@gmx.net>
In-Reply-To: <20030707001443.GA1530@invisible-island.net>
References:  <3F08B199.3050409@comcast.net> <3F08B79B.2040805@gmx.net> <20030707001443.GA1530@invisible-island.net>

index | next in thread | previous in thread | raw e-mail

Thomas Dickey wrote:
> On Mon, Jul 07, 2003 at 01:58:19AM +0200, Marcin Dalecki wrote:
> 
>>Myron J. Mayfield wrote:
>>
>>>I attempted to install the linux java sapgui on FreeBSD 5.0, but the jar
>>>file only unpacked part of it.  I then copied the files from my Redhat 9
>>>machine.  I linked up all the linux libraries needed and attempted to
>>>start it.  It gives me an error saying cant find /dev/shm.  I tried
>>>adding this to /dev but was unable to.  Does anyone have any
>>>information?  Thank you.  I am somewhat new to FreeBSD but have used
>>>linux for Many years.
>>
>>For some unexcused reason there is the trend in Linux to represent
>>everything as kind of a wired half finished pseudo file system. /proc pipe
>>devicefs sysctl and so on... The list is really long. Even shared memmory is
>>mapped to  ehrm.... a filesystem. This is "expected" to be mounted at 
>>/dev/shm by the system. You can't expect FreeBSD to follow this path...
> 
> 
> Linux isn't the only system that does this (learn a little, criticize less).

There is a great span between everything and some things where it makes sense.
Just please compare the devfs *implementations* between FreeBSD and Linux
to see the difference.

Some examples:

/etc/rc.d/init.d# cat /proc/meminfo
         total:    used:    free:  shared: buffers:  cached:
Mem:  526184448 515764224 10420224        0 43528192 353251328
Swap: 536862720        0 536862720
MemTotal:       513852 kB
MemFree:         10176 kB
MemShared:           0 kB
Buffers:         42508 kB
Cached:         344972 kB
SwapCached:          0 kB
Active:         332328 kB
ActiveAnon:      79088 kB
ActiveCache:    253240 kB
Inact_dirty:      8932 kB
Inact_laundry:       0 kB
Inact_clean:    125308 kB
Inact_target:    93312 kB
HighTotal:           0 kB
HighFree:            0 kB
LowTotal:       513852 kB
LowFree:         10176 kB
SwapTotal:      524280 kB
SwapFree:       524280 kB
/etc/rc.d/init.d#

Wonderfull well tought out conscise and dense design isn't it?

Or maybe:
/etc/rc.d/init.d# cat /proc/filesystems
nodev   rootfs
nodev   bdev
nodev   proc
nodev   sockfs
nodev   tmpfs
nodev   shm
nodev   pipefs
         ext2
nodev   ramfs
         iso9660
nodev   devpts
         ext3
nodev   usbdevfs
nodev   usbfs
nodev   binfmt_misc
/etc/rc.d/init.d#

And this is 2.4 kernel not the "upcomming" 2.6

Oh and I know well about the motivation behing /dev/shm - the excuse is called
"POSIX shm semantics". Which are broken in first place and never got over the
"standard" draft state.


help

Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?3F08C369.8080207>