All of lore.kernel.org
 help / color / mirror / Atom feed
From: Nikita Yushchenko via ltp <ltp@lists.linux.it>
To: Cyril Hrubis <chrubis@suse.cz>
Cc: kernel@openvz.org, ltp@lists.linux.it
Subject: Re: [LTP] [PATCH] testcases/lib: introduce sysctl wrapper
Date: Tue, 22 Feb 2022 19:09:15 +0300	[thread overview]
Message-ID: <26fe8a19-8557-5a63-7e5f-fb126e8eed95@virtuozzo.com> (raw)
In-Reply-To: <YhUKtWP8dwNBAcmy@yuki>

>> Linux sysctl utility does not propagate errors returned from proc writes
>> to it's exit code:
>>
>>> sysctl -q -w net.ipv4.tcp_congestion_control=dctcp
>> sysctl: setting key "net.ipv4.tcp_congestion_control": Operation not permitted
>>> echo $?
>> 0
> 
> I wonder why we use sysctl in the first place, all that it does in our
> case is write to /proc/sys/net/.... file. I guess that it may be easier
> if we just echo the value into the corresponding files instead.

LTP sometimes uses sysctl under 'tst_net_run' wrapper

Using shell redirection under wrapper is quite tricky if possible at all.

Nikita


-- 
Mailing list info: https://lists.linux.it/listinfo/ltp

  reply	other threads:[~2022-02-22 16:09 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-02-22 15:55 [LTP] [PATCH] testcases/lib: introduce sysctl wrapper Nikita Yushchenko via ltp
2022-02-22 16:09 ` Cyril Hrubis
2022-02-22 16:09   ` Nikita Yushchenko via ltp [this message]
2022-02-22 17:35     ` Cyril Hrubis
2022-02-22 18:31       ` Petr Vorel
2022-02-23 12:44         ` Cyril Hrubis
2022-02-23 14:47           ` Petr Vorel

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=26fe8a19-8557-5a63-7e5f-fb126e8eed95@virtuozzo.com \
    --to=ltp@lists.linux.it \
    --cc=chrubis@suse.cz \
    --cc=kernel@openvz.org \
    --cc=nikita.yushchenko@virtuozzo.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.