try fstat(1) - you won't need to install anything then.

On Mon, May 15, 2006 at 10:21:26PM +0200, RedShift wrote:
> Can you show us the output of lsof?
> 
> Peter Philipp wrote:
> >Hi,
> >
> >I have an ibook that has a broken ata controller and thus I boot and run 
> >the OS
> >off an USB stick.  It ran fine for months on a 512 MB stick until 3.9 which
> >increased the size (I think of the libraries) of OpenBSD, I switched to a 
> >1 gig
> >stick which surprisingly came down in cost the last little while.
> >
> >I've configured the system to use disk as little as possible, it uses a 
> >small
> >MFS for /tmp, processes like cron are disabled, syslogd writes to its 
> >memory
> >ringbuffers, filesystems when possible are noatime.  However on the led on 
> >the
> >USB stick I notice a disk operation every 3 seconds or so.  I ktraced every
> >process and found that none is writing or reading, so it must come from the
> >kernel.  What operation in the kernel causes reads / writes like this?  I
> >originally thought update does this but I'm sorta skeptical since there is 
> >nothing to write/sync to the filesystem..
> >
> >Here is some data if it helps any..
> >
> >$ df -h
> >Filesystem     Size    Used   Avail Capacity  Mounted on
> >/dev/sd0a      815M    515M    259M    67%    /
> >mfs:21581     15.7M    6.0K   14.9M     0%    /tmp
> >$ mount
> >/dev/sd0a on / type ffs (local, noatime)
> >mfs:21581 on /tmp type mfs (asynchronous, local, nodev, nosuid, size=32768 
> >512-blocks)
> >$ ps ax
> >  PID TT   STAT      TIME COMMAND
> >    1 ??  Is      0:00.01 /sbin/init
> >21581 ??  Is      0:00.02 /sbin/mount_mfs -o rw -s 32768 -o nodev -o 
> >nosuid /dev/sd0
> > 2635 ??  Is      0:00.01 dhclient: gem0 (dhclient)
> > 6060 ??  Is      0:00.01 syslogd: [priv] (syslogd)
> >25663 ??  I       0:00.23 syslogd -a /var/empty/dev/log -s 
> >/var/run/syslogd.sock -a
> >  193 ??  Is      0:00.01 /usr/sbin/apmd
> >11319 ??  Is      0:13.87 SCREEN (screen)
> > 6351 p0  Is      0:00.08 /bin/ksh
> >29520 p0  I+      0:00.06 /usr/bin/cu -l /dev/cuaU0 -s 9600
> >25830 p0  I+      0:01.30 /usr/bin/cu -l /dev/cuaU0 -s 9600
> > 3676 p1  Is      0:00.07 /bin/ksh
> > 4394 p1  R+      0:00.01 ps -ax
> >11940 C0- I       0:00.00 dhclient: gem0 [priv] (dhclient)
> >12415 C0  Is      0:01.10 -ksh (ksh)
> >24495 C0  I+      0:00.03 screen
> >$
> >
> >[ using 338996 bytes of bsd ELF symbol table ]
> >console out [ATY,RageM3p29s]console in [keyboard] ADB found
> >: memaddr 94000000 size 4000000, : consaddr 96008000, : ioaddr 90020000, 
> >size 20000: memtag 8000, iotag 8000: width 1024 linebytes 1024 height 768 
> >depth 8
> >Copyright (c) 1982, 1986, 1989, 1991, 1993
> >        The Regents of the University of California.  All rights reserved.
> >Copyright (c) 1995-2006 OpenBSD. All rights reserved.  
> >http://www.OpenBSD.org
> >
> >OpenBSD 3.9 (GENERIC) #853: Tue Feb 28 22:42:40 MST 2006
> >    [EMAIL PROTECTED]:/usr/src/sys/arch/macppc/compile/GENERIC
> >real mem = 134217728 (131072K)
> >avail mem = 110862336 (108264K)
> >using 1254 buffers containing 6709248 bytes (6552K) of memory
> >mainbus0 (root): model PowerBook4,1
> >cpu0 at mainbus0: 750 (Revision 0x2214): 499 MHz: 256KB backside cache
> >memc0 at mainbus0: uni-n
> >ki2c0 at memc0 offset 0xf8001000
> >iic0 at ki2c0
> >mpcpcibr0 at mainbus0 pci: uni-north, Revision 0xff
> >pci0 at mpcpcibr0 bus 0
> >pchb0 at pci0 dev 11 function 0 "Apple Pangea AGP" rev 0x00
> >vgafb0 at pci0 dev 16 function 0 "ATI Mobility M3" rev 0x02, mmio
> >wsdisplay0 at vgafb0 mux 1: console (std, vt100 emulation)
> >mpcpcibr1 at mainbus0 pci: uni-north, Revision 0x0
> >pci1 at mpcpcibr1 bus 0
> >pchb1 at pci1 dev 11 function 0 "Apple Pangea" rev 0x00
> >macobio0 at pci1 dev 23 function 0 "Apple Pangea Macio" rev 0x00
> >openpic0 at macobio0 offset 0x40000: version 0x4614
> >macgpio0 at macobio0 offset 0x50
> >macgpio1 at macgpio0 irq 47
> >"programmer-switch" at macgpio0 not configured
> >"firewire-linkon" at macgpio0 not configured
> >"gpio1" at macgpio0 not configured
> >"gpio9" at macgpio0 not configured
> >"extint-gpio4" at macgpio0 not configured
> >"extint-gpio12" at macgpio0 not configured
> >"escc-legacy" at macobio0 offset 0x12000 not configured
> >zsc0 at macobio0 offset 0x13000: irq 22,23
> >zstty0 at zsc0 channel 0
> >zstty1 at zsc0 channel 1
> >tumbler0 at macobio0 offset 0x10000: irq 30,1,2
> >"timer" at macobio0 offset 0x15000 not configured
> >adb0 at macobio0 offset 0x16000 irq 25: via-pmu, 3 targets
> >akbd0 at adb0 addr 2: PowerBook G4 keyboard (Inverted T)
> >wskbd0 at akbd0: console keyboard, using wsdisplay0
> >ams0 at adb0 addr 3: EMP trackpad <tpad> 2-button, 400 dpi
> >wsmouse0 at ams0 mux 0
> >abtn0 at adb0 addr 7: brightness/volume/eject buttons
> >apm0 at adb0: battery flags 0x5, 100% charged
> >"battery" at macobio0 offset 0x0 not configured
> >"backlight" at macobio0 offset 0xf300 not configured
> >ki2c1 at macobio0 offset 0x18000
> >iic1 at ki2c1
> >wdc0 at macobio0 offset 0x1f000 irq 19: DMA
> >wd0 at wdc0 channel 0 drive 0: <IBM-IC25N015ATDA04-0>
> >wd0: 16-sector PIO, LBA, 14403MB, 29498112 sectors
> >wd0(wdc0:0:0): using PIO mode 4, DMA mode 2, Ultra-DMA mode 4
> >audio0 at tumbler0
> >ohci0 at pci1 dev 24 function 0 "Apple Pangea USB" rev 0x00: irq 27, 
> >version 1.0
> >usb0 at ohci0: USB revision 1.0
> >uhub0 at usb0
> >uhub0: Apple OHCI root hub, rev 1.00/1.00, addr 1
> >uhub0: 2 ports with 2 removable, self powered
> >ohci1 at pci1 dev 25 function 0 "Apple Pangea USB" rev 0x00: irq 28, 
> >version 1.0
> >usb1 at ohci1: USB revision 1.0
> >uhub1 at usb1
> >uhub1: Apple OHCI root hub, rev 1.00/1.00, addr 1
> >uhub1: 2 ports with 2 removable, self powered
> >mpcpcibr2 at mainbus0 pci: uni-north, Revision 0x16
> >pci2 at mpcpcibr2 bus 0
> >pchb2 at pci2 dev 11 function 0 "Apple Pangea PCI" rev 0x00
> >"Apple Pangea FireWire" rev 0x00 at pci2 dev 14 function 0 not configured
> >gem0 at pci2 dev 15 function 0 "Apple Pangea GMAC" rev 0x00: irq 41, 
> >address 00:03:93:14:3f:be
> >bmtphy0 at gem0 phy 0: BCM5221 100baseTX PHY, rev. 3
> >uplcom0 at uhub1 port 1
> >uplcom0: ATEN International Serial, rev 1.10/0.01, addr 2
> >ucom0 at uplcom0
> >umass0 at uhub0 port 1 configuration 1 interface 0
> >umass0: CHEER USB_DISK, rev 2.00/2.00, addr 2
> >umass0: using SCSI over Bulk-Only
> >scsibus0 at umass0: 2 targets
> >sd0 at scsibus0 targ 1 lun 0: <CHEER, USB_DISK, 1.00> SCSI2 0/direct 
> >removable
> >sd0: 1010MB, 1010 cyl, 64 head, 32 sec, 512 bytes/sec, 2069760 sec total
> >bootpath: '/[EMAIL PROTECTED]/[EMAIL PROTECTED]/[EMAIL PROTECTED]/bsd'
> >string [/[EMAIL PROTECTED]/[EMAIL PROTECTED]/bsd] not found
> >Warning: bootpath unrecognized: /[EMAIL PROTECTED]/[EMAIL PROTECTED]/[EMAIL 
> >PROTECTED]/bsd
> >boot device: lookup '' failed.
> >root device : sd0
> >swap device (default sd0b):
> >root on sd0a
> >usb_transfer_complete: xfer=0xe01fb680 not busy 0x42555359
> >rootdev=0x200 rrootdev=0x800 rawdev=0x802
> >wd0(wdc0:0:0): timeout
> >        type: ata
> >        c_bcount: 0
> >        c_skip: 0
> >$
> >
> >Cheers,
> >
> >-p

Reply via email to