Information Tvheadend - The Saga Continues
#16
(2024-05-01, 13:35)petediscrete Wrote:
(2024-04-30, 19:10)oldtvwatcher Wrote: I just wanted to make a comment here about the latest Linux version of Tvheadend available through the apt repository.  We've been using Tvheadend for over a decade, but recently an old machine that ran Linux at a relative's home was on its last legs so for a replacement we got a used Optiplex and put Ubuntu 22.04 server on it and installed the latest Tvheadend using the apt repository.

Well in all previous installs, Tvheadend created a hts user and group, and a /home/hts directory, but now it seems to want to put everything in /var/lib/tvheadend.  That causes permissions issues with other things.  For example, on that system all the recordings were saved to an external hard drive, and Tvheadend just couldn't see it no matter what we did.  Finally we figured out that mounting the drive in the /var/lib/tvheadend directory tree allowed Tvheadend to find and use it.  A bit unorthodox but whatever works, right? We aren't Linux geniuses here so maybe there is a better way to do that but if so we don't know how.

And that was fine until a couple days ago when an update appeared in the Tvheadend repository, and it installed while doing a normal sudo apt update && sudo apt upgrade.  And then Tvheadend just stopped working.  If we ran top we could see it running, but nothing could access it.

To make a long story short, we discovered that apparently when Tvheadend installs an update and then restarts, it attempts to create a backup of the existing configuration by making a .tar.gz file in /var/lib/tvheadend/backup.  It is smart enough to not try to backup the backup directory (at least I would hope so) but it is not smart enough to ignore any added directories in the /var/lib/tvheadend directory tree, including that mounted external HD volume.  So, yes, it was trying to back up all the recordings of TV shows!  So when we discovered this, it was five hours later and it was still trying to create that backup (which would probably have never succeeded because it would have run out of drive space first).

The way we got around this was to stop Tvheadend and to delete the partial archive file, then create a DIRECTORY with the same name as the archive it was trying to create, and then marking that directory as unwriteable. Linux generally won't let you overwrite an existing directory with a file, so that prevented the archive from being created and I assume that Tvheadend just accepted that error and moved on.  Before we created that directory, every time we restarted Tvheadend or rebooted it just kept trying to start over with creating that archive.  It would have been nice to have the archive if it had been confined to the directory tree that Tvheadend installs, and not any directories that the user is forced to add because of the (IMHO) dumb decision to move away from running Tvheadend under the hts user.  Maybe there was some change in Ubuntu or Debian that forced that, I don't know, but it has definitely caused a few headaches.

For now we've just commented out Tvheadend's entry in the apt sources list so this can't happen again.  I fully admit that there may have been a better way to work around the problem of Tvheadend not seeing the external drive, or a better way to recover from this problem, but we are just computer users, not Linux gurus.  Usually Ubuntu server and Tvheadend have been stable enough that we haven't had problems like this in the past, but for some reason when things are working fine it always seems someone feels the need to make some major change that breaks things. I am not pointing fingers at anyone in particular, but if I had to guess I would first suspect Canonical of breaking something which then forced the change in Tvheadend. I've about had it with Ubuntu anyway, I think from now on when bringing up a server I'll just use Debian, or maybe MX Linux if they offer a server version (don't think they do but haven't looked into it).  Anyway I just wanted to let others know about this in case you suddenly have a non-responsive Tvheadend after an apt update.  Sorry if I am grousing a little but chasing down that problem was not how I wanted to spend my Sunday morning!!! No

P.S. It occurs to me now that maybe if that external drive had been mounted in the /var/lib/tvheadend/backup dir, MAYBE Tvheadend would have ignored it when trying to back itself up.  But of course we had no way of knowing that at the time it was mounted in /var/lib/tvheadend.

If you’ve been keeping up with the TVHeadend project you’ll have seen all these changes made that you are referring to both here https://github.com/tvheadend/tvheadend/issues and here https://tvheadend.org/

There’s absolutely no point in posting your dislike of changes made to the TVHeadend project on the Kodi forum and hoping that you’ll get attention or some form of traction on the matter.

You know where you should be posting your concerns and if you feel so strongly maybe you could join the project and contribute back to it instead of complaining. The guys on the Kodi forum are busy enough dealing with matters relating to Kodi to be getting involved in this.
I'm sorry if I left you under the impression that I was asking for help, or "hoping that [I'd] get attention or some form of traction on the matter".  I use both Kodi AND Tvheadend, and because this sub-forum exists I THOUGHT it was okay to talk about Tvheadend here.  If you don't want people talking about Tvheadend issues then why does this sub-forum even exist?  My goal in posting was just to let people know of these changes and the side effects.  No, I'm not particularly happy about the changes but I was not expecting anyone here to do anything about them, I doubt any Tvheadend developers even frequent this forum, and besides they may have been forced to make those changes due to changes in Ubuntu (which I also hate but that's totally irrelevant).

That said, it's condescending replies such as your last paragraph that make people want to just ignore forums altogether and turn to an AI for help instead.  Because even though an AI may not know what it is talking about for now, soon it may, and people will not post in forums if they are just going to get talked down to as if they were a naughty child! And THEN who will you find to denigrate?  I am not a coder so it's not like I can make any meaningful contribution to the Tvheadend project, but let's talk about this project, Kodi.  How many users do you think Kodi has, and out of that number, what percentage do you think are even capable of joining the project and contributing back in a way that would not annoy someone like you (who obviously doesn't want to hear any "complaining")?  And what percentage actually has contributed back?  So why would just just assume that someone telling you about an issue with Tvheadend has the ability to "join the project and contribute back"?

Also (responding to Prof Yaffle), some forum mods don't like it when you make a new thread if you topic is covered in an existing one, and my memory is not good enough to remember which forums want you to make new threads and which don't.  Mods, feel free to move my post to another thread if you think that would help, or to delete them entirely if they are really that offensive.
Reply

Logout Mark Read Team Forum Stats Members Help
Tvheadend - The Saga Continues0