On Tue, Aug 04, 2009 at 04:41:40PM +0700, Rashid N. Achilov wrote:
> This leads to destroy any MBR geoms for da0 and reconstruct it again. But I 
> think, that is extremely radical way - open raw device for writing. Is there 
> any less radical way to detect inserted flash? 

I have a little script that I run to prod my card reader(s):

#!/bin/sh
sudo smartctl -a /dev/da${1} -T permissive
sudo smartctl -a /dev/da${1} -T permissive
dd if=/dev/null of=/dev/da${1} count=0
mount_msdosfs /dev/da${1}s1 ~/usb

I pass in the device number (da6 would have 6...).  HTH

-- 

Richard Kolkovich
[email protected]

Attachment: pgpn8UCpieDOn.pgp
Description: PGP signature

Reply via email to