From: ebiederm@xmission.com (Eric W. Biederman)
To: Benoit Lourdelet <blourdel@juniper.net>
Cc: Serge Hallyn <serge.hallyn@ubuntu.com>,
"linux-kernel\@vger.kernel.org" <linux-kernel@vger.kernel.org>,
lxc-users <lxc-users@lists.sourceforge.net>
Subject: Re: [Lxc-users] Containers slow to start after 1600
Date: Wed, 20 Mar 2013 13:38:08 -0700 [thread overview]
Message-ID: <87vc8ldcy7.fsf@xmission.com> (raw)
In-Reply-To: <CD6F35B6.7221%blourdel@juniper.net> (Benoit Lourdelet's message of "Wed, 20 Mar 2013 20:09:29 +0000")
Benoit Lourdelet <blourdel@juniper.net> writes:
> Hello,
>
> The measurement has been done with kernel 3.8.2.
>
> Linux ieng-serv06 3.7.9 #3 SMP Wed Feb 27 02:38:58 PST 2013 x86_64 x86_64
> x86_64 GNU/Linux
Two different kernel versions?
> What information would you like to see on the kernel ?
The question is where is the kernel spending it's time. So profiling
information should help us see that. Something like.
$ cat > test-script.sh << 'EOF'
#!/bin/bash
for i in $(seq 1 2000) ; do
ip link add a$i type veth peer name b$i
done
EOF
$ perf record -a -g test-script.sh
$ perf report
I don't do anywhere enough work with perf to remember what good options
are.
You definititely don't want to time anything you are doing something
silly like asking ip link add to generate device names which is O(N^2)
when you create one device at a time.
And of course there is the interesting discrepency. Why can I add 5000
veth pairs in 120 seconds and it takes you 1123 seconds. Do you have a very
slow cpu in your test environment? Or was your test asking the kernel
to generate names.
Once we know where the kernel is spending it's time we can look to see
if there is anything that is easy to fix, and where to point you.
Both my timing and yours indicates that there is something taking O(N^2)
time in there. So it would at least be interesting to see what that
something is.
Eric
next prev parent reply other threads:[~2013-03-20 20:38 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20130319182829.GA15451@sergelap>
[not found] ` <CD6E73D8.71FE%blourdel@juniper.net>
2013-03-19 20:34 ` [Lxc-users] Containers slow to start after 1600 Serge Hallyn
2013-03-20 0:29 ` Eric W. Biederman
2013-03-20 20:09 ` Benoit Lourdelet
2013-03-20 20:38 ` Eric W. Biederman [this message]
2013-03-22 17:05 ` Benoit Lourdelet
2013-03-22 21:31 ` Eric W. Biederman
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=87vc8ldcy7.fsf@xmission.com \
--to=ebiederm@xmission.com \
--cc=blourdel@juniper.net \
--cc=linux-kernel@vger.kernel.org \
--cc=lxc-users@lists.sourceforge.net \
--cc=serge.hallyn@ubuntu.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.