Current Path : /usr/share/examples/netgraph/ |
FreeBSD hs32.drive.ne.jp 9.1-RELEASE FreeBSD 9.1-RELEASE #1: Wed Jan 14 12:18:08 JST 2015 root@hs32.drive.ne.jp:/sys/amd64/compile/hs32 amd64 |
Current File : //usr/share/examples/netgraph/raw |
#!/bin/sh # script to connect a raw synchronous card to a system interface. # Assumes the file if_sr was compiled with options NETGRAPH. # $FreeBSD: release/9.1.0/share/examples/netgraph/raw 222179 2011-05-22 14:23:48Z uqs $ CARD=sr0 # create an interface "ng0" and attach it to the sync port. # The packets had jolly well better be IP because we are not discriminating. ngctl mkpeer ${CARD}: iface rawdata inet # if ng0 already exists, use a CONNECT command instead of a mkpeer. e.g. # ngctl connect ${CARD}: ng0: rawdata inet # Then use ifconfig on interface ng0 as usual