LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 10-22-2016, 07:47 PM   #1
didiw
Member
 
Registered: Oct 2009
Posts: 30

Rep: Reputation: 0
nfsv4 gives "No locks available"



Hello,
I keep getting the error message "No locks available" on my Linux clients, when running Firefox or calibre (E-Book-Reader), just to name two programs.
  • In Firefpx this has the effect, that nothing seems to be remebered, no cookies, no bookmarks, no history, no passwords. I even cannot download any file, because the location selection window does not open after I select save to file in the save option windows.
  • Calibre just does not start, because it cannot lock its config file.
  • Even the command flock -x ./test -c "sleep 60" utters the error message "No locks available.
  • Interestingly, thunderbird runs fine without any noticable problem.

I think, the firefox problem is just related to sqlite not being able to lock its files, because, when I start sqlite3 wtth a db from firefox (no firefox running) it does not even gives me an output on the .tables command.

I recently changed from NFSv3 to NFSv4 and this is, when it started. With nfsv3 locking worked for all those programs.

The nfs-server is running opensuse 13.1 and nfs-kernel-server-1.2.8-4.17.1.x86_64, one client is running opensuse 42.1 and nfs-client-1.3.0-23.1.x86_64, a second client is running opensuse 13.1 too, but in cannot currently get the nfs client version, because I cannot switch it on currently.

Client logs show just this error message (No locks available), nothing else related to nfs after mounts. Server does not show any error logs except lockd: cannot monitor <client>, but this is just a nfsv3 error message, afaik.

Is there anything I can do to get the locks working? They should be working, since NFSv4 has locking incorporated into its protocol.

BTW. I use NFSv4 at work with opensuse 42.1 without problems, but the server is an older Sun Storage Box, which to which I don't have any access to check things out.

Regards, didiw
 
Old 10-29-2016, 12:34 PM   #2
dijetlo
Senior Member
 
Registered: Jan 2009
Location: RHELtopia....
Distribution: Solaris 11.2/Slackware/RHEL/
Posts: 1,491
Blog Entries: 2

Rep: Reputation: Disabled
Some applications when using an NFS mount want an rpc driven "lock" on the write media. This requires the NFS hosts and clients support lockd and statd nfs features
try running an nfsstat and confirm there are errors in the stack
Quote:
Server rpc stats:
calls badcalls badclnt badauth xdrcall
0 0 0 0 0

Client rpc stats:
calls retrans authrefrsh
14 0 14
This is from my FreeBSD NFS servers /etc/rc.conf
Quote:
# NFS Mount to Lab from metalBeast:/opt/kvm and metalBeast:/opt/docker
nfs_server_enable="YES"
nfsv4_server_enabled="YES"
nfsuserd_enabled="YES"
rpcbind_enable="YES"
mountd_enable="YES"
rpc_lockd_enable="YES"
rpc_statd_enable="YES"
It seems likely that your error is being driven by a failure of lockd and statd

Last edited by dijetlo; 10-29-2016 at 12:38 PM.
 
Old 01-05-2017, 11:49 AM   #3
didiw
Member
 
Registered: Oct 2009
Posts: 30

Original Poster
Rep: Reputation: 0
It was my own fault. I did not mount the filesystem as nfsv4, though the remote filesystem was the nfsv4 path, that is why I thought, it was mounted as nfsv4.
The problem, why locking in nfsv3 did not work, was, that the lock daemon in openSuSE 13.1 is missing and cannot be installed, even when reinstalling the kernel nfs server and nfs tools. So the issue is solved.
 
  


Reply

Tags
lock, lock file, nfs4, nfsv4


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
NFSv4 and Kerberos - "access denied by server" gatsby Linux - Server 2 11-13-2012 01:22 AM
sarge3.1 2.6.8-3-k7-smp locks up at "Configuring Network..." AlCstu Debian 1 01-09-2007 04:15 AM
ALSA "locks" sound only one program at a time slackwarefan Linux - Software 13 12-27-2006 12:34 PM
Debian(Knoppix? on HD) "locks" when PCMCIA card is inserted... dgr72371 Linux - Laptop and Netbook 4 01-23-2004 08:04 AM
new RH9 install locks up after displaying "login:" mikee Linux - General 1 07-29-2003 10:57 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 10:40 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration