Re: [gentoo-user] Getting maximum space out of a hard drive

2022-08-18 Thread David Haller
Hello,

On Thu, 18 Aug 2022, Dale wrote:
>Rich Freeman wrote:
>> On Thu, Aug 18, 2022 at 2:04 PM Dale  wrote:
>>>
>>> Part. # SizePartition TypePartition Name
>>> 1007.0 KiB  free space
>>>19.1 TiB Linux filesystem  10Tb
>>> 1007.5 KiB  free space
>>>
>>>
>>> I'm not sure why there seems to be two alignment spots.  Is that
>>> normal?  Already, there is almost 1TB lost somewhere.
>> 10 TB = 9.09495 TiB.  You aren't missing much of anything.
[..]
>Well, I realize it would be less than advertised but I just want to
>maximize it as much as I can.  I found the -m option for the file system
>a good while back and it saves a lot on these larger drives.  Since this
>is a external drive, no point in reserving any root space, since root
>will likely never access it after the file system is put on it. 

Also, if you're using ext2/3/4, there's the preset, i.e. if you're
rather sure about what kind of data is going to be on there, you
can tune it so that it reserves more or less place for metadata like
inodes, which can be another bit.

I made some experiments with a temp-repurposed swapfile of 2051M size:

Output of 'df -m':
1M-blocks  Used Available   Inodes   mke2fs-options used
201667  1847131072-j -t ext4
201667  1949131072-j -t ext4 -m 0
204867  18782048  -j -t ext4 -T largefile
204867  19812048  -j -t ext4 -T largefile -m 0

So, defaults uses about 1.7% of the space for metadata, and -T
largefile only about 0.15% of the space. Of course, there are rather
few inodes with '-T largefile'. But if you want to put basically only
some big videos on there, 2048 inodes seems a lot for a mere 2G of
space ;) This should scale linearly (in steps) for bigger devices and
can amount to quite some more space.

Anyway, see /etc/mke2fs.conf, 'man mke2fs' and 'man mke2fs.conf for
details.

I've done this in the past and got bitten by too few inodes, but you
can get around that for "inode-hogs" like news-spools etc. by using a
loop-filesystem with different parameters or a different fs. Just
beware: reiserfs on reiserfs is a recipie for desaster.

HTH,
-dnh

-- 
There are two major products that come out of Berkeley:
LSD and UNIX. We don't believe this to be a coincidence.
   -- Jeremy S. Anderson



Re: [gentoo-user] Getting maximum space out of a hard drive

2022-08-18 Thread Dale
Rich Freeman wrote:
> On Thu, Aug 18, 2022 at 2:04 PM Dale  wrote:
>>
>> Part. # SizePartition TypePartition Name
>> 
>> 1007.0 KiB  free space
>>19.1 TiB Linux filesystem  10Tb
>> 1007.5 KiB  free space
>>
>>
>> I'm not sure why there seems to be two alignment spots.  Is that
>> normal?  Already, there is almost 1TB lost somewhere.
> 10 TB = 9.09495 TiB.  You aren't missing much of anything.
>
> And no, I don't want to get into a religious war over base 2 vs base
> 10, and why it would be confusing if a tape that could store 10MB/m
> didn't store 10kB/mm but instead stored 10.24 kB/mm.
>


Well, I realize it would be less than advertised but I just want to
maximize it as much as I can.  I found the -m option for the file system
a good while back and it saves a lot on these larger drives.  Since this
is a external drive, no point in reserving any root space, since root
will likely never access it after the file system is put on it. 

Nice to know it is a conversion thing going on tho.  ;-)

Dale

:-)  :-) 



Re: [gentoo-user] Getting maximum space out of a hard drive

2022-08-18 Thread Andreas Fink
On Thu, 18 Aug 2022 13:04:57 -0500
Dale  wrote:

