2

This is the error message:

Failed to enable Livepatch: cannot enable machine: this machine ID is already enabled with a different key or is non-unique. Either "sudo canonical-livepatch disable" on the other machine, or regenerate a unique /etc/machine-id on this machine with "sudo rm /etc/machine-id /var/lib/dbus/machine-id && sudo systemd-machine-id-setup": {"error": "Conflicting machine-id"}

I can't get further after this. Can someone help please?

5 Answers5

2

A better option for fixing livepatch after upgrades to Ubuntu versions is to use the ua client, since it is able to reassociate an existing machine ID with the livepatch.

First check ua status and if it says "This machine is not attached to a UA subscription." then just go to https://ubuntu.com/advantage and get a new token for your account and attach it with ua attach $token. That fixed livepatch for me without having to regenerate the machine ID and thus take up another of the 3 free machines allowed for livepatch. (Also, if you're getting rid of a machine, make sure you disable livepatch on that machine first for the same reason.)

Cory Johns
  • 86
  • 2
  • 1
    This helped me in Ubuntu 20.04 while disabling livepatch, regenerating the machine-id, & enabling livepatch gave me the same error. Thanks! – saubhik Apr 14 '21 at 19:27
0

In case you do not have already three other machines connected to Livepatch (free-of-charge), please try the following:

  1. Run:

    sudo canonical-livepatch refresh
    
  2. In case it does not solve the problem, try to change your password of the machine and enable Livepatch.

  3. In case it does not solve the problem, you can consider re-installing your Ubuntu OS and give a new name and password to this machine. After installation, download all latest upgrades of the software and after all this enable Livepatch or run

    sudo canonical-livepatch refresh
    

    in the terminal.

With this PC I did all of the above and only after reinstalling the OS Livepatch works.

Eliah Kagan
  • 117,780
Kapel
  • 337
  • Hello , it tells me that livepatch is not enabled . I tried to enable it but it says " no key provided". Would it help when the next upgrade comes ? Thanks – Tanja Hild Aug 26 '19 at 17:37
  • 1
    Have you acquired (subscribed to) Livepatch token ? Please read these instructions: https://ubuntu.com/livepatch. Kapel – Kapel Aug 28 '19 at 03:51
0

I was having the same problem after reinstalling Ubuntu a few times on my machine, so using the command helped:

sudo rm /etc/machine-id /var/lib/dbus/machine-id && sudo systemd-machine-id-setup

After that I just had to enable again using the key provided on the live patch website https://ubuntu.com/security/livepatch You will see Free for personal use and a button under it Get Live Patch, just follow with your Ubuntu one account or Canonical account.

after you get the key just run

sudo canonical-livepatch enable key_provided_by_livepatch

Hope it helps someone.

Rck
  • 101
0

Try this on the Terminal:

$ sudo ua attach <token>
$ sudo ua enable livepatch

You can get your token from https://ubuntu.com/advantage.

Majal
  • 7,711
-1

Try this:

$ sudo ua detach
$ sudo ua attach <token>
andrew.46
  • 38,003
  • 27
  • 156
  • 232