Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 19 Jun 2005 10:25:06 +0300
From:      Giorgos Keramidas <keramida@ceid.upatras.gr>
To:        Lefteris Tsintjelis <lefty@asda.gr>
Cc:        freebsd-questions@freebsd.org
Subject:   Re: Can't mount partitions with soft-updates enabled with async option
Message-ID:  <20050619072506.GA638@gothmog.gr>
In-Reply-To: <42B4F7A8.87B4AEA6@ene.asda.gr>
References:  <42B481D0.EFA31599@ene.asda.gr> <20050618203437.GA1966@gothmog.gr> <42B4F7A8.87B4AEA6@ene.asda.gr>

next in thread | previous in thread | raw e-mail | index | archive | help
On 2005-06-19 07:42, Lefteris Tsintjelis <lefty@ene.asda.gr> wrote:
> Giorgos Keramidas wrote:
> >
> > Why would you want to do that?
> >
> > Soft-updates already provides most of the benefits of an async mount
> > plus some extra goodies, like never leaving the filesystem in an
> > inconsistent state.
>
> Kalimera Giorgo,

Kalimera ;)

> For boosting io speed to the max it can get. The system is very stable
> (no crashes whatsover) and UPS monitored and protected so chances of
> having an inconsistent filesystem are very low or am I wrong? (I am
> refering to an async mounted filesystem)

True.

You may still find it nice to run with softupdates though.  The guarantee
that the filesystem will always be in a consistent state (i.e. will recover
quickly whenever that may be needed) are too good to throw them away for an
extra 2-3% of speed.

In the "Design & Implementation" book, Kirk McKusick and George
V. Neville-Neil have included the results of benchmarks between: normal,
softupdates and async mounts.

The number of synchronous writes in a softupdates mount was less than
0.0006% and the total running time of the benchmarks on softupdates was
only 0.5% more than that of an asynchronous mount.

Thus, the speed gain of doing a fully asynchronous mount may not be worth
the potential trouble.

>> The speed gain of mounting a squid cache as async shouldn't really be that
>> big, but the guarantees of avoiding data loss when a filesystem is mounted
>> with softupdates are too big to ignore :-)

> Well, that would probably depend on the requests per second but for a pretty
> busy squid box (disk cache is already split to a few disks) and to keep things
> running even more smooth and optimal, this would probably boost the io
> performance further more (if I understood everything right).

Maybe.  But would the performance gain be big enough to justify losing the
stability and filesystem consistency that softupdates provide?  Judging by
the numbers presented in the "Design & Implementation of FreeBSD" book, it
seems that any performance gain of going fully async wouldn't be that big.

> The reason I am thinking of switching to async mode is that I am getting
> some physical io page faults (very small percentage compared to the
> requests per second but still) and I am already using the noatime option
> with soft-updates of course.

Squid is such a memory hungry beast that I wouldn't worry about a small
percentage of page faults caused by softupdates.  The proxy itself is
probably causing a hell of a lot more page faults as it maps cache files
or as it recycles cache entries :-)

Are you absolutely sure it's softupdates that is causing these extra
page faults?  (Which *may* be true, because of the extra memory
softupdates need, in order to operate.  But how can you tell?)

- Giorgos




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20050619072506.GA638>