Nextcloud version (eg, 12.0.2): 15.0.0.10
Operating system and version (eg, Ubuntu 17.04): Ubuntu 18.04
Apache or nginx version (eg, Apache 2.4.25): nginx 1.14
PHP version (eg, 7.1): 7.2
Windows Client: 2.5.1
External Storage: SAMBA, Ubuntu 18.04: Mounting Active Directory user homeshares
Root of Nextcloud: NFS
NFS and SAMBA running on the same server behind a firewall.
The issue you are facing:
When uploading/syncing many small files from a Windows machine the smbclient get “stuck” and server is running at 100% CPU. This does not get better when replication is stopped or replication is completed.
No problem when uploading/syncing /the same folder to the root of Nextcloud (NFS)!
top - 18:52:56 up 58 min, 1 user, load average: 12.04, 8.39, 4.67
Tasks: 175 total, 12 running, 100 sleeping, 0 stopped, 0 zombie
%Cpu(s): 22.7 us, 75.7 sy, 0.0 ni, 0.0 id, 0.0 wa, 0.0 hi, 0.0 si, 1.6 st
KiB Mem : 2031112 total, 1487256 free, 239856 used, 304000 buff/cache
KiB Swap: 190916 total, 190916 free, 0 used. 1613120 avail Mem
PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
19220 www-data 20 0 345640 16404 13924 R 62.8 0.8 0:34.57 smbclient
1151 www-data 20 0 347156 18116 13968 R 62.5 0.9 50:06.38 smbclient
14546 www-data 20 0 345508 16364 13880 R 56.1 0.8 3:29.06 smbclient
16657 www-data 20 0 345508 16272 13792 R 56.1 0.8 1:56.43 smbclient
9858 www-data 20 0 345508 16260 13784 R 54.8 0.8 6:42.18 smbclient
14443 www-data 20 0 345508 16400 13924 R 54.2 0.8 3:36.59 smbclient
10218 www-data 20 0 345508 16276 13792 R 51.8 0.8 6:32.10 smbclient
17007 www-data 20 0 345508 16280 13804 R 49.5 0.8 1:51.98 smbclient
7606 www-data 20 0 345508 16288 13812 R 48.8 0.8 8:14.29 smbclient
19361 www-data 20 0 345640 16336 13856 R 48.8 0.8 0:28.51 smbclient
14473 www-data 20 0 345508 16320 13844 R 47.2 0.8 3:35.29 smbclient
15281 www-data 20 0 651432 52292 35480 S 4.0 2.6 0:15.70 php-fpm7.2
754 www-data 20 0 143848 9508 7124 S 0.3 0.5 0:32.35 nginx
The PIDs of the smbclient processes are not staying the same, constantly changing, so the only solution is to reboot the server.
The SMB share can still be accessed and files can be written to the share, but extremely slow (due to 100% CPU usage).
Is this the first time you’ve seen this error? (Y/N): Yes, first time trying to use external storage
Steps to replicate it:
- Activate exteral Storage
- Add SMB Share
- Sync lot of small files (e.g. 1000 JPGs) via LAN
The output of your Nextcloud log in Admin > Logging: Empty
The output of your config.php file in /path/to/nextcloud
(make sure you remove any identifiable information!):
<?php
$CONFIG = array (
'instanceid' => 'xxx',
'passwordsalt' => 'xxx',
'secret' => 'xxx',
'trusted_domains' =>
array (
0 => 'URL',
1 => 'URL',
),
'datadirectory' => '/data/nextcloud/data',
'dbtype' => 'mysql',
'version' => '15.0.0.10',
'overwrite.cli.url' => 'https://',
'dbname' => 'nextcloud2',
'dbhost' => '192.168.xx.xx',
'dbport' => '',
'dbtableprefix' => 'oc_',
'dbuser' => 'USR',
'dbpassword' => 'PWD',
'installed' => true,
'mail_from_address' => 'cloud',
'mail_smtpmode' => 'smtp',
'mail_sendmailmode' => 'smtp',
'mail_domain' => 'xx',
'mail_smtpauthtype' => 'xx',
'mail_smtphost' => '192.168.xx.xx',
'mail_smtpport' => '25',
'ldapIgnoreNamingRules' => false,
'ldapProviderFactory' => 'OCA\\User_LDAP\\LDAPProviderFactory',
'memcache.local' => '\OC\Memcache\APCu',
);
The output of your Apache/nginx/system log in /var/log/____
: No Error
Unfortunately I can’t find a smbclient logfile or any error messages in the SAMBA server log.
Thank you in advance for any help!
Best regards, Kurt