<div dir="auto"><div><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Fri, Oct 13, 2023, 5:02 a.m. Mike Perkins <<a href="mailto:mikep@randomtraveller.org.uk">mikep@randomtraveller.org.uk</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">On 13/10/2023 04:44, Stephen Worthington wrote:<br>
> On Thu, 12 Oct 2023 23:01:00 -0400, you wrote:<br>
> <br>
>> On Thu, Oct 12, 2023, 9:57 p.m. Stephen Worthington <<br>
>> <a href="mailto:stephen_agent@jsw.gen.nz" target="_blank" rel="noreferrer">stephen_agent@jsw.gen.nz</a>> wrote:<br>
>><br>
>>> On Thu, 12 Oct 2023 13:42:43 -0400, you wrote:<br>
>>><br>
>>>> Thinking of my next backend build. Any considerations to take into account<br>
>>>> if I run both MythTV and Jellyfin on the same box so as not to negatively<br>
>>>> affect recordings.<br>
>>>><br>
>>>> MythTV: occasionally up to 4 recordings at once off of a network tuner<br>
>>>> (hdhomerun).<br>
>>>><br>
>>>> Jellyfin: mostly direct lan connection to client. Maybe the odd wireless<br>
>>>> client in house that would need harware transcoding. Jellyfin content<br>
>>> would<br>
>>>> not be on the MythTV recording drives.<br>
>>>><br>
>>>> Any thoughts on minimum memory, etc?<br>
>>>><br>
>>>> Thanks.<br>
>>><br>
>>> For 11 years I ran MythTV with 8 Gibytes of RAM, and found that while<br>
>>> it did push large chunks of code to swap, it was mostly unused code<br>
>>> and everything was fine.  The RAM needs of the base Ubuntu system<br>
>>> increased significantly over the years.  I have seven recording drives<br>
>>> and at times am recording up to 14 channels at once.  Remember that<br>
>>> there will be up to twice as many recordings running when there are<br>
>>> overlaps due to the pre- and post-roll times.<br>
>>><br>
>>> However, I do not do any commercial flagging, which requires lots of<br>
>>> CPU and a bit more RAM.  Jellyfin transcoding would affect commercial<br>
>>> skip processing, but is unlikely to affect recording (which is very<br>
>>> low CPU usage).  And commercial skip processing does not need to be<br>
>>> real-time, so a bit of delay in completing it is not a problem.<br>
>>><br>
>>> For my new MythTV box in April, I chose to get 32 Gibytes of RAM, as<br>
>>> RAM is cheap (I was getting DDR4, not DDR5).  Now even DDR5 seems to<br>
>>> be fairly cheap, so if you want the new system to last a long time,<br>
>>> why not get lots?<br>
>>><br>
>>> If you are using your network tuners on the same Ethernet connection<br>
>>> that you will be using for normal network traffic, then there is a<br>
>>> probability of getting contention at times, which can affect<br>
>>> recordings.  I think the MythTV may now be using TCP for recording<br>
>>> connections to hdhomeruns, which would help a lot with that problem.<br>
>>> Unless you have lots of 4k connections to Jellyfin at the same time,<br>
>>> you are unlikely to saturate a 1 Gbit/s Ethernet connection, but every<br>
>>> time you copy a large video file on that connection, the speeds of<br>
>>> hard drives and especially NVME drives now means that the 1 Gbit/s<br>
>>> will be completely filled by the copy operation, so unless your<br>
>>> Ethernet adapters/drivers at both ends (and your switch?) support DSCP<br>
>>> priorities for the traffic, the recordings from the tuners may be<br>
>>> swamped by that traffic.  Last time I looked, the hdhomerun tuner<br>
>>> documentation did say they set a high priority DSPC flag on their<br>
>>> traffic.  So if you ever want to copy large files, you really want to<br>
>>> put your network tuners on a separate Ethernet port, if possible.<br>
>>><br>
>>> One thing to watch out for is CD/DVD/Bluray drives - if you want one<br>
>>> still in your new build, and are getting a new case, there are only a<br>
>>> few cases now that have 5.25" slots.  So you may need to get an<br>
>>> external USB one, or search out a case that still has an optical drive<br>
>>> slot.  I went with a SilverStone Grandia GD08B, as my 16 year old HTPC<br>
>>> case was dying (LEDs and buttons not working).<br><br>
>><br>
>> A great answer from you as always. Many thanks.<br>
>><br>
>> A networking question: OK, so say the motherboard has two ports. I have two<br>
>> hdhomeruns. Do I plug the hdhomeruns into a small switch and plug that<br>
>> directly into one of the two ports on the backend? (port #2)<br>
> <br>
> Yes.  You will need to also set up a DHCP server on that port.  This<br>
> looks like an OK guide for Ubuntu:<br>
> <br>
> <a href="https://www.linuxtechi.com/how-to-configure-dhcp-server-on-ubuntu/" rel="noreferrer noreferrer" target="_blank">https://www.linuxtechi.com/how-to-configure-dhcp-server-on-ubuntu/</a><br>
> <br>
>> Or using, say, a pfsense router (I want to learn and expand my network) and<br>
>> a managed switch, does it do anything to plug the hdhomeruns into the main<br>
>> switch (with other devices in the home) and use pfsense/switch and vlans to<br>
>> send it to port #2 on the backend?<br>
> <br>
> With a proper managed switch that does full VLANs, you can run<br>
> multiple different subnets on the same switch.  You just set the<br>
> switch to use a different VLAN number for all the ports on each<br>
> different subnet.  Set it to add the VLAN header on packets entering<br>
> the switch and to remove it from packets leaving the switch, so they<br>
> only have the VLAN headers while in the switch.  You would normally<br>
> leave all the original subnet ports set to no VLAN, but you could<br>
> choose to put them all on a different VLAN.  This is exactly what I do<br>
> on my commercial grade switch to keep my main subnet, my guest subnet<br>
> and my IoT subnet separate.  My switch is a Ubiquiti EdgeSwitch 24<br>
> Lite.<br>
> <br>
> The downside of using your main switch in this way is that you need<br>
> another cable from the MythTV box to the switch and two cables back to<br>
> the two hdhomeruns.  The upside is that you do not have to pay for the<br>
> extra electricity to run a small switch (2-6 Watts 24/7).<br>
> <br>
> There is nothing to do on the router - you do not want the router to<br>
> even see the packets that are moving on a subnet between the devices<br>
> of that subnet.  It should only handle routing between the subnets and<br>
> between the subnets and the WAN port.<br>
> <br>
A note on pfSense and VLANs.<br>
<br>
I have used pfSense for years to manage my far-too-large network and I will give the software a big <br>
thumbs up. Out of all those I have tried pfSense is easily the most straightforward to configure and <br>
use. Caveat is that it is still something of an art.<br>
<br>
BUT. You do not want to send HDHR traffic in through your router and out again, especially on the <br>
same port but a different VLAN! This effectively doubles the traffic on that port when, as Steven <br>
says, it doesn't need to go there at all. (Ask me how I know!)<br>
<br>
My setup uses a 6-port Mini-ITX board with one WAN port and five LAN ports, isolating <br>
high-throughput segments from one another where possible. Each of the LAN ports connects to a <br>
switch, some are smart, some are not. The Mythtv backend, frontend and two HDHRs are connected to a <br>
simple 8-port gigabit switch which keeps that traffic away from everything else. I have had no <br>
trouble with bandwidth, but I do not (yet) run 4K.<br>
<br>
Other subnets? One carries a zoneminder setup which is running 24/7 and obviously a lot of traffic <br>
from the cameras. A third is the Wifi access which uses different VLANS to permit several separate <br>
SSIDs from the access point. A fourth is the 'main' subnet which has most of the major servers on <br>
it, the last is the 'odds and sods' subnet which carries, via VLAN, things like our printer and the <br>
Central Heating connection.<br>
<br>
Making rules to permit things the appropriate access over that lot is fun.<br>
<br>
</blockquote></div></div><div dir="auto"><br></div><div dir="auto">Mike and Stephen, </div><div dir="auto"><br></div><div dir="auto">Thanks so much for the education about these issues. Looking forward to when I can roll up my sleeves and get hands-on with this. </div><div dir="auto"><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><a href="https://forum.mythtv.org" rel="noreferrer noreferrer" target="_blank"></a><br>
</blockquote></div></div></div>