<div dir="ltr"><div dir="ltr"><br></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Sun, 6 Mar 2022 at 00:33, Gary Buhrmaster <<a href="mailto:gary.buhrmaster@gmail.com">gary.buhrmaster@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">On Sat, Mar 5, 2022 at 11:56 PM UB40D via mythtv-users<br>
<<a href="mailto:mythtv-users@mythtv.org" target="_blank">mythtv-users@mythtv.org</a>> wrote:<br>
<br>
> Thanks for this explanation but I find it mindboggling... Why does Myth need "heuristics" when perfectly reliable first-hand information is available from the computer and OS about which drive is which?<br>
<br>
Because some people choose to use different<br>
directories on the same drive, and therefore<br>
the amount of space available on the drive is<br>
not always a simple thing to calculate. Only<br>
when the available space is different does<br>
MythTV "guess" that they must be different<br>
drives (and calculates space as if they are<br>
different).<br></blockquote><div><br></div><div>I am not sure I understand the problem the programmers experienced when they wrote the code that way. It seems to me that there is no need for heuristics (= guesswork) when unequivocal information is readily available.</div><div><br></div><div>for every directory d listed in mythtv setup as containing recordings:</div><div> df -h $d will return something like<br></div><div><font size="1" face="monospace"><span style="font-variant-ligatures:no-common-ligatures;color:rgb(0,0,0)">Filesystem</span><span class="gmail-Apple-converted-space" style="font-variant-ligatures:no-common-ligatures;color:rgb(0,0,0)"> </span><span style="font-variant-ligatures:no-common-ligatures;color:rgb(0,0,0)">Size</span><span class="gmail-Apple-converted-space" style="font-variant-ligatures:no-common-ligatures;color:rgb(0,0,0)"> </span><span style="font-variant-ligatures:no-common-ligatures;color:rgb(0,0,0)">Used Avail Use% Mounted on</span><br></font></div>
<div><font size="1" face="monospace"><span style="font-variant-ligatures:no-common-ligatures;color:rgb(0,0,0)">/dev/sdd1</span><span class="gmail-Apple-converted-space" style="font-variant-ligatures:no-common-ligatures;color:rgb(0,0,0)"> </span><span style="font-variant-ligatures:no-common-ligatures;color:rgb(0,0,0)">17T </span><span class="gmail-Apple-converted-space" style="font-variant-ligatures:no-common-ligatures;color:rgb(0,0,0)"> </span><span style="font-variant-ligatures:no-common-ligatures;color:rgb(0,0,0)">16T</span><span class="gmail-Apple-converted-space" style="font-variant-ligatures:no-common-ligatures;color:rgb(0,0,0)"> </span><span style="font-variant-ligatures:no-common-ligatures;color:rgb(0,0,0)">294G</span><span class="gmail-Apple-converted-space" style="font-variant-ligatures:no-common-ligatures;color:rgb(0,0,0)"> </span><span style="font-variant-ligatures:no-common-ligatures;color:rgb(0,0,0)">99% /mnt/wd18000a1</span> </font></div><div><br></div><div>so it is trivial to figure out both</div><div>a) how much free space is left on the drive that hosts that directory</div><div>b) whether that directory is on the same filesystem or drive of any other directory (to avoid double-counting)</div><div><br></div><div>I may be missing something crucial but I still fail to see why any guesswork might be needed.</div><div><br></div><div>BTW I did copy some files from the "recording" drive to one of those new "read-only" drives and indeed they now appear as separate drives, and the reported total amount of free space is now what I expected, so thanks to David and you for that suggestion.</div></div></div>