Kodi randomly reset my settings
#1
Hi!

I'm a newbie in Kodi and the wonderful world of media centers... I recently built one by installing Kodi on OSMC on a Raspberry Pi 2 B.

I feed it with all my movies and really enjoy it!

My issue is this: randomly when I turn on the Pi, Kodi opens on the default skin and I can see that he forgot every setting I set. I looked for someone having the same issue, but system or context were each time different.

Did someone have the same issue? Is there some fix, or a process to avoid this settings loss?

Excuse my english, I'm a french fan Big Grin
Reply
#2
Sounds like file system corruption, specifically the guisettings.xml file (probably).

How are you shutting down the Pi? Are you selecting "Power off" from the Kodi menu, or are you turning off the power supply at the wall/pulling the power cable while the Pi is still running Kodi?

Also worth a try is a different (more powerful) PSU and different USB cable - make sure it's not too thin as cheap cables can result in too much voltage drop.

If you ever see a rainbow-coloured square in the top right of the display (or the red power LED turns off) then your PSU is not supplying enough voltage.
Texture Cache Maintenance Utility: Preload your texture cache for optimal UI performance. Remotely manage media libraries. Purge unused artwork to free up space. Find missing media. Configurable QA check to highlight metadata issues. Aid in diagnosis of library and cache related problems.
Reply
#3
Quote:Sounds like file system corruption, specifically the guisettings.xml file (probably).
That's what I supposed after some research.

Quote:How are you shutting down the Pi? Are you selecting "Power off" from the Kodi menu, or are you turning off the power supply at the wall/pulling the power cable while the Pi is still running Kodi?
I select Power off, then the screen gets black. The green light flashes for a few seconds then turn off, so I pull the cable.

Quote:Also worth a try is a different (more powerful) PSU and different USB cable - make sure it's not too thin as cheap cables can result in too much voltage drop.
I bought this : http://www.amazon.fr/dp/B00U88KSHO/ref=p...71_TE_dp_1 which seems specially made for R-Pi 2 (the one I bought)...

Quote:If you ever see a rainbow-coloured square in the top right of the display (or the red power LED turns off) then your PSU is not supplying enough voltage.
I heard about that rainbow thing, but never saw it. And the red light never turn off.

Next time I'll see the issue, I will look at the logs if I can. Meanwhile, every idea is welcome Smile
Reply
#4
What memory card are you using?
Make sure its at least a class 6 or class 10 ideally.
I would think that it may be a error on your memory card if you have a spare make a complete copy of your card and write it onto a new card and see if it works on there.
Reply
#5
It's a class 10 (this one: http://www.amazon.fr/dp/B010NE3ND8/ref=p...71_TE_dp_4).

I looked carefully at the hardware I bought to prevent these kinds of problem.

I will try to get another card to try what you suggest.

If it can help, I had the feeling that settings were reset when any update was made (I think, without warranty at all, that each time my settings are gone, a message bar shows "[random feature] was updated", but I can be wrong).
Reply
#6
Its possible that a update is causing it.
Make sure OSMC automatic updates are turned off most addons have a option to turn off automatic updates also.
Once all the automatic updates are turned off on everything do a few reboots and see if anything happens and if it seems to be working OK you could then turn on automatic updates on one at a time and see which one causes it to mess up.
Would be best turning on Kodi debug log and reading what happens on startup.
Reply
#7
I think it's best to report this in OSMC forum. I think it is OSMC specific. There are a few posts about it:
https://discourse.osmc.tv/t/kodi-occasio...eboot/6953
https://discourse.osmc.tv/t/skin-regular...-vero/6902
Reply
#8
Thank you, I didn't see this thread (probably because I used "Kodi" as keyword and not OSMC).

Vviljanen and Kilobyte seems to have exactly the same issue. I'll try that way.
Reply
#9
Hi

I believe I identified and fixed the issue in this commit: https://github.com/osmc/osmc/commit/192d...7baf55d4e8.

There are some race conditions in the way the Kodi shutdown process operates. As such, to guarantee reboots do not hang, we signal the logind event before invoking the Kodi tear down process (g_application.Stop()). This could sometimes cause a reboot as guisettings.xml was being written. We now ensure that the SIGTERM handler properly ensures settings are written properly and in plenty of time before reboot occurs.

This will be in our Kodi 15.1 release which is scheduled for this Sunday. We are currently experiencing a network outage but this is not expected to impact the release date.

Thanks

Sam
Reply
#10
I didn't see the issue for a few days, so I cross my fingers and wait for this release.

(Excuse the newbie : will Kodi automatically install this fix when it will be released?)
Reply
#11
It did again - fortunately, I saved my guisettings.xml.

I restored it and got my skin and settings back... but this problem is quite annoying...
Reply
#12
any solution to this issue yet? This happens to me over and over. Normally when I log out of one profile and into the next.
Reply
#13
I can't help you, it stopped just like it started and it never happened again.
Reply
#14
I've seen this as well on RPi3 and PRi2 running Arch ARM. It's more serious though in that when I reset estuary settings in the GUI, the corresponding file (~/.kodi/userdata/addon_data/skin.estuary/settings.xml) isn't consistently updated. My solution is to simply have a pre-setup settings.xml and a little script that copies it into place. Perhaps my cause is different that your cause.

Code:
#!/bin/bash
cp /var/lib/kodi/settings.xml /var/lib/kodi/.kodi/userdata/addon_data/skin.estuary/settings.xml
chown -R kodi:kodi /var/lib/kodi

EDIT: this only started happening when I switched of the the early betas of v17 and continues on RC3.
Need help programming a Streamzap remote?
Reply
#15
This is an old post, so I don't believe OSMC is affected anymore.

There are scenarios in CApplication where guisettings is written out multiple times. This increases the chance of corruption, especially if you have a systemd unit which will kill processes after a certain time if you call a reboot or shutdown. Kodi does not have a native sigterm handler.

We used to have a patch to prevent write out if the contents of guisettings.xml would be unchanged

This doesn't seem to be an issue anymore in OSMC after reworking our sigterm handler.

Assuming you are using systemd, make sure you are giving Kodi 30s before SIGKILL. There are some versions of systemd where this is not honoured and this is a regression.
Reply

Logout Mark Read Team Forum Stats Members Help
Kodi randomly reset my settings0