| Revision: | 1.1 |
| Committed: | Sun Apr 13 16:00:31 2003 UTC (23 years, 1 month ago) by pcg |
| Branch: | MAIN |
| CVS Tags: | rel-1_9, rel-1_8, rel-2_01, poll-based-iom, rel-3_0, VPE_0_9, VPE_1_2, rel-2_2, rel-2_0, VPE_1_4, VPE_1_6, rel-1_7, VPE-1_6_1, rel-2_21, rel-2_22, rel-2_25, VPE_1_0, HEAD |
| Log Message: | *** empty log message *** |
| # | Content |
|---|---|
| 1 | #!/bin/sh |
| 2 | |
| 3 | # Some environment variables will be set (in addition the ones |
| 4 | # set in if-up, too): |
| 5 | # |
| 6 | # DESTNODE=doom # others nodename |
| 7 | # DESTID=5 # others node id |
| 8 | # DESTIP=188.13.66.8 # others ip |
| 9 | # DESTPORT=407 # others port |
| 10 | # STATE=up/down # node-up gets UP, node-down script gets DOWN |
| 11 | |
| 12 | if [ $STATE = up ]; then |
| 13 | { |
| 14 | echo update delete $DESTNODE.lowttl.example.com. a |
| 15 | echo update delete $DESTNODE-last.lowttl.example.com. a |
| 16 | echo update add $DESTNODE.lowttl.example.com. 1 in a $DESTIP |
| 17 | echo update add $DESTNODE-last.lowttl.example.com. 1 in a $DESTIP |
| 18 | echo |
| 19 | } | nsupdate -d -k $CONFBASE:marc.example.net. |
| 20 | else |
| 21 | { |
| 22 | echo update delete $DESTNODE.lowttl.example.com. a |
| 23 | echo update delete $DESTNODE-last.lowttl.example.com. a |
| 24 | echo update add $DESTNODE-last.lowttl.example.com. 1 in a $DESTIP |
| 25 | echo |
| 26 | } | nsupdate -d -k $CONFBASE:marc.example.net. |
| 27 | fi |
| 28 |