|
13 |
# few changes must be made to this file, if any. |
13 |
# few changes must be made to this file, if any. |
14 |
# |
14 |
# |
15 |
|
15 |
|
|
|
16 |
option rfc3442-classless-static-routes code 121 = array of unsigned integer 8; |
17 |
|
16 |
@!@ |
18 |
@!@ |
17 |
if configRegistry.is_true('dhclient/options/ddns', False): |
19 |
if configRegistry.is_true('dhclient/options/ddns', False): |
18 |
print 'send host-name "%s";' % configRegistry.get('hostname', '') |
20 |
print 'send host-name "%s";' % configRegistry.get('hostname', '') |
Lines 21-29
if configRegistry.is_true('dhclient/options/ddns', False):
|
Link Here
|
---|
|
21 |
else: |
23 |
else: |
22 |
print 'send fqdn.fqdn "%s.%s";' % (configRegistry.get('hostname', ''), configRegistry.get('domainname', '')) |
24 |
print 'send fqdn.fqdn "%s.%s";' % (configRegistry.get('hostname', ''), configRegistry.get('domainname', '')) |
23 |
if configRegistry.is_true('dhclient/options/ddns/serverupdate', True): |
25 |
if configRegistry.is_true('dhclient/options/ddns/serverupdate', True): |
24 |
print 'send fqdn.server-update on;' |
26 |
print 'send fqdn.server-update on;' |
25 |
else: |
27 |
else: |
26 |
print 'send fqdn.server-update off;' |
28 |
print 'send fqdn.server-update off;' |
27 |
print 'send fqdn.encoded on;' |
29 |
print 'send fqdn.encoded on;' |
28 |
@!@ |
30 |
@!@ |
29 |
#send host-name "andare.fugue.com"; |
31 |
#send host-name "andare.fugue.com"; |
Lines 32-46
if configRegistry.is_true('dhclient/options/ddns', False):
|
Link Here
|
---|
|
32 |
#supersede domain-name "fugue.com home.vix.com"; |
34 |
#supersede domain-name "fugue.com home.vix.com"; |
33 |
#prepend domain-name-servers 127.0.0.1; |
35 |
#prepend domain-name-servers 127.0.0.1; |
34 |
request subnet-mask, broadcast-address, time-offset, routers, |
36 |
request subnet-mask, broadcast-address, time-offset, routers, |
35 |
domain-name, domain-name-servers, host-name, |
37 |
domain-name, domain-name-servers, domain-search, host-name, |
36 |
netbios-name-servers, netbios-scope, interface-mtu; |
38 |
netbios-name-servers, netbios-scope, interface-mtu, |
|
|
39 |
rfc3442-classless-static-routes, ntp-servers; |
37 |
#require subnet-mask, domain-name-servers; |
40 |
#require subnet-mask, domain-name-servers; |
38 |
@!@ |
41 |
@!@ |
39 |
print 'timeout %s;' % configRegistry.get( 'dhclient/options/timeout', '30' ) |
42 |
print 'timeout %s;' % configRegistry.get( 'dhclient/options/timeout', '30' ) |
40 |
print 'retry %s;' % configRegistry.get( 'dhclient/options/retry', '60' ) |
43 |
print 'retry %s;' % configRegistry.get( 'dhclient/options/retry', '60' ) |
41 |
@!@ |
44 |
@!@ |
42 |
# reboot + timout should be below the 45 secs that NetworkManager waits before terminating dhclient, otherwise fallback script is not run |
45 |
# reboot + timout should be below the 45 secs that NetworkManager waits before terminating dhclient, otherwise fallback script is not run |
43 |
reboot 5; |
46 |
reboot 5; |
44 |
#select-timeout 5; |
47 |
#select-timeout 5; |
45 |
#initial-interval 2; |
48 |
#initial-interval 2; |
46 |
#script "/etc/dhcp3/dhclient-script"; |
49 |
#script "/etc/dhcp3/dhclient-script"; |
Lines 78-84
if configRegistry.is_true('dhclient/linklocal/fallback', True):
|
Link Here
|
---|
|
78 |
iface = k.split('/')[1] |
81 |
iface = k.split('/')[1] |
79 |
r1 = random.randrange(0, 255) # 0 to 254 |
82 |
r1 = random.randrange(0, 255) # 0 to 254 |
80 |
r2 = random.randrange(0, 255) # 0 to 254 |
83 |
r2 = random.randrange(0, 255) # 0 to 254 |
81 |
|
84 |
|
82 |
d = datetime.fromtimestamp(time.time() + (6*3600)) # expire in six hours |
85 |
d = datetime.fromtimestamp(time.time() + (6*3600)) # expire in six hours |
83 |
|
86 |
|
84 |
print 'lease {' |
87 |
print 'lease {' |