PostgreSQL (7.3) on SMB/CIFS Shares on FreeBSD 5.1

From: "Rob Oakley" <robo(at)pobox(dot)com>
To: <pgsql-hackers(at)postgresql(dot)org>
Subject: PostgreSQL (7.3) on SMB/CIFS Shares on FreeBSD 5.1
Date: 2004-04-21 19:59:09
Message-ID: 20040421195909.88F11D1B579@svr1.postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

[Previously posted to General list]

I have an embedded system running FreeBSD (5.1) that does not have any local
(rotating) storage (i.e. disk drives).

PostgreSQL (7.3.2.1) also runs on this box and (at this point) has two
tables. It is an extremely simple PostgreSQL configuration with the tables
having less than 20 fields each, and no relations between the tables.

However, because there isn't any (substantial) local storage available on
the Compact Flash, and the tables have the potential to grow fairly large;
Windows-based shares are being used (via PostgreSQL's 'initlocation') as the
backing store for the tables.

Moreover, setting the system up consisted of:
1. Setting and exporting PGDATA2=/var/nsg/dbNSG in ~/.profile
2. mount_smbfs <user(at)server/share> /var/nsg/dbNSG
3. initdb (default location (/usr/local/pgsql/data) (on the flash))
4. start PostgreSQL
5. createuser -A -D nsg
6. initlocation -D PGDATA2
7. createdb -D PGDATA2 -O nsg nsg
8. (create tables)

This all completes successfully, the problems begin while attempting to
populate the tables. It seems that attempts to add specific records causes
my C/libpq application to forever block on 'postgres'. My app is blocked on
select(2) (via pg_exec('INSERT...')) and PostgreSQL is blocked on a
semaphore. And for the record, the application and PostgreSQL perform
flawlessly if step 2 (above) is skipped. In other words, there seems to be
problem when SMB/CIFS is layered in.

Does anyone have any information that might shed a little light?

Anyone use SMB/CIFS as the backing store for PostgreSQL?

Is there possible locking/deadlocking problems associated with using a
SMB/CIFS supporting PostgreSQL.

Thanks in advance!
robo

Attachment Content-Type Size
winmail.dat application/ms-tnef 2.7 KB

Browse pgsql-hackers by date

  From Date Subject
Next Message scott.marlowe 2004-04-21 20:03:00 Re: contrib vs. gborg/pgfoundry for replication solutions
Previous Message Tom Lane 2004-04-21 19:49:06 Re: contrib vs. gborg/pgfoundry for replication solutions