Operating System - Linux
1827814 Members
2842 Online
109969 Solutions
New Discussion

NFS and limit in 32 directorys??

 
Carme Torca
Super Advisor

NFS and limit in 32 directorys??

Hi,

I have a directory that its a NFS mount in another system. But I have one problem I can not mkdir more than 31 directorys in this directory. If I mkdir one directory or file more and I do an ls, it is hung.

Does anybody knows why??, Is there any restricction??

Thanks!,
Carmen.
Users are not too bad ;-)
11 REPLIES 11
Ramalingam
Advisor

Re: NFS and limit in 32 directorys??

Hi Carmen,

1. man mkdir
- reveals that only LINK_MAX subdirectories
be created.
See linits(5)
Look in
( /usr/include/limits.h )
This header file is already mentioned in some thread about finding "32 / 64 bit architecture by some one
Search for "diff between " in this forum
)

2. To look in limits(5)
man 5 limits

3. getconf LINK_MAX [pathname of dir]

I think you can configure those values in
that header file

Hope this helps

Regards,
Ram.
We Learn the most When We have to Invent
Stuart Browne
Honored Contributor

Re: NFS and limit in 32 directorys??

Well you've failed to say what distribution you're using and what the client and server versions of daemons etc. are.

However, Linux as an NFS server and client have no issues with that depth of path:

/home/bekar/schedule/1/2/3/4/6/7/8/9/0/1/2/3/4/5/6/7/8/9/0/1/2/3/4/5/6/7/8/9/0/1/2/3/4/5/6/7/8/9/0/1/2/3/4/5/6/7/8/9/0

That's 53 odd levels deep, without batting an eyelid.

Possibly it's not a depth issue, but a length issue. What path are you trying to use/create?
One long-haired git at your service...
Carme Torca
Super Advisor

Re: NFS and limit in 32 directorys??

Hi,

I have this:

root@nodo-orig]# df -k

nodo-1:/export/fitxers_carregues
34979548 1331996 33297756 4% /export/fitxers_carregues/app

and I have in nodo-orig:/export/fitxers_carregues/app:
[root@hppz06 app]# ls -l
total 31
drwxr-xr-x 6 ftpbea ftpbea 512 Aug 3 09:14 SARCAT_APP_AJUTS
drwxr-xr-x 6 ftpbea ftpbea 512 Aug 3 09:14 SARCAT_APP_ARP
drwxr-xr-x 6 ftpbea ftpbea 512 Aug 3 09:14 SARCAT_APP_CC
drwxr-xr-x 6 ftpbea ftpbea 512 Aug 3 09:14 SARCAT_APP_CET
drwxr-xr-x 6 ftpbea ftpbea 512 Aug 3 09:14 SARCAT_APP_CIP
drwxr-xr-x 6 ftpbea ftpbea 512 Aug 3 09:14 SARCAT_APP_CON
drwxr-xr-x 6 ftpbea ftpbea 512 Aug 3 09:14 SARCAT_APP_DIP
drwxr-xr-x 6 ftpbea ftpbea 512 Aug 3 09:14 SARCAT_APP_DIS
drwxr-xr-x 6 ftpbea ftpbea 512 Aug 3 09:14 SARCAT_APP_ECONOMICS
drwxr-xr-x 6 ftpbea ftpbea 512 Aug 3 09:14 SARCAT_APP_EPI
drwxr-xr-x 6 ftpbea ftpbea 512 Aug 3 09:14 SARCAT_APP_EXP
drwxr-xr-x 6 ftpbea ftpbea 512 Aug 3 09:14 SARCAT_APP_FAMILIES
drwxr-xr-x 6 ftpbea ftpbea 512 Aug 3 09:14 SARCAT_APP_GEU
drwxr-xr-x 6 ftpbea ftpbea 512 Aug 3 09:14 SARCAT_APP_HAH
drwxr-xr-x 6 ftpbea ftpbea 512 Aug 3 09:14 SARCAT_APP_HCE
drwxr-xr-x 6 ftpbea ftpbea 512 Aug 3 09:14 SARCAT_APP_HOF
drwxr-xr-x 6 ftpbea ftpbea 512 Aug 3 09:14 SARCAT_APP_HRH
drwxr-xr-x 6 ftpbea ftpbea 512 Aug 3 09:14 SARCAT_APP_INSPECCIO
drwxr-xr-x 6 ftpbea ftpbea 512 Aug 3 09:14 SARCAT_APP_LLOGATERS
drwxr-xr-x 6 ftpbea ftpbea 512 Aug 3 09:14 SARCAT_APP_NOCES
drwxr-xr-x 6 ftpbea ftpbea 512 Aug 3 09:14 SARCAT_APP_REIE
drwxr-xr-x 6 ftpbea ftpbea 512 Aug 3 09:14 SARCAT_APP_RMI
drwxr-xr-x 6 ftpbea ftpbea 512 Aug 3 09:14 SARCAT_APP_SERVEIS
drwxr-xr-x 6 ftpbea ftpbea 512 Aug 3 09:14 SARCAT_APP_SGI
drwxr-xr-x 6 ftpbea ftpbea 512 Aug 3 09:14 SARCAT_APP_SIE
drwxr-xr-x 6 ftpbea ftpbea 512 Aug 3 09:14 SARCAT_APP_SIEBEL
drwxr-xr-x 6 ftpbea ftpbea 512 Aug 3 09:14 SARCAT_APP_SIN
drwxr-xr-x 6 ftpbea ftpbea 512 Aug 3 09:14 SARCAT_APP_SUBVENCIO
drwxr-xr-x 6 ftpbea ftpbea 512 Aug 3 09:14 SARCAT_APP_TSA
drwxr-xr-x 6 ftpbea ftpbea 512 Aug 3 09:14 SARCAT_APP_VIDU
drwxr-xr-x 6 ftpbea ftpbea 512 Aug 3 09:14 SARCAT_APP_W4

