TVHeadend vs Plex Media Server on same server, sharing one PCIe Tuner card

My set up today
A Ubuntu server with a Hauppauge Dual tuner PCIe card running TVHeadend (back end) and a Plex Server.
A couple of HTPC:s running Kodi, as client for wathing live TV etc. (primarily within my own network)
A couple of hand held devices running Plex (primarily for outside my own network, and for the transcoding)

My goal
A Ubuntu server with a Hauppauge Dual Quad tuner PCIe card running TVHeadend (back end) and a Plex Server.
A couple of HTPC:s running Kodi, as client for watching live TV etc. (primarily within my own network)
A couple of smart phones/tablets running Plex client (primarily for outside my own network, and for the transcoding).
On these smart phones/tablets I would be able to watch live TV too via Plex, without having to switch to a separate app for this (as is the case today)

My question
If I decide to change the PCIe card to a Hauppauge Quad tune PCIe card (one supported by Plex obviously), how will that perform my TVHeadend set up?

I would be going from 2 tuners to 4 tuners, which is fine, but what happens if TVHeadend and the Plex server both want to start using the same tuner?
What would happen if Plex server “hogs” all 4 tuners and then TVheadend want’s 1, or vice versa?
Will they cooperate nicely until all 4 tuners are taken, and if a fifth tuner is required by TVheadend or Plex Server, will this request will be denied?

In a nutshell : Does TVHeadend hog the entire PCI card with all it’s tuners, or will it play nicely with the Plex Server, and allow Plex Server to use the tuners that aren’t in service by TVHeadend (and vice versa)?

Hope you understand my question…

Warning this is a cross post : http://tvheadend.org/boards/5/topics/26824 - but I haven’t gotten a reply there, so hoping for an answer here…

From my experience TVHeadend hogs the PCI card. You can use tvhproxy though. Tvhproxy will pretend your tvheadend installation is a hdhomerun device, so plex can connect to it. With this setup plex is just another tvheadend client. Naturally it would be even more ideal, if plex would become a native tvheadend client, but I don’t think that is going to happen anytime soon.

Advantage is that you will not have two systems accessing your tuner cards at the same time -> better device management.

Alright perfect - thanks!
I’ll look in to tvhproxy!

On my system, tvhproxy can only be found after a restart of the plex server. After a while plex will state that the connection is lost, but it still works. So something in the communication is not optimal.

Way to configure is: restart plex, go into dvr and add tvhproxy. Configure your channels and let it run. If you need to make changes, I have to restart plex.

And I had to open port 5004 so plex could talk to tvhproxy. I run plex in a docker, tvheadend has its own docker as well and tvhproxy is on the host.

I gave up and bought a new USB tuner, that Plex get’s to use exclusively.
So the PCIe card is used by TVHeadend, and the USB card used by Plex.