Merge "Move router advertisement daemon restarts to privsep."
This commit is contained in:
commit
7e98253729
|
@ -1060,11 +1060,8 @@ interface %s
|
|||
else:
|
||||
LOG.debug('Pid %d is stale, relaunching radvd', pid)
|
||||
|
||||
cmd = ['radvd',
|
||||
'-C', '%s' % _ra_file(dev, 'conf'),
|
||||
'-p', '%s' % _ra_file(dev, 'pid')]
|
||||
|
||||
_execute(*cmd, run_as_root=True)
|
||||
nova.privsep.linux_net.start_ra(_ra_file(dev, 'conf'),
|
||||
_ra_file(dev, 'pid'))
|
||||
|
||||
|
||||
def _host_lease(fixedip):
|
||||
|
|
|
@ -340,3 +340,11 @@ def _restart_dnsmasq_inner(flag_file, network_ref, config_file, pid_path,
|
|||
cmd.append('--addn-hosts=%s' % hosts_path)
|
||||
|
||||
processutils.execute(*cmd)
|
||||
|
||||
|
||||
@nova.privsep.sys_admin_pctxt.entrypoint
|
||||
def start_ra(conf_path, pid_path):
|
||||
cmd = ['radvd',
|
||||
'-C', '%s' % conf_path,
|
||||
'-p', '%s' % pid_path]
|
||||
processutils.execute(*cmd)
|
||||
|
|
Loading…
Reference in New Issue