On AIX, you might want to open the files using O_DSYNC flag: (see)
http://publibn.boulder.ibm.com/doc_link/en_US/a_doc_lib/libs/basetrf1/open.htm#HDRA1509805
Test results:
Opening for rdonly
kwrite(1, 0xF0373B18, 19) = 19
open("/home/ixion/T", O_RDONLY|O_LARGEFILE) = 3
fsync(3) Err#9 EBADF
close(3) = 0
Opening for rdw
kwrite(1, 0xF0373B18, 16) = 16
open("/home/ixion/T", O_RDWR|O_LARGEFILE) Err#21 EISDIR
close(-1) Err#9 EBADF
kfcntl(1, F_GETFL, 0x20000BC8) = 2
kfcntl(2, F_GETFL, 0xF0373B18) = 2
Dan,
If you want any other quick tests cases run, let me know and I'll put them
together.
Thanks,
Ken
Ken <[EMAIL PROTECTED]> wrote: Dan,
I'll test this with a quick bit of C code and get back to you with the truss
output.
Good catch Roger! ( and thanks)
Thanks,
Ken
Dan wrote:
On Jul 15, 2008, at 9:00 AM, Roger Binns wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> Ken wrote:
>
>> open("/home/ixion/ix_propagator/data/db/ajax102/batch", O_RDONLY|
>> O_LARGEFILE) = 10
>> kfcntl(10, F_GETFD, 0x00000000) = 0
>> kfcntl(10, F_SETFD, 0x00000001) = 0
>> fsync(10) Err#9 EBADF
>
> My best guess is that the call is rejected is because the directory
> was
> not opened for writing.
> http://publibn.boulder.ibm.com/doc_link/en_US/a_doc_lib/libs/
> basetrf1/fsync.htm
>
> In the error code section:
>
> EBADF The FileDescriptor parameter is not a valid file descriptor
> open
> for writing.
>
> (I doubt there is an modern UNIX that does allow opening
> directories for
> write though).
Ah... Quite possibly. In os_unix.c directories are opened with:
fd = open(zDirname, O_RDONLY|O_BINARY, 0);
_______________________________________________
sqlite-users mailing list
[email protected]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
_______________________________________________
sqlite-users mailing list
[email protected]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
Ken <[EMAIL PROTECTED]> wrote: Dan,
I'll test this with a quick bit of C code and get back to you with the truss
output.
Good catch Roger! ( and thanks)
Thanks,
Ken
Dan wrote:
On Jul 15, 2008, at 9:00 AM, Roger Binns wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> Ken wrote:
>
>> open("/home/ixion/ix_propagator/data/db/ajax102/batch", O_RDONLY|
>> O_LARGEFILE) = 10
>> kfcntl(10, F_GETFD, 0x00000000) = 0
>> kfcntl(10, F_SETFD, 0x00000001) = 0
>> fsync(10) Err#9 EBADF
>
> My best guess is that the call is rejected is because the directory
> was
> not opened for writing.
> http://publibn.boulder.ibm.com/doc_link/en_US/a_doc_lib/libs/
> basetrf1/fsync.htm
>
> In the error code section:
>
> EBADF The FileDescriptor parameter is not a valid file descriptor
> open
> for writing.
>
> (I doubt there is an modern UNIX that does allow opening
> directories for
> write though).
Ah... Quite possibly. In os_unix.c directories are opened with:
fd = open(zDirname, O_RDONLY|O_BINARY, 0);
_______________________________________________
sqlite-users mailing list
[email protected]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
_______________________________________________
sqlite-users mailing list
[email protected]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
_______________________________________________
sqlite-users mailing list
[email protected]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users