From owner-freebsd-stable@FreeBSD.ORG Tue Feb 28 15:27:01 2012 Return-Path: Delivered-To: freebsd-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 20E94106564A for ; Tue, 28 Feb 2012 15:27:01 +0000 (UTC) (envelope-from alexander@leidinger.net) Received: from mail.ebusiness-leidinger.de (mail.ebusiness-leidinger.de [217.11.53.44]) by mx1.freebsd.org (Postfix) with ESMTP id A91FF8FC0C for ; Tue, 28 Feb 2012 15:27:00 +0000 (UTC) Received: from outgoing.leidinger.net (p5796C834.dip.t-dialin.net [87.150.200.52]) by mail.ebusiness-leidinger.de (Postfix) with ESMTPSA id 869BE844C52; Tue, 28 Feb 2012 16:26:44 +0100 (CET) Received: from webmail.leidinger.net (webmail.Leidinger.net [IPv6:fd73:10c7:2053:1::3:102]) by outgoing.leidinger.net (Postfix) with ESMTPS id C7CF411EF; Tue, 28 Feb 2012 16:26:41 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=leidinger.net; s=outgoing-alex; t=1330442801; bh=K+vll7s572TX7NzUgADs6iJUyyU7HgdKLfm72SOM0T8=; h=Date:Message-ID:From:To:Cc:Subject:References:In-Reply-To: Content-Type:MIME-Version; b=fjO35UtUTO5pfVzglI4nuRNGJhTC7mdchzN/xA2IMYSz6p7QqfgGt4OtnyVQoC8A3 +x8ciAkL2VOgKRAeOzofLTStzEDYTW/yBHJ7XaIYOTJxXMzMSzjzceh20Gsevc1fm2 oipDChxSIsltiWMQoQaxy7JxAQQXr2cGKe9mOQgNOqBCRd4Tcw/+hrYtUh71147KX8 mgolMVEaFDx8L0+L9FsczQb2SKrBw0i1hExEfwNd89HqHNPe/E3gTXv/4h7oH3I+U9 L5ncpt8tX1L1RCrcYAhEsJ0aG3LIQJnnfYMkLJEdVwyTj7wJfTxoPr0KVHqjV2O/dv Uzs269XYp3GeQ== Received: (from www@localhost) by webmail.leidinger.net (8.14.5/8.14.4/Submit) id q1SFQavP036149; Tue, 28 Feb 2012 16:26:36 +0100 (CET) (envelope-from Alexander@Leidinger.net) X-Authentication-Warning: webmail.leidinger.net: www set sender to Alexander@Leidinger.net using -f Received: from 85.94.224.19 ([85.94.224.19]) by webmail.leidinger.net (Horde Framework) with HTTP; Tue, 28 Feb 2012 16:26:36 +0100 Date: Tue, 28 Feb 2012 16:26:36 +0100 Message-ID: <20120228162636.Horde.JgORKJjmRSRPTPIsGKfo0uA@webmail.leidinger.net> From: Alexander Leidinger To: vermaden References: <4F3EE186.4020801@gmail.com> <201202181409.08859.hselasky@c2i.net> <20120226203949.H89643@sola.nimnet.asn.au> In-Reply-To: User-Agent: Internet Messaging Program (IMP) H4 (5.0.18) Content-Type: text/plain; charset=utf-8; format=flowed; DelSp=Yes MIME-Version: 1.0 Content-Disposition: inline X-EBL-MailScanner-Information: Please contact the ISP for more information X-EBL-MailScanner-ID: 869BE844C52.A189F X-EBL-MailScanner: Found to be clean X-EBL-MailScanner-SpamCheck: not spam, spamhaus-ZEN, SpamAssassin (not cached, score=-0.518, required 6, autolearn=disabled, AWL -0.41, DKIM_SIGNED 0.10, DKIM_VALID -0.10, DKIM_VALID_AU -0.10, T_RP_MATCHES_RCVD -0.01) X-EBL-MailScanner-From: alexander@leidinger.net X-EBL-MailScanner-Watermark: 1331047605.80459@qpVYR2aywm6gu1sPj2k/xA X-EBL-Spam-Status: No Cc: fidaj@ukr.net, freebsd-stable@freebsd.org, lars.engels@0x20.net, Hans Petter Selasky , smithi@nimnet.asn.au Subject: Re: devd based AUTOMOUNTER X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 28 Feb 2012 15:27:01 -0000 Quoting vermaden (from Mon, 27 Feb 2012 21:36:46 +0100): >> Unfortunately, I spent a few days that would >> have to understand how it is possible to >> detect the inserted CD-ROM with devd; but >> alas - the only thing that detects changes >> in the drive CD-ROM - a :sysctl kern.geom.conftxt >> >> before inserting the disc: >> kern.geom.conftxt: 0 DISK cd0 0 2048 hd 0 sc 0 >> ... >> >> after inserting the disc: >> kern.geom.conftxt: 0 DISK cd0 4700372992 2048 hd 0 sc 0 > > Thanks, at least we have 'something' we can cepend on. > > I can create an 'active wait' daemon for that, like the skel below: > > while sleep 3 > do > case $( sysctl -n kern.geom.conftxt ) in > (0 DISK cd0 0 2048 hd 0 sc 0) > echo "No CD in the drive ..." > # umount procedure ... > ;; > (0 DISK cd0 * * hd 0 sc 0) > echo "We have CD here!" > # do something about it lile mount_cd9660 > ;; > esac > done > > But a devd(8) event would be far better, maybe some somple commit to > devd(8) would help here? My knowledge does not allow me to add these > bits to devd(8). The kernel does not poll for CD changes, and the people guarding the relevant CD code where against something like this in the kernel everytime this came up in the past. So no devd event for this. Bye, Alexander. -- Back when I was a boy, it was 40 miles to everywhere, uphill both ways and it was always snowing. http://www.Leidinger.net Alexander @ Leidinger.net: PGP ID = B0063FE7 http://www.FreeBSD.org netchild @ FreeBSD.org : PGP ID = 72077137