[lustre-discuss] Cannot set ost.OSS.ost.thread_started
Youbiao He
yh54 at iastate.edu
Fri Nov 6 13:27:26 PST 2020
Thank you very much for your answer. It helps a lot. My Lustre version is
2.10.
For thread_min, when I set it to a number larger than 12, everything works
well, but when I set it to a number smaller than 12, whatever value I set,
it shows 8.
# lctl set_param ost.OSS.ost.threads_min=10
ost.OSS.ost.threads_min=10
# lctl get_param ost.OSS.ost.threads_min
ost.OSS.ost.threads_max=8
My cluster has 4 OSS and 3 clients.
On Tue, Nov 3, 2020 at 5:00 PM Andreas Dilger <adilger at dilger.ca> wrote:
> On Nov 3, 2020, at 9:25 AM, Youbiao He <yh54 at iastate.edu> wrote:
> > I have installed lustre file system on CentOS. It works well when I
> write or read files. But when I try to set the thread_started and
> thread_min for oss services, I met the following problem.
>
> It is always important to include the Lustre release version that you are
> using in any problem report.
>
> > To set parameters, I run: "sudo lctl set_param
> ost.OSS.ost.threads_started=36"
> > then, I check the setting value by running: "lctl get_param
> ost.OSS.ost.threads_started", and then it shows
> "ost.OSS.ost.threads_started=21". So I can not change the parameter
> "ost.OSS.ost.threads_started".
>
> The "threads_started" parameter is read-only, and lists the number of
> threads currently running. I agree that "lctl set_param" should probably
> print an error for the user in this case. You can see which parameters are
> writable by the '=' after the parameter name:
>
> $ lctl list_param -F ost.OSS.ost.threads*
> ost.OSS.ost.threads_max=
> ost.OSS.ost.threads_min=
> ost.OSS.ost.threads_started
>
> The underlying writable /proc or /sys files also has mode 644 instead of
> 444:
>
> $ ls -l /proc/fs/lustre/ost/OSS/ost/threads_*
> 0 -rw-r--r-- 1 root root 0 Nov 3 15:53
> /proc/fs/lustre/ost/OSS/ost/threads_max
> 0 -rw-r--r-- 1 root root 0 Nov 3 15:53
> /proc/fs/lustre/ost/OSS/ost/threads_min
> 0 -r--r--r-- 1 root root 0 Nov 3 15:53
> /proc/fs/lustre/ost/OSS/ost/threads_started
>
> There *is* an non-zero command status returned to the caller, but it is
> not obvious:
>
> # lctl set_param ost.OSS.ost.threads_started=38
> # echo $?
> 5
>
>
> > Another problem is on the parameter "ost.OSS.ost.threads_min", When I
> set it to 10 using lctl, and it shows the parameter is set to 8, not 10.
>
> In my testing, this seems to work OK:
>
> # lctl get_param ost.OSS.ost.*thread*
> ost.OSS.ost.threads_max=64
> ost.OSS.ost.threads_min=3
> ost.OSS.ost.threads_started=36
> # lctl set_param ost.OSS.ost.threads_min=8
> ost.OSS.ost.threads_min=8
> # lctl get_param ost.OSS.ost.*thread*
> ost.OSS.ost.threads_max=64
> ost.OSS.ost.threads_min=8
> ost.OSS.ost.threads_started=36
>
> Writing to threads_min at runtime doesn't change the current number of
> running threads. More service threads are only started when there are
> enough concurrently processed requests to start new threads, but it will no
> longer *stop* threads once threads_min is hit.
>
> # lctl set_param ost.OSS.ost.threads_min=48
> ost.OSS.ost.threads_min=48
> # lctl get_param ost.OSS.ost.threads*
> ost.OSS.ost.threads_max=64
> ost.OSS.ost.threads_min=48
> ost.OSS.ost.threads_started=36
>
> Cheers, Andreas
>
>
>
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.lustre.org/pipermail/lustre-discuss-lustre.org/attachments/20201106/e669e036/attachment.html>
More information about the lustre-discuss
mailing list