Download stops after 10 GB

Nextcloud version (eg, 12.0.2): 12.05
Operating system and version (eg, Ubuntu 17.04): Ubuntu 16.04
Apache or nginx version (eg, Apache 2.4.25): Apache 2.4.18
PHP version (eg, 7.1): 7.0

The issue you are facing:

While downloading anything larger than 10 GB, download stops at 10 GB

Is this the first time you’ve seen this error? (Y/N): Yes but first time tried downloading.

Steps to replicate it:
Try downloading file larger than 10 GB.

The output of your Nextcloud log in Admin > Logging:
Since this issue was identified a day ago, the logs below are relevant to that.

|Error|no app in context|Symfony\Component\Routing\Exception\RouteNotFoundException: Unable to generate a URL for the named route "theming.Theming.getLogo" as such route does not exist.|2018-03-10T09:17:02-0600|
|---|---|---|---|
|Error|no app in context|Symfony\Component\Routing\Exception\RouteNotFoundException: Unable to generate a URL for the named route "theming.Theming.getLogo" as such route does not exist.|2018-03-10T09:16:56-0600|
|Warning|core|Trusted domain error. "<some external IP>" tried to access using "<my external IP>" as host.|2018-03-10T06:45:06-0600|
|Warning|core|Trusted domain error. "<some external IP" tried to access using "<my external IP>" as host.|2018-03-10T06:43:22-0600|
|Error|no app in context|Symfony\Component\Routing\Exception\RouteNotFoundException: Unable to generate a URL for the named route "theming.Theming.getLogo" as such route does not exist.|2018-03-09T20:56:06-0600|
|Error|no app in context|Symfony\Component\Routing\Exception\RouteNotFoundException: Unable to generate a URL for the named route "theming.Theming.getLogo" as such route does not exist.|2018-03-09T20:55:53-0600|
|Error|no app in context|Symfony\Component\Routing\Exception\RouteNotFoundException: Unable to generate a URL for the named route "theming.Theming.getLogo" as such route does not exist.|2018-03-09T20:55:43-0600|
|Error|no app in context|Symfony\Component\Routing\Exception\RouteNotFoundException: Unable to generate a URL for the named route "theming.Theming.getLogo" as such route does not exist.|2018-03-09T20:55:35-0600|
|Error|PHP|Exception: The requested uri(/currentsetting.htm) cannot be processed by the script '/core/templates/404.php') at /var/www/nextcloud/lib/private/AppFramework/Http/Request.php#729|2018-03-09T18:32:01-0600|
|Warning|core|Login failed: 'someusername' (Remote IP: 'xxx.xxx.xxx.90')|2018-03-09T16:59:58-0600|
|Error|no app in context|Symfony\Component\Routing\Exception\RouteNotFoundException: Unable to generate a URL for the named route "theming.Theming.getLogo" as such route does not exist.|2018-03-09T15:02:28-0600|
|Error|no app in context|Symfony\Component\Routing\Exception\RouteNotFoundException: Unable to generate a URL for the named route "theming.Theming.getLogo" as such route does not exist.|2018-03-09T14:36:28-0600|
|Warning|core|Trusted domain error. "xx.xx.202.204" tried to access using "xxx.xxx.xxx.101" as host.|2018-03-09T08:16:35-0600|
|Warning|core|Trusted domain error. "xxx.xxx.206.67" tried to access using "xxx.xxx.xxx.101" as host.|2018-03-09T07:06:50-0600|
|Warning|core|Trusted domain error. "xxx.xxx.88.20" tried to access using "xxx.xxx.xxx.101:443" as host.|2018-03-09T06:48:41-0600|
|Warning|core|Trusted domain error. "xxx.xxx.113.204" tried to access using "xxx.xxx.xxx.101" as host.|2018-03-09T02:17:45-0600|
|Warning|core|Trusted domain error. "xx.xxx.97.172" tried to access using "xxx.xxx.xxx.101:443" as host.|2018-03-09T00:33:39-0600|
|Error|PHP|Exception: The requested uri(/OWA-AUTODISCOVER-EWS) cannot be processed by the script '/core/templates/404.php') at /var/www/nextcloud/lib/private/AppFramework/Http/Request.php#729|2018-03-08T23:14:57-0600|

The output of your config.php file in /path/to/nextcloud (make sure you remove any identifiable information!):

