Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 11 Apr 2007 01:38:35 +0200
From:      "Clayton Milos" <clay@milos.co.za>
To:        "Scott Lambert" <lambert@lambertfam.org>
Cc:        FreeBSD STABLE <freebsd-stable@freebsd.org>
Subject:   Re: uid/gid lookups slower on 6.2 than 4.x?
Message-ID:  <05c001c77bc9$5bdc36b0$9603a8c0@claylaptop>
References:  <20070410231942.GB13500@sysmon.tcworks.net>

next in thread | previous in thread | raw e-mail | index | archive | help

----- Original Message ----- 
From: "Scott Lambert" <lambert@lambertfam.org>
To: "FreeBSD STABLE" <freebsd-stable@freebsd.org>
Sent: Wednesday, April 11, 2007 1:19 AM
Subject: uid/gid lookups slower on 6.2 than 4.x?


> I've run into an interesting performance "issue" with ls on a 6.2-STABLE
> box, web1.  This box is going to replace my current 4.11 box, ns,
> and is not currently active.  It's running all the daemons it will be in
> production, but traffic is not pointed at it yet.
>
> I don't think the gmirror vs. adaptec RAID disk subsystem would explain
> the performance differences.  I could be wrong.  If I am, I'm going to
> have to get a RAID card for the new box.
>
> root@web1 /home
> 17:58:57 Tue Apr 10 # time ls -l | wc -l
>    3135
>
> real    0m35.224s
> user    0m6.748s
> sys     0m28.482s
>
> root@web1 /home
> 17:59:48 Tue Apr 10 # time ls -l | wc -l
>    3135
>
> real    0m35.279s
> user    0m6.939s
> sys     0m28.348s
>
> root@web1 /home
> 18:00:37 Tue Apr 10 # time ls -l | wc -l
>    3135
>
> real    0m35.203s
> user    0m6.640s
> sys     0m28.569s
>
> root@web1 /home
> 18:01:13 Tue Apr 10 #  uname -a
> FreeBSD web1.hosting.tcworks.net 6.2-STABLE-200702 FreeBSD 
> 6.2-STABLE-200702 #0: Sun Feb  4 13:35:09 UTC 2007 
> root@dessler.cse.buffalo.edu:/usr/obj/usr/src/sys/SMP  i386
>
> root@web1 /home
> 18:03:38 Tue Apr 10 # time ls -ln | wc -l
>    3135
>
> real    0m0.054s
> user    0m0.030s
> sys     0m0.031s
>
> root@web1 /home
> 18:04:53 Tue Apr 10 # time ls -ln | wc -l
>    3135
>
> real    0m0.054s
> user    0m0.046s
> sys     0m0.014s
>
> root@web1 /home
> 18:04:54 Tue Apr 10 # time ls -ln | wc -l
>    3135
>
> real    0m0.054s
> user    0m0.037s
> sys     0m0.024s
>
> The difference in the number of home directories is due to my rsync
> script not using the --delete option, yet.
>
> Here are the same statistics from my 4.11 box.  This box is in
> production with the same daemons as the web1 box. :
>
> root@ns /home
> 18:04:38 Tue Apr 10 # time ls -l | wc -l
>    3070
>
> real    0m0.113s
> user    0m0.041s
> sys     0m0.050s
>
> root@ns /home
> 18:04:41 Tue Apr 10 # time ls -l | wc -l
>
>    3070
>
> real    0m0.096s
> user    0m0.037s
> sys     0m0.053s
>
> root@ns /home
> 18:04:41 Tue Apr 10 # time ls -l | wc -l
>    3070
>
> real    0m0.099s
> user    0m0.046s
> sys     0m0.046s
>
> root@ns /home
> 18:04:44 Tue Apr 10 # uname -a
> FreeBSD ns 4.11-RELEASE-p21 FreeBSD 4.11-RELEASE-p21 #2: Thu Sep 21 
> 00:53:20 CDT 2006     root@sysmon:/usr/obj/usr/src/sys/NS  i386
>
> root@ns /home
> 18:09:38 Tue Apr 10 # time ls -ln | wc -l
>    3070
>
> real    0m0.055s
> user    0m0.030s
> sys     0m0.023s
>
> root@ns /home
> 18:10:20 Tue Apr 10 # time ls -ln | wc -l
>    3070
>
> real    0m0.055s
> user    0m0.031s
> sys     0m0.022s
>
> root@ns /home
> 18:10:21 Tue Apr 10 # time ls -ln | wc -l
>    3070
>
> real    0m0.059s
> user    0m0.041s
> sys     0m0.012s
>
>
> -- 
> Scott Lambert                    KC5MLE                       Unix 
> SysAdmin
> lambert@lambertfam.org
>

First thing to check is if the RAID card has onboard cache. I've found RAID 
cards to cache things like this and make the array appear incredibly fast.
You haven't said which RAID card you are using but if it's an Adaptec I'm 
pretty sure it has some amount of onboard cache.

-Clay




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?05c001c77bc9$5bdc36b0$9603a8c0>