-
#!/bin/bash
-
-
rm -rf wgw.txt
-
for((i=1;i<=10;i++))
-
do
-
for((j=1;j<=99;j++))
-
do
-
printf "interface mgt0 dhcp-server ip-binding 192.168.%02d.%02d 11-22-33-44-%02d-%02d\n" $i $j $i $j >> wgw.txt
-
done
-
done
printf可以格式化输出,echo不行,%02d表示不足位用0顶替
阅读(616) | 评论(0) | 转发(0) |