Bug 722734 - [device-mapper-multipath] multipath should manage its fds wisely in case they run out
Summary: [device-mapper-multipath] multipath should manage its fds wisely in case they...
Keywords:
Status: CLOSED WONTFIX
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: device-mapper-multipath
Version: 6.1
Hardware: x86_64
OS: Linux
unspecified
high
Target Milestone: rc
: ---
Assignee: LVM and device-mapper development team
QA Contact: Storage QE
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2011-07-17 08:09 UTC by Haim
Modified: 2014-01-13 00:49 UTC (History)
13 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2011-07-19 21:30:24 UTC
Target Upstream Version:


Attachments (Terms of Use)
messages (12.60 MB, application/x-gzip)
2011-07-17 08:09 UTC, Haim
no flags Details

Description Haim 2011-07-17 08:09:00 UTC
Created attachment 513517 [details]
messages

Description of problem:

case: 

testing system scalability, where host is connected via FC to 360 devices with 4 paths each, multipath is run out of fds. 

Jul 17 07:56:40 | out of file descriptors. set or increase max_fds in /etc/multipath.conf

[root@rhev-a8c-02 ~]# lsof |grep multi |wc -l 
1047

[root@rhev-a8c-02 ~]# multipath -ll | awk '/3600/' |wc -l 
362

[root@rhev-a8c-02 ~]# multipath -ll | awk '/sd/' |wc -l 
1448

desired: multipath should open & close fds dynamically.

[root@rhev-a8c-02 ~]# ulimit -a
core file size          (blocks, -c) 0
data seg size           (kbytes, -d) unlimited
scheduling priority             (-e) 0
file size               (blocks, -f) unlimited
pending signals                 (-i) 515767
max locked memory       (kbytes, -l) 64
max memory size         (kbytes, -m) unlimited
open files                      (-n) 3000
pipe size            (512 bytes, -p) 8
POSIX message queues     (bytes, -q) 819200
real-time priority              (-r) 0
stack size              (kbytes, -s) 10240
cpu time               (seconds, -t) unlimited
max user processes              (-u) 1024
virtual memory          (kbytes, -v) unlimited
file locks                      (-x) unlimited

Comment 2 Ben Marzinski 2011-07-19 21:30:24 UTC
Multipathd checks the status of every path every polling_interval seconds (usually 5).  To do this, it needs an open file descriptor.  Closing and re-opening these descriptors every time is not an acceptable option.  Losing paths can put the system under load. Depending on which devices you lose, this can significantly delay or even make it impossible to reopen these devices.  Also, keeping the multipath path devices open, keeps many programs from accidentally accessing the path devices directly, instead of accessing the multipath device.  For instance, user's can't simply mount a single path of a multipath device.

It's simple to adjust the number of file descriptors with the max_fds multipath.conf variable.

multipath intentionally uses the same number of file descriptors as multipathd to make it more likely that a user will notice that they don't have max_fds set correctly.  Otherwise, they might not notice it when the multipathd daemon fails. Leaving their multipath devices unable to restore lost paths.


Note You need to log in before you can comment on or make changes to this bug.