Differences
This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision | ||
userdoc:tt-dhcpv6-prefix-delegation [2017/05/11 16:42] abelbeck [DHCPv6 Client Action Script] |
userdoc:tt-dhcpv6-prefix-delegation [2017/06/07 10:20] (current) abelbeck [DHCPv6 Client Action Script] |
||
---|---|---|---|
Line 27: | Line 27: | ||
Internal Interfaces: -> Interface: -> IPv6 Autoconfig: | Internal Interfaces: -> Interface: -> IPv6 Autoconfig: | ||
+ | !!Version ->!! AstLinux 1.2.5 to AstLinux 1.2.10 - '' | ||
{{: | {{: | ||
- | !!Tip -> | + | !!Version |
+ | {{: | ||
!!Note ->!! A " | !!Note ->!! A " | ||
- | |||
===== DHCPv6 Client Action Script ===== | ===== DHCPv6 Client Action Script ===== | ||
!!Note: AstLinux 1.2.10 or later is required!! | !!Note: AstLinux 1.2.10 or later is required!! | ||
+ | |||
+ | !!Note: AstLinux 1.3.0 or later!! executes a default action, additional custom actions can enabled if a custom script is defined. | ||
If an executable script exists at ''/ | If an executable script exists at ''/ | ||
Line 62: | Line 65: | ||
dhcp6c_prefix_len | dhcp6c_prefix_len | ||
+ | |||
+ | !!Note ->!! Do not expect all the variables to be always defined, though if '' | ||
Lastly, an indication whether the DHCPv6 update was different from the previous update: | Lastly, an indication whether the DHCPv6 update was different from the previous update: | ||
Line 69: | Line 74: | ||
The '' | The '' | ||
- | !!Note ->!! Do not expect all the variables to be always defined, though if '' | + | As an example, a simple script to log when the DHCPv6 lease is updated and whether it changed:\\ |
- | + | !!Note ->!! Occurs by default with AstLinux 1.3.0 or later | |
- | As an example, a simple script to log when the DHCPv6 lease is updated and whether it changed: | + | |
#!/bin/bash | #!/bin/bash | ||
| | ||
- | | + | |
- | logger -t dhcp6c -p kern.info "Updated with Prefix: $dhcp6c_prefix${dhcp6c_changed:+ changed=$dhcp6c_changed}" | + | |
- | fi | + | no) changed=" |
+ | *) changed="" | ||
+ | esac | ||
+ | | ||
===== Debugging DHCPv6 ===== | ===== Debugging DHCPv6 ===== | ||