Ifconfig -v tap0 ? Does this work for you ?

Also upon opening a tap...

ifconfig tap create

Will return the numeric portion of the tap that was created with $?

So scripting it out it would be similar to...

ifconfig tap create && export MYTUNIS="$?"

echo "tap$MYTAPIS"

-- 
 Jason Hellenthal
 IS&T Services Professional
 Inbox: jhellent...@dataix.net
 JJH48-ARIN


On May 10, 2013, at 1:03, "Marc G. Fournier" <scra...@hub.org> wrote:

> 
> 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
> _______________________________________________
> freebsd-net@freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-net
> To unsubscribe, send any mail to "freebsd-net-unsubscr...@freebsd.org"
_______________________________________________
freebsd-net@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-net
To unsubscribe, send any mail to "freebsd-net-unsubscr...@freebsd.org"

Reply via email to