If I create another directory or another file in this filesystem, the nfs doesn't work and it's hung.


Users are not too bad ;-)
Stuart Browne
Honored Contributor

Re: NFS and limit in 32 directorys??

Well, a quick test here:

perl -e 'for ($i = 0;$i<50;$i++) { mkdir( "somestuband_" . $i ); }'

No issues creating 50 directories.

What have you got serving NFS? What are you using as a client to the NFS server?
One long-haired git at your service...
Carme Torca
Super Advisor

Re: NFS and limit in 32 directorys??

Hi,

I have using nfslock, and I have running this process: rpc.statd.

It is in the /etc/init.d/


Users are not too bad ;-)
Carme Torca
Super Advisor

Re: NFS and limit in 32 directorys??

Hi,

I could create all the directories, but, after I could not access to this directory.. I have to remove them from the original server.
Users are not too bad ;-)
Stuart Browne
Honored Contributor

Re: NFS and limit in 32 directorys??

Ok then.. try these commands:

rpcinfo -p
rpcinfo -p

This will return the various services and versions that are running. Show us this information please.
One long-haired git at your service...
Steven E. Protter
Exalted Contributor

Re: NFS and limit in 32 directorys??

This could be actually causes by kernel parameters like nflock or nfile on HP or whatever the euqivalent is on Linux.

See why i'm unworthy for my position in the standings.

I will re-iterate that there is nothing built into NFS like this. I'm doing more than 32 in an Linux NFS mount right now.

Red Hat ES 3

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
Vitaly Karasik_1
Honored Contributor

Re: NFS and limit in 32 directorys??

- Any messages in syslog?

- what is distro/kernel on server/client?

Carme Torca
Super Advisor

Re: NFS and limit in 32 directorys??

Hi,

I have change the version of nfs at mount:
node-1:/export/fitxers_carregues /export/fitxers_carregues/app nfs rw,suid,nfsvers=2,soft 0
0

and now its works... but I have the problem not at the 32 file, I have the problem to create the 43 file.
Any idea???

Thanks!

Users are not too bad ;-)
Stuart Browne
Honored Contributor

Re: NFS and limit in 32 directorys??

You've still not told us the server OS or versions, or the clietn OS or versions.

Without this information, we can't help you further, without making wild random guesses.
One long-haired git at your service...