Plan 9 from Bell Labs’s /usr/web/sources/contrib/quanstro/sosether

Copyright © 2021 Plan 9 Foundation.
Distributed under the MIT License.
Download the Plan 9 distribution.


#!/bin/rc
rfork e

fn getlist{
	ethers = ()
	for(i in `{seq 0 15}){
		s = '#'l$i/ether$i
		if(test -d $s > /dev/null >[2=1])
			ethers = ($ethers $s)
	}
}

echo pci
pci | grep net
echo

echo interfaces
getlist;
for(i in $ethers)
	echo '	'^$i
echo

for(i in $ethers){
	echo $i ^ :
	echo stats:
	cat $i/stats | sed 's/^/	/g' 
	echo
	echo ifstats:
	cat $i/ifstats | sed 's/^/	/g' 
}

echo
echo kmesg:
cat /dev/kmesg

Bell Labs OSI certified Powered by Plan 9

(Return to Plan 9 Home Page)

Copyright © 2021 Plan 9 Foundation. All Rights Reserved.
Comments to webmaster@9p.io.