> Howdy,
> 
> I got my 10TB drive in today.  I want to maximize the amount of data I
> can put on this thing and it remain stable.  I know about -m 0 when
> making the file system but was wondering if there is any other tips or
> tricks to make the most of the drive space.  This is the output of cgdisk.
> 
> 
> Part. # Size    Partition Type    Partition Name
> 
>     1007.0 KiB  free space
>    1    9.1 TiB Linux filesystem  10Tb
>     1007.5 KiB  free space
> 
> 
> I'm not sure why there seems to be two alignment spots.  Is that
> normal?  Already, there is almost 1TB lost somewhere.  Any way to
> increase that and still be safe?  Right now, I've ran the short test and
> it is chewing on the long test.  It will be done around 7AM tomorrow, 19
> or 20 hours to complete.  As it is, there's no data on it or even a file
> system either.  Now is the time to tweak things. 
> 
> Any tips or ideas would be appreciated. 
> 
> Dale
> 
> :-)  :-) 
> 

Ah yes, the good old harddisk marketing size calculating in base 1000,
while TiB is in base 1024.
In short:
1TB=1000^4 != 1TiB=1024^4

Do the math yourself, what 10TB should be in TiB, but it's in the
ballpark of 9.1TiB ;)



Re: [gentoo-user] Getting maximum space out of a hard drive

2022-08-18 Thread Rich Freeman
On Thu, Aug 18, 2022 at 2:04 PM Dale  wrote:
>
>
> Part. # SizePartition TypePartition Name
> 
> 1007.0 KiB  free space
>19.1 TiB Linux filesystem  10Tb
> 1007.5 KiB  free space
>
>
> I'm not sure why there seems to be two alignment spots.  Is that
> normal?  Already, there is almost 1TB lost somewhere.

10 TB = 9.09495 TiB.  You aren't missing much of anything.

And no, I don't want to get into a religious war over base 2 vs base
10, and why it would be confusing if a tape that could store 10MB/m
didn't store 10kB/mm but instead stored 10.24 kB/mm.

-- 
Rich



[gentoo-user] Getting maximum space out of a hard drive

2022-08-18 Thread Dale
Howdy,

I got my 10TB drive in today.  I want to maximize the amount of data I
can put on this thing and it remain stable.  I know about -m 0 when
making the file system but was wondering if there is any other tips or
tricks to make the most of the drive space.  This is the output of cgdisk.


Part. # Size    Partition Type    Partition Name

    1007.0 KiB  free space
   1    9.1 TiB Linux filesystem  10Tb
    1007.5 KiB  free space


I'm not sure why there seems to be two alignment spots.  Is that
normal?  Already, there is almost 1TB lost somewhere.  Any way to
increase that and still be safe?  Right now, I've ran the short test and
it is chewing on the long test.  It will be done around 7AM tomorrow, 19
or 20 hours to complete.  As it is, there's no data on it or even a file
system either.  Now is the time to tweak things. 

Any tips or ideas would be appreciated. 

Dale

:-)  :-) 



Re: [gentoo-user] DNSmasq: to IPv6 or not to IPv6?

2022-08-18 Thread Peter Humphrey
On Thursday, 18 August 2022 03:58:43 BST cal wrote:
> On 8/17/22 05:53, Peter Humphrey wrote:
> > On Wednesday, 17 August 2022 13:33:30 BST Peter Humphrey wrote:
> >> Hello list,
> >> 
> >> My LAN server runs net-dns/dnsmasq, which was updated today. When I
> >> restarted it I got a log entry that said it had been compiled with IPv6 -
> >> but the only reference to that under /etc/portage is USE=-dnsmasq in
> >> make.conf.
> > 
> > Oops! That should have been USE=-ipv6, of course.
> 
> It seems upstream removed the ability to disable IPv6 at compile time
> several years back:
> https://thekelleys.org.uk/gitweb/?
p=dnsmasq.git;a=commit;h=ee8750451b49d27b1
> 80517a4e35b636be0fae575. Ironic that the author included "I'm sure no-one
> wants or needs
> IPv6-free code these days" in the commit message.

Interesting. I see that was nearly four years ago, and I've only just noticed.

> I suppose you could file a bug to remove the `ipv6` USE from the dnsmasq
> ebuild since it no longer does anything.

Perhaps. Thanks for finding this, Cal.

-- 
Regards,
Peter.