#!/bin/ksh ################### # Pass the vlan tag id as $1 # # ################### # create the entX device DEV=`mkdev -c adapter -s vlan -t` # create the enX device DE=`echo $DEV | cut -f1 -d" " | cut -c1,2,4-` /usr/lib/methods/defif -c if -t en -s EN -w $DE # create the etX device, not usually used DT=`echo $DEV | cut -f1 -d" " | cut -c1,3-` /usr/lib/methods/defif -c if -t en -s EN -w $DT # retrieve the entX name echo $DEV | while read ENT TRASH # set the vlan tag chdev -l $ENT -a vlan_tag_id=$1