From owner-freebsd-net@FreeBSD.ORG Fri May 10 05:03:08 2013 Return-Path: Delivered-To: freebsd-net@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 75A8C1DD for ; Fri, 10 May 2013 05:03:08 +0000 (UTC) (envelope-from scrappy@hub.org) Received: from hub.org (hub.org [200.46.208.146]) by mx1.freebsd.org (Postfix) with ESMTP id 419ABD08 for ; Fri, 10 May 2013 05:03:08 +0000 (UTC) Received: from maia.hub.org (unknown [200.46.151.188]) by hub.org (Postfix) with ESMTP id ECD2117C5AC5 for ; Fri, 10 May 2013 02:03:04 -0300 (ADT) Received: from hub.org ([200.46.208.146]) by maia.hub.org (mx1.hub.org [200.46.151.188]) (amavisd-maia, port 10024) with ESMTP id 62770-03 for ; Fri, 10 May 2013 05:03:03 +0000 (UTC) Received: from Marc-Fourniers-Mac-mini.local (S01067cb21b2ff4ca.gv.shawcable.net [24.108.26.71]) by hub.org (Postfix) with ESMTPA id 838E617C5AC4 for ; Fri, 10 May 2013 02:03:03 -0300 (ADT) Message-ID: <518C7F85.3000405@hub.org> Date: Thu, 09 May 2013 22:03:01 -0700 From: "Marc G. Fournier" User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:17.0) Gecko/20130328 Thunderbird/17.0.5 MIME-Version: 1.0 To: freebsd-net@freebsd.org Subject: status of a tap device ... Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 10 May 2013 05:03:08 -0000 Quick question ... is there a command I can run that will tell me if a tap device is open? I know I can do 'ifconfig tap0' and see the 'Opened by' line, but I want to do this within a perl script, for instance, akin to how I can use the fstat function to get information about a file ... Rather avoid re-creating the wheel, so to say, if its already been created ... Thx