bugmonotone - Bugs: bug #12455, MT 0.16 can't access, if DB stored...

 
 

You are not allowed to post comments on this tracker with your current authentication level.

bug #12455: MT 0.16 can't access, if DB stored on NFS

Submitter:  Henry Nestler <henryn>
Submitted:  Thu 24 Mar 2005 09:50:26 PM UTC
   
 
Category:  networking Severity:  3 - Normal
Item Group:  incorrect behavior Status:  Wont Fix
Privacy:  Public Assigned to:  stephen_leake
Open/Closed:  Closed
mtn version --full: 

monotone 0.16 (base revision: ce860bae312c4bb8483d5b3b2a8cd3bebe2323d5)

(A self compiled full static version.)

Jump to the original submission

Sat 08 May 2010 08:48:17 PM UTC, comment #6: 

Since this is a problem with the NFS filesystem not providing locking, I don't think mtn can do anything about it.

Stephen Leake <stephen_leake>
Group Member
Tue 14 Jun 2005 04:42:28 PM UTC, comment #5: 

This are the interesting commands without rpc.lockd:

> strace monotone --db=test.db db init 2>mt-strace-nolock.txt

monotone: fatal: std::runtime_error: sqlite exec error database is locked
monotone: this is almost certainly a bug in monotone.
monotone: please send this error message, the output of 'monotone --full-version',
monotone: and a description of what you were doing to monotone-devel@nongnu.org.
monotone: discarding debug log (maybe you want --debug or --dump?)

> cat mt-strace-nolock.txt | grep ENOLCK

fcntl64(3, F_SETLK64, {type=F_RDLCK, whence=SEEK_SET, start=1073741824, len=1}, 0xbfffe280) = -1 ENOLCK (No locks available)

> man fcntl | grep ENOLCK

 ENOLCK Too  many  segment  locks open, lock table is full, or a remote locking
        protocol failed (e.g. locking over NFS).

> monotone --full-version

monotone 0.19 (base revision: 168adf9537ff136c9b7fe7faad5991f92859390d)
Running on: Linux 2.4.21-99-default #1 Wed Sep 24 13:30:51 UTC 2003 i686
Changes since base revision:

new_manifest [a9ee1d741b855fdcc0d038d64d913cef70da72f5]

old_revision [168adf9537ff136c9b7fe7faad5991f92859390d]
old_manifest [a9ee1d741b855fdcc0d038d64d913cef70da72f5]


Henry Nestler <henryn>
Tue 14 Jun 2005 04:16:41 PM UTC, comment #4: 

Found error on nfs mount: Have no file locking on nfs.
If I run rpc.statd and rpc.lockd, monotone runs perfect.

Ok, this can be enable for a NFS mounted filesystem.
But, what can I do, if the filesystem don't support file locking, such my cofs (a fuse implementation)?

I'm liddle be wounder.  You not allow to run more as one monotone on the same database, but you lock every access to DB with three locking operations (lock 1 byte, lock a block 510 bytes, unlock first byte)?  Why not locking cmplete file?  I means only on local filesystem.  For server mode is an other situation.

The strace give some more interesting outputs about your bad performance on local filesystem.  You write to db.jurnal and execute a sync to db.jurnal and the currect directory with a complete open close of directory.  For server mode this all is very good for stable data.  For client this is an overkill if downloding a big database.

You should perhaps implement diffent accesses to DB file, if MT running as server or client?  A local running MT not need all the locking and sync stuff.  Here I wish more speed.  If any user not trust the filesystem or storage, can mount it with "-o sync".

A good option could be a command line argument to disable locking and sync or both.  This would also incrase the speed.

Output from strace for a "monotone --db=test.db db init" on NFS have attached as file.

Henry Nestler <henryn>
Fri 03 Jun 2005 10:16:24 PM UTC, comment #3: 

Yes, have access rigts for create, read and write files and directories, and else to create new files under self created diretories.  I'm work on this NFS server as user, can compile on this.  ;-)

The specific comparsion between NFS and COFS is the mount, that user-id is set by mount "uid=500,gid=100".

I will try again with /strace/. Please wait.

Henry Nestler <henryn>
Sat 28 May 2005 02:46:27 AM UTC, comment #2: 

Do you have sufficient permissions to create new files in the same directory as the monotone database, and write to them?  Because monotone requires that.

(Really, sqlite requires that; if you open a database "foo.db", it creates a temporary file "foo.db-journal" to record what it's doing, so rollback works.)

Anonymous
Fri 27 May 2005 12:36:24 PM UTC, comment #1: 

Same error on MT version 0.19

Only problem is write access to DB.  Cofs is a fuse-lite filesystem with limited access rights.  User have full read/write access to this fs. Can read/write/copy/edit any files on cofs.
A "monotone update" or "checkout" works.


hn@hn-lt:~/Monotone/work> monotone commit

enter passphrase for key ID [henry@bigfoot.de]:*********

monotone: committed revision 8e3f6983bda8e4300d5ed63f15c3c489a962914c
monotone: fatal: std::runtime_error: sqlite exec error disk I/O error

Henry Nestler <henryn>
Thu 24 Mar 2005 09:50:26 PM UTC, original submission:  

All actions on nfs mounted DB give same error. Here I list only a "db init".
On NFS have normal user read/write access.
I'm the only one to access the DB file. As work a round I copy DB local, do something and copy back to server.

$ monotone --db=nfs-test.db db init
monotone: discarding debug log
monotone: fatal: std::runtime_error: sqlite exec error database is locked
monotone: this is almost certainly a bug in monotone.
monotone: please send this error message, the output of 'monotone --full-version',
monotone: and a description of what you were doing to monotone-devel@nongnu.org.



Henry Nestler <henryn>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attached Files
file #3090:  mt-strace-lock.txt added by henryn (47KiB - text/plain - rpc.lockd runs, MT runs. See the lot of lock and sync here)
file #3089:  mt-strace-nolock.txt added by henryn (7KiB - text/plain - failed, because rpc.lockd not runs)
file #3010:  commit_on_cofs.txt added by henryn (2KiB - text/plain - error output, MT/debug, mounts)
file #2785:  mt016-on-nfs.txt added by henryn (3KiB - text/plain - Full error list debug output, mounts)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by stephen_leake (Posted a comment)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

     

    Follow 8 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2010-05-10 stephen_leake Open/ClosedIn Test Closed
    2010-05-08 stephen_leake StatusNone Wont Fix
        Assigned toNone stephen_leake
        Open/ClosedOpen In Test
    2005-06-14 henryn Attached File- Added mt-strace-lock.txt, #2608
    2005-06-14 henryn Attached File- Added mt-strace-nolock.txt, #2607
    2005-05-27 henryn Attached File- Added commit_on_cofs.txt, #2547
    2005-03-24 henryn Attached File- Added mt016-on-nfs.txt, #2352

    Back to the top

    Powered by Savane 3.13-bb6a.
    Corresponding source code