Whamcloud - gitweb
LU-10986 lfs: make lfs project tolerant errors 02/34102/5
authorWang Shilong <wshilong@ddn.com>
Wed, 2 May 2018 08:54:15 +0000 (16:54 +0800)
committerOleg Drokin <green@whamcloud.com>
Sat, 2 Mar 2019 01:30:13 +0000 (01:30 +0000)
commitffa453b2aa1ad7659b186bd8f729035f7060f075
tree24aaedf9a166a4b6fb837bea039c333b6722b926
parent3d3114e9a481ab0c1e3adc25465d99c913791fd1
LU-10986 lfs: make lfs project tolerant errors

This patch try to fix following problems:
1)command hang on pipe file, reproduced by following steps:
 $ mkfifo tmp/pipe
 $ lfs project -srp 500 tmp -->this will never finish.

Problem is opening a pipe file will be blocked in default
without O_NOBLOCK or O_NODELAY flag.

2)If a symbolic link with missing target exists, command
returns error and does not process remaining entries.

we should fix this problem by allowing command process
further even it hit some errors.

3)fix a wrong check for MAX_PATH

Lustre-change: https://review.whamcloud.com/32243
Lustre-commit: d189024bd3065c69c51ba90f6228c3ea28419dd0

Signed-off-by: Wang Shilong <wshilong@ddn.com>
Change-Id: I7d08a7547e6b1351a1eff23063da6cd9c4cdc5e3
Reviewed-on: https://review.whamcloud.com/34102
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Tested-by: Jenkins
Tested-by: Maloo <maloo@whamcloud.com>
lustre/tests/sanity-quota.sh
lustre/utils/lfs_project.c