<?php
$CONFIG = array (
  'instanceid' => 'dlkdksldsk',
  'passwordsalt' => 'xxxxxxxXXXXXXxXXXXXXXx',
  'secret' => 'X/xxxxxxxXXXXxxXXXx1323423xxxxxxxxxxxxx',
  'trusted_domains' =>
  array (
    0 => 'mysite.mydomain.com',
  ),
  'datadirectory' => '/var/www/nextcloud/data',
  'overwrite.cli.url' => 'https://mysite.mydomain.com',
  'dbtype' => 'mysql',
  'version' => '12.0.5.3',
  'dbname' => 'dbname',
  'dbhost' => 'localhost',
  'dbport' => '',
  'dbtableprefix' => 'oc_',
  'mysql.utf8mb4' => true,
  'dbuser' => 'xxxxxx',
  'dbpassword' => 'xxxxxx',
  'installed' => true,
  'updater.release.channel' => 'production',
  'mail_smtpmode' => 'smtp',
  'mail_smtpauthtype' => 'LOGIN',
  'mail_smtpsecure' => 'tls',
  'mail_from_address' => 'name',
  'mail_domain' => 'mydomain.com',
  'mail_smtphost' => 'my.smtphost.com',
  'mail_smtpport' => '587',
  'mail_smtpauth' => 1,
  'mail_smtpname' => 'name@domain.com',
  'mail_smtppassword' => 'xxxxxxxx',
  'memcache.local' => '\OC\Memcache\APCu',
  'memcache.locking' => '\OC\Memcache\Redis',
  'filelocking.enabled' => 'true',
  'redis' =>
  array (
  'host' => '/var/run/redis/redis.sock',
  'port' => 0,
  'timeout' => 0.0,
  ),
);

The output of your Apache/nginx/system log in /var/log/____: /var/log/apache2/error.log

