livepatch-charmers team mailing list archive
-
livepatch-charmers team
-
Mailing list archive
-
Message #00017
[Merge] ~barryprice/canonical-livepatch-charm/+git/canonical-livepatch-charm:master into canonical-livepatch-charm:master
Barry Price has proposed merging ~barryprice/canonical-livepatch-charm/+git/canonical-livepatch-charm:master into canonical-livepatch-charm:master.
Commit message:
If ksplice is installed, let's cowardly refuse to install livepatch
Requested reviews:
Livepatch charm developers (livepatch-charmers)
For more details, see:
https://code.launchpad.net/~barryprice/canonical-livepatch-charm/+git/canonical-livepatch-charm/+merge/325816
--
Your team Livepatch charm developers is requested to review the proposed merge of ~barryprice/canonical-livepatch-charm/+git/canonical-livepatch-charm:master into canonical-livepatch-charm:master.
diff --git a/reactive/canonical_livepatch.py b/reactive/canonical_livepatch.py
index 8bdb830..c2fb420 100644
--- a/reactive/canonical_livepatch.py
+++ b/reactive/canonical_livepatch.py
@@ -218,8 +218,12 @@ def canonical_livepatch_connect():
universal_newlines=True).strip()
current = LooseVersion(uname)
required = LooseVersion('4.4')
- if current < required:
- hookenv.log('We need to reboot, kernel {} is too old'.format(current))
+ uptrack_path = '/usr/sbin/uptrack-upgrade'
+ if path.exists(uptrack_path):
+ hookenv.log('Ksplice/Uptrack detected, please remove it and reboot')
+ unit_update('blocked', 'Remove ksplice and then reboot')
+ elif current < required:
+ hookenv.log('Reboot required, kernel {} is too old'.format(current))
unit_update('blocked', 'A reboot is required')
else:
unit_update('maintenance', 'Connecting to the livepatch service')
Follow ups