update from RELEASE to STABLE changed /dev/ad or geom behavior?
mike at jellydonut.org
Thu Aug 16 10:27:09 PDT 2007
To fix a bug in PF I recently updated my home firewall platform (a
shrunk-down install of FreeBSD 6 on a CompactFlash card mounted
read-only as /dev/ad0a) from the RELENG_6_2 to the RELENG_6 branch. All
went very well there and the PF problem is resolved, but now I've run
across a new issue.
Previously, when updating my CompactFlash image "in the field", I would
boot the system into single-user mode via serial console, setup a small
memory filesystem big enough to hold gzip, dd, and reboot (and their
required libraries, with LD_LIBRARY_FLAGS set appropriately), copy the
new flash image to the mfs, and run (from the MFS) "gzip -dc <flashimage
| dd of=/dev/ad0 bs=8k" and then run "reboot -lnq" to reboot into the
This all worked well and good until the update to RELENG_6, and now I
see the following when I try to dd the new image:
# sysctl kern.geom.debugflags=16
kern.geom.debugflags: 0 -> 16
# gzip -dc <flashimage | dd of=/dev/ad0 bs=8k
dd: /dev/ad0: Invalid argument
298+1 records in
298+0 records out
1220608 bytes transferred in 1.330433 secs (917452 bytes/sec)
With the above kern.geom.debugflags sysctl, I thought I would have the
ability to directly write to /dev/ad0 via dd, and this was the case with
RELENG_6_2. Is this no longer the case? Didn't see anything in
/usr/src/UPDATING to indicate any sort of change, and I'm not sure where
in the RELENG_6 code this would exist (GEOM perhaps)?
Anyone have any ideas or suggestions as to why this doesn't work anymore?
More information about the freebsd-stable