[Sat Mar 10 08:03:41.615966 2018] [:error] [pid 29371] [client xxx.xxx.xxx.xxx:61071] PHP Fatal error:  Uncaught Doctrine\\DBAL\\DBALException: Failed to connect to the database: An exception occured in driver: SQLSTATE[HY000] [2002] No such file or directory in /var/www/nextcloud/lib/private/DB/Connection.php:61\nStack trace:\n#0 /var/www/nextcloud/3rdparty/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(429): OC\\DB\\Connection->connect()\n#1 /var/www/nextcloud/3rdparty/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(389): Doctrine\\DBAL\\Connection->getDatabasePlatformVersion()\n#2 /var/www/nextcloud/3rdparty/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(328): Doctrine\\DBAL\\Connection->detectDatabasePlatform()\n#3 /var/www/nextcloud/3rdparty/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(623): Doctrine\\DBAL\\Connection->getDatabasePlatform()\n#4 /var/www/nextcloud/lib/private/DB/Connection.php(148): Doctrine\\DBAL\\Connection->setTransactionIsolation(2)\n#5 /var/www/nextcloud/3rdparty/doctrine/dbal/lib/Doctrine/DBAL/DriverManager.php(172): OC\\DB\\Connection->__construct(Array, Object(Doctrine\\DBAL\\Driver\\PDOMySql\\Driver), Obj in /var/www/nextcloud/lib/private/DB/Connection.php on line 61
[Sat Mar 10 08:03:41.616093 2018] [:error] [pid 29145] [client xxx.xxx.xxx.xxx:61072] PHP Fatal error:  Uncaught Doctrine\\DBAL\\DBALException: Failed to connect to the database: An exception occured in driver: SQLSTATE[HY000] [2002] No such file or directory in /var/www/nextcloud/lib/private/DB/Connection.php:61\nStack trace:\n#0 /var/www/nextcloud/3rdparty/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(429): OC\\DB\\Connection->connect()\n#1 /var/www/nextcloud/3rdparty/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(389): Doctrine\\DBAL\\Connection->getDatabasePlatformVersion()\n#2 /var/www/nextcloud/3rdparty/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(328): Doctrine\\DBAL\\Connection->detectDatabasePlatform()\n#3 /var/www/nextcloud/3rdparty/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(623): Doctrine\\DBAL\\Connection->getDatabasePlatform()\n#4 /var/www/nextcloud/lib/private/DB/Connection.php(148): Doctrine\\DBAL\\Connection->setTransactionIsolation(2)\n#5 /var/www/nextcloud/3rdparty/doctrine/dbal/lib/Doctrine/DBAL/DriverManager.php(172): OC\\DB\\Connection->__construct(Array, Object(Doctrine\\DBAL\\Driver\\PDOMySql\\Driver), Obj in /var/www/nextcloud/lib/private/DB/Connection.php on line 61
[Sat Mar 10 08:03:41.616303 2018] [:error] [pid 29371] [client xxx.xxx.xxx.xxx:61071] PHP Fatal error:  Uncaught Doctrine\\DBAL\\DBALException: Failed to connect to the database: An exception occured in driver: SQLSTATE[HY000] [2002] No such file or directory in /var/www/nextcloud/lib/private/DB/Connection.php:61\nStack trace:\n#0 /var/www/nextcloud/3rdparty/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(429): OC\\DB\\Connection->connect()\n#1 /var/www/nextcloud/3rdparty/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(389): Doctrine\\DBAL\\Connection->getDatabasePlatformVersion()\n#2 /var/www/nextcloud/3rdparty/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(328): Doctrine\\DBAL\\Connection->detectDatabasePlatform()\n#3 /var/www/nextcloud/3rdparty/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(623): Doctrine\\DBAL\\Connection->getDatabasePlatform()\n#4 /var/www/nextcloud/lib/private/DB/Connection.php(148): Doctrine\\DBAL\\Connection->setTransactionIsolation(2)\n#5 /var/www/nextcloud/3rdparty/doctrine/dbal/lib/Doctrine/DBAL/DriverManager.php(172): OC\\DB\\Connection->__construct(Array, Object(Doctrine\\DBAL\\Driver\\PDOMySql\\Driver), Obj in /var/www/nextcloud/lib/private/DB/Connection.php on line 61
[Sat Mar 10 08:03:41.616399 2018] [:error] [pid 29145] [client xxx.xxx.xxx.xxx:61072] PHP Fatal error:  Uncaught Doctrine\\DBAL\\DBALException: Failed to connect to the database: An exception occured in driver: SQLSTATE[HY000] [2002] No such file or directory in /var/www/nextcloud/lib/private/DB/Connection.php:61\nStack trace:\n#0 /var/www/nextcloud/3rdparty/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(429): OC\\DB\\Connection->connect()\n#1 /var/www/nextcloud/3rdparty/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(389): Doctrine\\DBAL\\Connection->getDatabasePlatformVersion()\n#2 /var/www/nextcloud/3rdparty/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(328): Doctrine\\DBAL\\Connection->detectDatabasePlatform()\n#3 /var/www/nextcloud/3rdparty/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(623): Doctrine\\DBAL\\Connection->getDatabasePlatform()\n#4 /var/www/nextcloud/lib/private/DB/Connection.php(148): Doctrine\\DBAL\\Connection->setTransactionIsolation(2)\n#5 /var/www/nextcloud/3rdparty/doctrine/dbal/lib/Doctrine/DBAL/DriverManager.php(172): OC\\DB\\Connection->__construct(Array, Object(Doctrine\\DBAL\\Driver\\PDOMySql\\Driver), Obj in /var/www/nextcloud/lib/private/DB/Connection.php on line 61
[Sat Mar 10 08:03:41.707196 2018] [mpm_prefork:notice] [pid 1482] AH00169: caught SIGTERM, shutting down
[Sat Mar 10 08:14:46.028720 2018] [mpm_prefork:notice] [pid 1452] AH00163: Apache/2.4.18 (Ubuntu) OpenSSL/1.0.2g configured -- resuming normal operations
[Sat Mar 10 08:14:46.037857 2018] [core:notice] [pid 1452] AH00094: Command line: '/usr/sbin/apache2'
[Sat Mar 10 09:11:34.629476 2018] [authz_core:error] [pid 1487] [client xxx.xxx.xxx.xxx:51077] AH01630: client denied by server configuration: /var/www/nextcloud/data/.ocdata
[Sat Mar 10 09:16:56.862944 2018] [authz_core:error] [pid 1815] [client xxx.xxx.xxx.xxx:52724] AH01630: client denied by server configuration: /var/www/nextcloud/data/.ocdata
[Sat Mar 10 09:17:02.586869 2018] [authz_core:error] [pid 1683] [client xxx.xxx.xxx.xxx:52782] AH01630: client denied by server configuration: /var/www/nextcloud/data/.ocdata