home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.lang.perl
- Path: sparky!uunet!usc!rpi!batcomputer!cornell!uw-beaver!fluke!gtisqr!roger
- From: roger@mav.com (Roger Droz)
- Subject: Re: Any portable way to get round...
- Message-ID: <1992Aug18.185755.21870@mav.com>
- Summary: gdbm has fewer arbitrary limits, but has multi-user restrictions.
- Organization: Maverick International Inc.
- References: <1992Aug9.204433.13995@news.uit.no> <ASHERMAN.92Aug10125542@laser.fmrco.com>
- Date: Tue, 18 Aug 92 18:57:55 GMT
- Lines: 43
-
- In article <ASHERMAN.92Aug10125542@laser.fmrco.com>
- asherman@laser.fmrco.com (Aaron Sherman) writes:
- >>>>>> tomg@stud.cs.uit.no (Tom Grydeland) said:
- >tomg> Subject: Any portable way to get round...
- >tomg> ...the limitation of one block per key/value pair and all
- >tomg> key/value pairs that hash together? I want to use the dbm/ndbm
- >tomg> format [...]
- >
- >Try linking perl with gdbm. I don't know that this will help, but in
- >general the GNU folks have been good about eliminating arbitrary
- >limitations.
-
- gdbm is a disk space win. It uses an extensible hashing technique
- that does create sparse (in the unix sense) files. More blocks are
- allocated as needed to spread things out when too many keys hask
- together.
-
- The downside of gdbm is that it doesn't permit concurrent writers or a
- writer to co-exist with a reader.
-
- Perl dbmopen first trys to open the database for read/write. Failing
- that, the dbmopen is retried for read-only access. dbmopen succeeds
- in either case.
-
- When gdbm is linked into perl, the second opener fails because the
- first opener was granted exclusive access to the database
- (whether he wanted to write or not). I hacked our perl to pay
- attention to the mode argument when opening existing databases. Thus
- our perl supports concurrent readers of gdm databases.
-
- Does anyone have the way of supporting concurrent writers of gdm
- databases? Do dbm/ndbm support concurrent writers?
-
- (Email me a copy of replies you post. Our newsfeed hasn't been reliable
- lately.)
- ____________
- Roger Droz Domain: roger@mav.COM
- () () Maverick International UUCP: uw-beaver!gtisqr!roger
- (_______) 8217 44th Ave West Bell: (206) 743-6659
- ( ) Mukilteo, WA 98275
- | | "We're all mavericks here:
- | | Each of us has our own opinions,
- (___) and the company has yet different ones!"
-