[LU-9399] lctl conf_param and lctl set_param -P are broken for llite parameters Created: 26/Apr/17  Updated: 17/Jun/17  Resolved: 17/Jun/17

Status: Resolved
Project: Lustre
Component/s: None
Affects Version/s: Lustre 2.10.0
Fix Version/s: Lustre 2.10.0

Type: Bug Priority: Minor
Reporter: John Hammond Assignee: Emoly Liu
Resolution: Fixed Votes: 1
Labels: None

Issue Links:
Related
is related to LU-7183 lctl set_param -P does not work for s... Closed
is related to LU-8066 Move lustre procfs handling to sysfs ... Open
is related to LU-7004 fix "lctl set_param -P" to allow depr... Resolved
Severity: 3
Rank (Obsolete): 9223372036854775807

 Description   

lctl conf_param and lctl set_param -P are broken for llite parameters (probably due to an ordering issue between the processing of the config logs and creation of the subdirectory of /proc/fs/llite corresponding to the mount point. Both work as expected for a client that was mounted when the parameter was set but fail for subsequently mounted clients.

Using lctl conf_param:

m:~# llmount.sh
...
m:~# lctl get_param llite.*.xattr_cache
llite.lustre-ffff880036686000.xattr_cache=1
m:~# lctl conf_param lustre.llite.xattr_cache=0
m:~# lctl get_param llite.*.xattr_cache
llite.lustre-ffff880036686000.xattr_cache=1
m:~# lctl get_param llite.*.xattr_cache
llite.lustre-ffff880036686000.xattr_cache=0
m:~# umount /mnt/lustre
m:~# mount m@tcp:/lustre /mnt/lustre -t lustre -o user_xattr,flock
m:~# lctl get_param llite.*.xattr_cache
llite.lustre-ffff88001017d800.xattr_cache=1
m:~# sleep 60 && lctl get_param llite.*.xattr_cache
llite.lustre-ffff88001017d800.xattr_cache=1
m:~# sleep 60 && lctl get_param llite.*.xattr_cache
llite.lustre-ffff88001017d800.xattr_cache=1
m:~# llmountcleanup.sh
...

Using lctl set_param -P:

m:~# mllmount.sh
...
m:~# lctl get_param llite.*.xattr_cache
llite.lustre-ffff88000ee70800.xattr_cache=1
m:~# lctl set_param -P llite.*.xattr_cache=0
m:~# lctl get_param llite.*.xattr_cache
llite.lustre-ffff88000ee70800.xattr_cache=1
m:~# sleep 10 && lctl get_param llite.*.xattr_cache
llite.lustre-ffff88000ee70800.xattr_cache=0
m:~# umount /mnt/lustre
m:~# mount m@tcp:/lustre /mnt/lustre -t lustre -o user_xattr,flock
m:~# lctl get_param llite.*.xattr_cache
llite.lustre-ffff880007858000.xattr_cache=1
m:~# sleep 60 && lctl get_param llite.*.xattr_cache
llite.lustre-ffff880007858000.xattr_cache=1
m:~# sleep 60 && lctl get_param llite.*.xattr_cache
llite.lustre-ffff880007858000.xattr_cache=1

If a second client is mounted (on the same node) then the param will
be set correctly on the first mount point but not on the second.

m:~# mount m@tcp:/lustre /mnt/lustre2 -t lustre -o user_xattr,flock
m:~# lctl get_param llite.*.xattr_cache
llite.lustre-ffff880007858000.xattr_cache=0
llite.lustre-ffff88006cddb800.xattr_cache=1


 Comments   
Comment by Peter Jones [ 27/Apr/17 ]

Emoly

Could you please assist with this issue?

Thanks

Peter

Comment by James A Simmons [ 04/May/17 ]

Can you try my llite sysfs patch https://review.whamcloud.com/#/c/24031. Test conf-sanity 28 will reveal this problem. Currently it fails because of it.

Comment by Emoly Liu [ 05/May/17 ]

I will look into it.

Comment by Emoly Liu [ 19/May/17 ]

As John said, this is an ordering issue. process_param2_config() calls "/usr/sbin/lctl set_param llite.*.xattr_cache=0" during mounting before the client's /proc/fs/lustre/llite/xxx proc entry is created.
I will see how to fix it.

Comment by Gerrit Updater [ 23/May/17 ]

Emoly Liu (emoly.liu@intel.com) uploaded a new patch: https://review.whamcloud.com/27241
Subject: LU-9399 llite: register mountpoint before process llog
Project: fs/lustre-release
Branch: master
Current Patch Set: 1
Commit: 35efc9b025c910028317b60398d0d40f446db3f2

Comment by Gerrit Updater [ 16/Jun/17 ]

Oleg Drokin (oleg.drokin@intel.com) merged in patch https://review.whamcloud.com/27241/
Subject: LU-9399 llite: register mountpoint before process llog
Project: fs/lustre-release
Branch: master
Current Patch Set:
Commit: fa1bff8f6f3afb858618a563b039af3bbf46153b

Comment by Peter Jones [ 17/Jun/17 ]

Landed for 2.10

Generated at Sat Feb 10 02:25:51 UTC 2024 using Jira 9.4.14#940014-sha1:734e6822bbf0d45eff9af51f82432957f73aa32c.