1
0
mirror of https://github.com/altlinux/gpupdate.git synced 2025-03-23 22:50:17 +03:00

Improved logging on Kerberos errors

This commit is contained in:
Игорь Чудов 2020-09-11 18:58:42 +04:00
parent e9cf33855c
commit 66c2303069
Signed by untrusted user: nir
GPG Key ID: 0F3883600CAE7AAC

View File

@ -74,10 +74,13 @@ def check_krb_ticket():
try:
subprocess.check_call(['klist', '-s'])
output = subprocess.check_output('klist', stderr=subprocess.STDOUT).decode()
logging.info(output)
result = True
log('D17')
except:
log('E14')
logdata = dict()
logdata['output'] = output
log('D17', logdata)
except Exception as exc:
logdata = dict()
logdata['krb-exc'] = exc
log('E14', logdata)
return result