From: "Randy MacLeod" <randy.macleod@windriver.com>
To: Sakib Sajal <sakib.sajal@windriver.com>,
openembedded-core@lists.openembedded.org
Subject: Re: [OE-core] [PATCH] scripts/oe-timeout-dd-test.sh: add script
Date: Mon, 8 Mar 2021 09:50:19 -0500 [thread overview]
Message-ID: <a8d69435-a6cc-4daf-a22a-cb190c04f781@windriver.com> (raw)
In-Reply-To: <20210307205817.5679-1-sakib.sajal@windriver.com>
On 2021-03-07 3:58 p.m., Sakib Sajal wrote:
> oe-timeout-dd-test tries to write <count> number of
> kilobytes to the filesystem within a specified
> <timeout>. The purporse of this script is to find
s/purporse/purpose/
> which part of the build system puts stress on the
> filesystem io and log all the processes.
>
> To use and monitor a build, add to local.conf:
> BB_HEARTBEAT_EVENT = "<interval to log data>"
> BB_LOG_HOST_STAT_ON_INTERVAL = "1"
> BB_LOG_HOST_STAT_CMDS = "oe-timeout-dd-test.sh <timeout> <count>"
>
> Log can be found at:
> $TMPDIR/buildstats/<build_number>/host_stats file.
>
> Signed-off-by: Sakib Sajal <sakib.sajal@windriver.com>
> ---
> scripts/oe-timeout-dd-test.sh | 26 ++++++++++++++++++++++++++
> 1 file changed, 26 insertions(+)
> create mode 100644 scripts/oe-timeout-dd-test.sh
>
> diff --git a/scripts/oe-timeout-dd-test.sh b/scripts/oe-timeout-dd-test.sh
> new file mode 100644
> index 0000000000..40b3948c32
> --- /dev/null
> +++ b/scripts/oe-timeout-dd-test.sh
> @@ -0,0 +1,26 @@
> +#!/bin/sh
> +#
> +# oe-timeout-dd-test tries to write <count> number of
> +# kilobytes to the filesystem within a specified time
> +# constraint. The purporse of this script is to find
s/purporse/purpose/
> +# which part of the build system puts stress on the
> +# filesystem io and log all the processes.
s/./when that happens./
It's probably worth pointing out that <timeout> is a floating point
number and maybe provide typical values such as with a HB interval of
15 seconds, and 0.5s timeout and 100 KB IO, the result is
no triggers on an isolated system whereas say ?0.1?s and 100 KB IO
results in several triggers. The idea is to give people a starting
point.
> +
> +usage() {
> + echo "Usage: $0 <timeout> <count>"
> +}
> +
> +if [ $# -ne 2 ]; then
> + usage
> + exit 1
> +fi
> +
> +timeout $1 dd if=/dev/zero of=/tmp/foo bs=1024 count=$2 >/dev/null 2>&1
> +
> +if [ $? -ne 0 ]
> +then
> + top -b -n 1
> +else
> + echo "success"
Do we need this else part? It'll just fill up the logs?
> +fi
> +
What values have you tried and how did that work out?
On Friday, a build with 100KB and was it .5 seconds and didn't
see any event exceed the timeout, right? We also ran several builds
out of a shared local sstate-cache and didn't see any event exceed the
timeout, iirc.
../Randy
>
>
>
>
>
--
# Randy MacLeod
# Wind River Linux
next prev parent reply other threads:[~2021-03-08 14:50 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-03-07 20:58 [PATCH] scripts/oe-timeout-dd-test.sh: add script Sakib Sajal
2021-03-08 14:50 ` Randy MacLeod [this message]
2021-03-08 17:33 ` [OE-core] " Richard Purdie
2021-03-08 20:46 ` Sakib Sajal
2021-03-08 22:10 ` Richard Purdie
2021-03-11 20:53 ` Yi Fan Yu
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=a8d69435-a6cc-4daf-a22a-cb190c04f781@windriver.com \
--to=randy.macleod@windriver.com \
--cc=openembedded-core@lists.openembedded.org \
--cc=sakib.sajal@windriver.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox