From: Nikolay Borisov <n.borisov.lkml@gmail.com>
To: viro@zeniv.linux.org.uk
Cc: "linux-kernel"@vger.kernel.org, linux-fsdevel@vger.kernel.org,
spender@grsecurity.net
Subject: Repercussions of overflow in get_next_ino()
Date: Thu, 07 May 2015 15:30:25 +0300 [thread overview]
Message-ID: <554B5AE1.4060901@gmail.com> (raw)
Hello,
get_next_ino would allocate a number between 0...2^32 - 1 to be used as
an inode number. The implementation of this mechanism relies on an
unsigned int which is 32 bits. On one server I'm observing that every
couple of months grsec complains that the percpu variable last_ino
overflows (due to shared_last_ino) being incremented to the limit of a
32 bit value and then then the machine becomes unstable due to grsec
starting to kill processes. Now, I understand this isssue stems from the
fact how grsec detects the overflow.
My question is what are the repercussions of get_next_ino overflowing
and at some point having possibly multiple inodes on my system with the
same i_ino id? And why is it safe to have the inode id's overflow and
wrap around?
Would simply changing the inode numbering code work with 64 bit value
remedy the situation or would it require a more involved fix?
Regards,
Nikolay
next reply other threads:[~2015-05-07 12:30 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-05-07 12:30 Nikolay Borisov [this message]
2015-05-07 16:33 ` Repercussions of overflow in get_next_ino() J. R. Okajima
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=554B5AE1.4060901@gmail.com \
--to=n.borisov.lkml@gmail.com \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=spender@grsecurity.net \
--cc=viro@zeniv.linux.org.uk \
/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).