Mateusz Okulus wrote:
>> root@fireball / # sysctl fs.file-max
>> fs.file-max = 3289952
>> root@fireball / # sysctl -w fs.file-max=32899520
>> fs.file-max = 32899520
>> root@fireball / # cat /proc/sys/fs/file-max
>> 32899520
> On my pc the limit is 2^63. But this is max files for kernel, which is
> different for max files per user and max files per process.
>
> For example if I run:
>
> $ grep 'Limit\|open' /proc/$(pgrep qbittorrent | head -1)/limits
> Limit                     Soft Limit           Hard Limit           Units
> Max open files            524288               524288               files
>
> 524288 = 2^19
>
> QBittorrent increases it's process limit to hard limit. With 10 TB of
> torrents it's hard to tell if it's a bug or just 500k files is not
> enough, I'd say it's probably the latter.
>
> It seems you can change the default hard limit in
> /etc/security/limits.conf
>
> For example:
>
> # 2^24, increased from 2^19
> * hard nofile 16777216
>
> Then after reloging:
>
> $ grep 'Limit\|open' /proc/$(pgrep qbittorrent | head -1)/limits
> Limit                     Soft Limit           Hard Limit           Units
> Max open files            16777216             16777216             files
>
> So this works, at least for me.
>
> Check also limits.conf man page.
>
> Regards,
> mmokulus
>
> .
>


It appears the change I made wasn't what was needed.  I took a nap,
after doing today what I used to do on Friday, which involves going to
Doctor, getting shots, then shopping around town etc etc.  Anyway, I
woke up to Qbittorrent being gone.  It crashed at some point.  In the
notification thingy, it had a few of the file open errors again.  So, I
ran some of the commands you posted, my hard limit was set to 4096.  I
whipped out my calculator and doubled it.  I set it in the limits.conf
file like so: 

root@fireball / # cat /etc/security/limits.conf | grep nofile
#        - nofile - max number of open file descriptors
*               hard    nofile          8192
root@fireball / #


I logged out and back in.  I ran the command you shared and it was
indeed set to the new amount.  I'm going to upgrade qbittorrent to the
new version again and test it some more. 

Thanks much for the help.  Maybe this will fix it.

Dale

:-)  :-) 

Reply via email to