EdgeRouter - 설정 변경 스크립트를 어떻게 사용할 수 있을까요? ================================================================= download at 2017-02-07T01:03:03Z `origin `_ 정답 ------ -------------- 터널 IP 주소를 변경하는 예제 스크립트를 작성해 봅시다. :: ubnt@ubnt:~$ cat change_tun_ip #!/bin/vbash if [ $# == 0 ]; then echo usage: $0 exit 1 fi new_ip=$1; source /opt/vyatta/etc/functions/script-template configure set interfaces tunnel tun0 local-ip $new_ip commit save exit EdgeRouter PoE 인터페이스의 PoE 설정을 활성화/비활성화하는 스크립트를 작성해봅시다: :: #!/bin/vbash if [ $# -ne 2 ]; then echo "usage: $0 [24v|48v|off]"; exit 1; fi intf=$1 val=$2 poe=`/usr/sbin/ubnt-hal-e hasPoeE` if [ "$poe" != 1 ]; then echo This platform does not support PoE; exit 1; fi source /opt/vyatta/etc/functions/script-template configure set interfaces ethernet $intf poe output $val commit save exit   \ `Vyatta's CLI shell API page `__. 페이지를 참조하면 shell-API에 대한 더 많은 정보를 확인할 수 있습니다. *UBNT-Stig* .. raw:: html
.. raw:: html .. raw:: html .. raw:: html