Hi Lukasz,
I'm guessing you may need to specify things down to the individual interface
level if there isn't a direct mapping between interfaces - I don't simulate
my switches but I'm guessing you could do something like below which is a
version of what I use in my lab -
http://noshut.blogspot.com/2010/09/started-ipexpert-volume-1-workbook.html(the
shell script below is untested so possibly might have some typos but I
think you should be able to get the concept) I'm assuming your switch is a
router with 2 x 16 port switch blades installed..
TEMPFILE="/tmp/rework.sed"
if [ -f $TEMPFILE ]
then
rm $TEMPFILE
fi
for C in Cat*.txt
do
sed -e 's/FastEthernet0\/1/FastEthernet1\/1/gI' \
-e 's/FastEthernet0\/2/FastEthernet1\/2/gI' \
-e 's/FastEthernet0\/3/FastEthernet1\/3/gI' \
-e 's/FastEthernet0\/4/FastEthernet1\/4/gI' \
-e 's/FastEthernet0\/5/FastEthernet1\/5/gI' \
-e 's/FastEthernet0\/6/FastEthernet1\/6/gI' \
-e 's/FastEthernet0\/7/FastEthernet1\/7/gI' \
-e 's/FastEthernet0\/8/FastEthernet1\/8/gI' \
-e 's/FastEthernet0\/9/FastEthernet1\/9/gI' \
-e 's/FastEthernet0\/10/FastEthernet1\/10/gI' \
-e 's/FastEthernet0\/11/FastEthernet1\/11/gI' \
-e 's/FastEthernet0\/12/FastEthernet1\/12/gI' \
-e 's/FastEthernet0\/13/FastEthernet1\/13/gI' \
-e 's/FastEthernet0\/14/FastEthernet1\/14/gI' \
-e 's/FastEthernet0\/15/FastEthernet1\/15/gI' \
-e 's/FastEthernet0\/16/FastEthernet1\/16/gI' \
-e 's/FastEthernet0\/17/FastEthernet2\/1/gI' \
-e 's/FastEthernet0\/18/FastEthernet2\/2/gI' \
-e 's/FastEthernet0\/19/FastEthernet1\/11/gI' \
-e 's/FastEthernet0\/20/FastEthernet2\/12/gI' \
-e 's/FastEthernet0\/21/FastEthernet2\/13/gI' \
-e 's/FastEthernet0\/22/FastEthernet2\/14/gI' \
-e 's/FastEthernet0\/23/FastEthernet2\/15/gI' \
-e 's/FastEthernet0\/24/FastEthernet2\/16/gI' \
$C > $TEMPFILE
mv $TEMPFILE $C
done
Cheers,
Adam
On Wed, Jun 1, 2011 at 7:17 AM, Lukasz Szalacha <[email protected]> wrote:
> Hi All,
>
>
> I've managed to change the interfaces on the routers with:
>
> sudo sed 's/GigabitEthernet/FastEthernet/g' -i
> /root/IPexpert/configs/Vol-x/LAB-x/INITIAL/Rx.txt
>
> sudo sed 's/Serial0\//Serial/g' -i
> /root/IPexpert/configs/Vol-x/LAB-x/INITIAL/Rx.txt
>
>
> but I am not able to find a way to change quickly the interfaces on CatX
> devices. Is there magic syntax for that? :)
>
>
> Thanks,
> Lukasz
> _______________________________________________
> For more information regarding industry leading CCIE Lab training, please
> visit www.ipexpert.com
>
> Are you a CCNP or CCIE and looking for a job? Check out
> www.PlatinumPlacement.com
>
_______________________________________________
For more information regarding industry leading CCIE Lab training, please visit
www.ipexpert.com
Are you a CCNP or CCIE and looking for a job? Check out
www.PlatinumPlacement.com