[prev in list] [next in list] [prev in thread] [next in thread]
List: sqlite-dev
Subject: Re: [sqlite-dev] sqlite3OsSync() not called issue in WAL
From: Dan Kennedy <danielk1977 () gmail ! com>
Date: 2016-05-24 16:34:32
Message-ID: 57448298.10702 () gmail ! com
[Download RAW message or body]
On 05/24/2016 12:59 PM, Yongil Jang wrote:
> If 84 frames are written with 1KB page size, issue will be happen.
Thanks for reporting this. Now fixed here:
http://sqlite.org/src/info/37de3eab67f12ae1
How did you discover this problem?
Dan.
>
> 2016년 5월 24일 (화) 10:22, Yongil Jang <yongiljang@gmail.com
> <mailto:yongiljang@gmail.com>> 님이 작성:
>
> In sqlite3WalFrames(),
> following block will try to add padding frames to prevent
> powersafe_overwrite issue.
>
> if( isCommit && (sync_flags & WAL_SYNC_TRANSACTIONS)!=0 ){
> if( pWal->padToSectorBoundary ){
> int sectorSize = sqlite3SectorSize(pWal->pWalFd);
> w.iSyncPoint = ((iOffset+sectorSize-1)/sectorSize)*sectorSize;
> while( iOffset<w.iSyncPoint ){
> rc = walWriteOneFrame(&w, pLast, nTruncate, iOffset);
> if( rc ) return rc;
> iOffset += szFrame;
> nExtra++;
> }
> }else{
> rc = sqlite3OsSync(w.pFd, sync_flags & SQLITE_SYNC_MASK);
> }
> }
>
> But, if iOffset equals to w.iSyncPoint then sqlite3OsSync() is not
> called.
>
>
>
> _______________________________________________
> sqlite-dev mailing list
> sqlite-dev@mailinglists.sqlite.org
> http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-dev
_______________________________________________
sqlite-dev mailing list
sqlite-dev@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-dev
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic