Subject: port-i386/585: File system corruption after being in standby mode
To: None <gnats-admin@sun-lamp.cs.berkeley.edu>
From: Oystein Torbjornsen TF.DT <Oystein.Torbjornsen@tfdt.nta.no>
List: netbsd-bugs
Date: 11/23/1994 11:35:05
>Number:         585
>Category:       port-i386
>Synopsis:       FS corruption after being in standby mode on Compaq laptop
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    gnats-admin (GNATS administrator)
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Wed Nov 23 11:35:03 1994
>Originator:     Oystein Torbjornsen
>Organization:
"Norwegian Telecom Research, Trondheim, Norway"
>Release:        1.0
>Environment:
Compaq LTE/Lite 4/25E laptop, 8MB RAM, IDE, 210MB Seagate ST9235AG 
NetBSD 1.0 (GENERICAHA) #3: Sun Oct 23 20:58:04 PDT 1994
    cgd@sun-lamp.cs.berkeley.edu:/usr/src/sys/arch/i386/compile/GENERICAHA
CPU: i486DX (486-class CPU)
real mem  = 8257536
avail mem = 6778880
using 126 buffers containing 516096 bytes of memory
pc0 at isa0 port 0x60-0x6f irq 1: color
com0 at isa0 port 0x3f8-0x3ff irq 4: ns82450 or ns16450, no fifo
com1 at isa0 port 0x2f8-0x2ff irq 3: ns16550a, working fifo
lpt2 at isa0 port 0x3bc-0x3c3: polled
wdc0 at isa0 port 0x1f0-0x1f7 irq 14
wd0 at wdc0 drive 0: 200MB 985 cyl, 13 head, 32 sec <ST9235AG>
fdc0 at isa0 port 0x3f0-0x3f7 irq 6 drq 2
fd0 at fdc0 drive 0: 1.44MB 80 cyl, 2 head, 18 sec
ep0 at isa0 port 0x300-0x30f irq 10: aui/utp address 00:60:8c:75:e6:dd
ie0: unknown AT&T board type code 15
npx0 at isa0 port 0xf0-0xff: using exception 16
biomask 4040 netmask 41a ttymask 1a
changing root device to wd0a

System: NetBSD fabula.nta.no 1.0 NetBSD 1.0 (GENERICAHA) #3: Sun Oct 23 20:58:04 PDT 1994 cgd@sun-lamp.cs.berkeley.edu:/usr/src/sys/arch/i386/compile/GENERICAHA i386

>Description:

Setting the laptop into standby mode (using the standby button) severely
corrupts the filesystem. This is consistent and has happened all times I have
tried it. fsck is not sufficient to repair the damage. Depending on the damage
I have been repairing it using clri and/or restoring files from backup and/or
running newfs + restore.  

In standby mode the screen is turned off, the disk stopped, and the clock to
the processor halted. Power to the board is maintained and refresh to memory
continues. When the laptop resumes it should start from the instruction where
it was halted. This workes under MS/DOS and I don't think I ever had any
problems with it on NetBSD 0.9 either.

Note that the disk stops and starts automatically to save power without doing
any harm.

The corruption seems to mainly hit the inodes. After a couple of the failures a
big bunch of consecutive inodes (~50) were damaged with wild filesizes, modes,
access times, etc. Some have been so bad that I have had to use 'clri' to
remove them. The corruption also seems to hit the first data I access after a
standby pause. Eg. running a 'w' as the first command corrupted a lot of inodes
in the /dev directory including /dev/kmem. Actually 'w' stopped reporting that
/dev/kmem was a bad device.

Btw, this is NO upgrade from 0.9 but a full from scratch 1.0 installation.

>How-To-Repeat:
Take a Compaq portable into standby mode and back again.
>Fix:
Currently avoid using standby mode! 

>Audit-Trail:
>Unformatted: