sqlite 2.8, HP-UX, Linux NFS server

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

sqlite 2.8, HP-UX, Linux NFS server

b s-2
Hi,
I am trying the following program and it fails with 'database is locked'. I
have set the 'insecure_locks' option in /etc/exports of the NFS server (RH 7.3,
2.4.18-3 kernel).
It only fails for HP-UX clients (11iv1 aka 11.11).
Anybody has success with this combo?

thanks
bal

#include <stdio.h>
#include <sqlite.h>

char *schema = "create table foo (bar varchar(20));";
int main()
{
    sqlite *db;
    char *errmsg=NULL;
    char *dbname = "testdb";
    if (NULL == (db = sqlite_open(dbname, 0, &errmsg))) {
        fprintf(stderr, "Error opening %s err: %s\n", dbname, errmsg);
        return 1;
    }

    if (SQLITE_OK != sqlite_exec(db, schema, NULL, NULL, &errmsg)) {
        fprintf(stderr, "Error creating %s err: %s\n", dbname, errmsg);
        sqlite_close(db);
        //unlink(dbname);
        return 1;
    }

    sqlite_close(db);
    return 0;
}



               
__________________________________________
Yahoo! DSL – Something to write home about.
Just $16.99/mo. or less.
dsl.yahoo.com