Subject: Re: [2.0-RC1] shutdown is not clean
To: None <port-sparc64@netbsd.org>
From: Michael Gerhards <HM-Gerhards@uni.de>
List: port-sparc64
Date: 10/10/2004 15:21:30
Daniel Carosone <dan@geek.com.au> wrote:
>> >
>> > Try "dkctl wd0 setcache r" before shutting down.
>>
>> I tried this and it worked! The next startup all filesystems were
>> described as "file system is clean, not checking".
>
> Exactly as I said above; the disk is being powered off before it's
> finished moving the final writes from its cache to the platters.
>
> Given that it's been asked to sync cache before it gets shut down, and
> that this isn't a commonly-reported problem, I suspect it may be a
> problem with your disk's firmware - a bug that means the sync cache
> command doesn't wait for the cache to sync until its complete.

Well - but why didn't this also appear on NetBSD 1.6.2? Are there any
changes in this behaviour between 1.6.2 and 2.0?

> Can you:
> - post details of the disk (atactl wd0 identify)

Model: SAMSUNG SP0802N, Rev: TK200-04, Serial #: S00JJ50X607945
Device type: ATA, fixed
Cylinders: 16383, heads: 16, sec/track: 63, total sectors: 156368016
Device capabilities:
        DMA
        LBA
        ATA standby timer values
        IORDY operation
        IORDY disabling
Device supports following standards:
ATA-1 ATA-2 ATA-3 ATA-4 ATA-5 ATA-6 ATA-7
Command set support:
        READ BUFFER command
        WRITE BUFFER command
        Host Protected Area feature set
        look-ahead
        write cache
        Power Management feature set
        Security Mode feature set
        SMART feature set
        FLUSH CACHE EXT command
        FLUSH CACHE command
        Device Configuration Overlay feature set
        48-bit Address feature set
        Automatic Acoustic Management feature set
        SET MAX security extension
        DOWNLOAD MICROCODE command
        SMART self-test
        SMART error logging
Command sets/features enabled:
        look-ahead
        write cache

> - try a different disk model/manufacturer

I will try this, but it will take at least until next weekend.

> Otherwise, i'd suggest running with the write cache off anyway,
> because i'd just be generally wary of that drive with the cache on.

So I should run "dkctl wd0 setcache r" on startup in rc.local?
Will this cost much performance?

Michael