Generate new UUID?

I had openHAB running on a RasPi working great with my.opnehab. However if I make an image of the RasPI SD card and insert into another Pi (unsurprisingly) the UUID is the same. If I wanted to connect the 2nd Pi to a different My.OpenHAB account how can I do this if the UUID is the same?

Is it possible to generate a new UUID?

reinstall openhab via
sudo apt-get --reinstall install openhab

That schould be fine.
But, please keep a backup (the SD card image, in case you did some modifications outside the /configurations folder.
Then you have to replace the files that you changed-
The UUID ist also stored in the folder ~/webapps/static

You might be able to change it within this file, but i don’t know the specifications of the UUID
The secret could be changed much easier

Just stop openHAB, delete ~/webapps/static/uuid and restart openHAB. It will autogenerate a new uuid…

1 Like

Thanks a lot, worked a treat :thumbsup:

How can I change my uuid on my raspberry pi?

You obviously used the search function to find this thread, why didn’t you read it.

Call me a spoon feeder, but for those who are new to linux, here are the steps:

sudo service openhab2 stop
#If you installed openhab from the repository
sudo rm /var/lib/openhab2/uuid
sudo service openhab2 start


Sorry about my beginner’s question:
What is the entire order to delete UUID? For me it does not work ~/webapps/static/uuid
Do I have to do something else?

Thank you

LE: I succeeded in the steps described by @anjana55