kernelnewbies.kernelnewbies.org archive mirror
 help / color / mirror / Atom feed
From: ablacktshirt@gmail.com (Yubin Ruan)
To: kernelnewbies@lists.kernelnewbies.org
Subject: Is vnode number also limit system-wide number of open file?
Date: Thu, 1 Jun 2017 01:47:44 +0800	[thread overview]
Message-ID: <20170531174741.GA8663@HP> (raw)
In-Reply-To: <35D5B7E0-148A-4B4B-AF20-BA3E174FC60B@gmail.com>

On Wed, May 31, 2017 at 08:34:09AM +0100, Okash Khawaja wrote:
> 
> 
> > On 31 May 2017, at 14:37, Yubin Ruan <ablacktshirt@gmail.com> wrote:
> > 
> > I notice that there is a 
> > 
> >    unsigned long        i_ino;
> > 
> > in definition of `struct inode' [1], which is the virtual filesystem inode.
> > Does that mean "inode number" and is it used for indexing in the system-wide
> > inode table? 
> > 
> > If that is the case, would that limit the number of open file in Linux?
> > 
> > I know there *is* such a limit, and superusers can adjust that by
> > /proc/sys/fs/file-max. Currently I cannot raise that to too high, otherwise
> > the system would crash, which I think is because I have limited memory. But,
> > the point is, if I have lots of memory in my machine (say hunderds of
> > Gigabytes), would the number of open file system-wide limited by the `i_ino'
> > above? Since its type is "unsigned long", I guess I can only open
> > 2^(sizeof(unsigned long)) file simultaneously? 
> 
> 2^(8*sizeof(unsigned long))
 
 good catch.

> Which is big. Is there some use case for very large number of files?

No, I just wonder whether this is the limit...

--
Yubin

  reply	other threads:[~2017-05-31 17:47 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-05-31 13:37 Is vnode number also limit system-wide number of open file? Yubin Ruan
2017-05-31  7:34 ` Okash Khawaja
2017-05-31 17:47   ` Yubin Ruan [this message]
2017-05-31 17:30 ` Rik van Riel
2017-06-01  9:15   ` Yubin Ruan
2017-06-01  2:12     ` valdis.kletnieks at vt.edu
2017-06-01  2:16     ` Manish Katiyar

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20170531174741.GA8663@HP \
    --to=ablacktshirt@gmail.com \
    --cc=kernelnewbies@lists.kernelnewbies.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).