if __name__ == '__main__':
hostname = socket.getfqdn().lower()
+ realm = file('/etc/invirt/realm').read().strip()
+ principal = 'host/'+hostname+'@'+realm
config = '\n'.join('console %s { master %s; }' % (vm, hostname)
for vm in live_vms())
f = open('/etc/conserver/sipb-xen-consoles.cf', 'w')
f.close()
reload_conserver()
subprocess.call(['/usr/bin/kinit', '-k', '-t', '/etc/krb5.keytab',
- 'host/'+hostname+'@ATHENA.MIT.EDU'])
+ principal])
subprocess.call(['/usr/bin/remctl', 'sipb-xen-console.mit.edu',
'console', 'update', config])