-
-
Notifications
You must be signed in to change notification settings - Fork 4.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
SMB/CIFS Problem: Could not rename part file to final file #11295
Comments
GitMate.io thinks possibly related issues are #9152 (Problem renaming folders), #9000 (Problem rewriting SMB files), #8942 (Uploading to shared public upload-only Folder fails: Could not rename part file to final file), #9091 ( server replied: Internal Server Error (Could not rename part file to final file)), and #490 (Rename file logging from "ownCloud" to "file"). |
Does no one has any idea what causes this error or how ti fix it ? I cant upload any file to the external storage. This is very important because there are over 200 users waiting for it. I searched through all the forums i could find and also the things the nextcloud bot suggested me. There is no fix that could have helped me. Could someone please look through this ? Thanks very much. |
Does no one else have this problem ? |
I really need your help .. just give me any point where i can start searching for the problem .. |
We had a similiar problem with NetApp as backend for CIFS/SMB external storage. Seems the CIFS implementation on NetApp and Samba/smbclient negotiated SMB1 as protocol but tried to upload with data chunks > 64k which does not work in SMB1 resulting in a butched upload.
Pls let me know if this was of any help. Source: |
Did not change anything.. i checked the whole smb.conf file there wasnt anything like that in there so i copied that in the file. I tried rebooting the whole machine but it did not affect the error at all .. |
It may well be that this won't fix your problem. But just to make sure, you put those lines into the global section of smb.conf? It is prefixed by a line "[global]". |
seems perfect... then sorry for not beeing helpfull in your case :( |
no problem but thanks for tryin .. :/ |
still not working after 14.0.3 Update .... |
Same here; |
Are you using Netapp with a CIFS share? |
I'm using an internally self-hosted Tech&Me VM, updated to 14.03 using the External Storage SMB/CIFS share configuration to a Windows 2012 Std (Not R2) share. Creating a file within Nextcloud works fine but uploads do not, this includes the sync clients on any platform. I have done a workaround by mounting the windows share using fstab and using "Local" as storage type. This means the share is accessed using one set of windows credentials rather than the LDAP authentication (preferred) but this works very well - and much quicker! |
Hi Guys, Just to let you know of a workaround for this. If I create the share as a hidden share this works eg; \server1\Data$ and connect your external storage to that. No idea why, but it works! |
I had the same problem. It turned out to be a permission problem. User "www-data" could not write to the "data/media/files" folder. |
I also got this problem when trying to upload files to a directory I had read access but not write access. Double check if the folder you are trying to upload to is owned by the Nextcloud user you are logged in and is writable. |
Hi! Don't want to create new topic, so will post in here: Nextcloud 14.0.4 I have mounted Azure cifs share with such command: share mounts with no error and syncs. I can create files and folders and new files in those folders with no problems with Nextcloud. Also they nicely syncs to Azure. BUT I can't upload any file using Nextcloud or NC WebDav to that folder or subfolders. All those files and folders are owned by apache : apache In error log there is such error: ` ` Any advice, please?! |
I fixed this error by adding the line
to the configuration of the corresponding Samba shares. Also make sure that the Samba user which is used by Nextcloud is in the A complete Samba configuration might look like this:
In this example, |
I get this error with filenames containing characters like ":", "/" or "?". All other files sync normally. |
Reproductible every time? |
@skjnldsv Yes! |
To anyone using Netapp:
|
Thanks @valeriop , you saved my day :) |
Failing to rename files/dirs with smbclient/libsmbclient for protocols > SMB1 appears to be a samba bug, cf.: In my case with nextcloud on Debian buster trying to connect to a samba server on Debian stretch I could work around the issue with
|
FYI, with Version 19.0.1 July 17 2020, issue was still occuring with SMB share during upload of file.. and not where creating subfolder. was not working is working. No need to patch any other file |
... if you are fine with other samba clients connecting through a very unsafe protocol of if you have no other clients. |
Do we have a solution for SMB2 or SMB3 ? especially if NAS parameters cannot be changed or is not NetAPP... |
Problem still persist. Going back to NT1 is no solution. Problem is Nextcloud / icewind, not the samba-client |
I used a Windows Server 2016 as AD Controller and this fixed it temporary. As I use NextCloud in a Docker Container, the change is not persistant. Is there any solution in the meanwhile? |
Yes, I also think so. |
This isn't the main topic, but like this.
|
@ynott: Cheers, |
https://bugzilla.samba.org/show_bug.cgi?id=14169 This has been fixed on latest version of samba. Some other issues related to the SAMBA library that had issues with Nextcloud and Owncloud were fixed as well. |
Hi, please update to 24.0.8 or better 25.0.2 and report back if it fixes the issue. Thank you! |
Great! Thanks for verifying! |
![]() @szaimen It should be reopened, [Nextcloud Hub 7] (28.0.4) |
Steps to reproduce
Expected behaviour
Tell us what should happen
Upload should begin and finish with no issue
Actual behaviour
Tell us what happens instead
The file is trying to upload but exits with the error on top:
Could not rename part file to final file
Server configuration
Operating system:
Ubuntu 18.04 LTS
Web server:
Apache 2
Database:
MariaDB
PHP version:
PHP 7.1
Nextcloud version: (see Nextcloud admin page)
NC 14.0.0.19
Updated from an older Nextcloud/ownCloud or fresh install:
Updated from 13.0.6
Where did you install Nextcloud from:
Tech and me prepared VM installation
Signing status:
Signing status
List of activated apps:
App list
- accessibility: 1.0.1 - activity: 2.7.0 - admin_audit: 1.4.0 - bruteforcesettings: 1.1.0 - cloud_federation_api: 0.0.1 - comments: 1.4.0 - dav: 1.6.0 - federatedfilesharing: 1.4.0 - files: 1.9.0 - files_external: 1.5.0 - files_pdfviewer: 1.3.2 - files_rightclick: 0.8.4 - files_sharing: 1.6.2 - files_texteditor: 2.6.0 - files_trashbin: 1.4.1 - files_versions: 1.7.1 - files_videoplayer: 1.3.0 - gallery: 18.1.0 - groupfolders: 1.3.3 - logreader: 2.0.0 - lookup_server_connector: 1.2.0 - metadata: 0.7.0 - nextcloud_announcements: 1.3.0 - notifications: 2.2.1 - oauth2: 1.2.1 - password_policy: 1.4.0 - previewgenerator: 1.1.0 - provisioning_api: 1.4.0 - serverinfo: 1.4.0 - sharebymail: 1.4.0 - support: 1.0.0 - survey_client: 1.2.0 - systemtags: 1.4.0 - theming: 1.5.0 - twofactor_backupcodes: 1.3.1 - updatenotification: 1.4.1 - user_ldap: 1.4.0 - workflowengine: 1.4.0 Disabled: - admin_notifications - announcementcenter - checksum - contacts - encryption - federation - files_accesscontrol - files_downloadactivity - files_retention - firstrunwizard - fulltextsearch - ldaporg - quota_warning - ransomware_protection - tasks - unsplash - user_external - w2g2Nextcloud configuration:
Config report
{
"system": {
"passwordsalt": "REMOVED SENSITIVE VALUE",
"secret": "REMOVED SENSITIVE VALUE",
"trusted_domains": [
"localhost",
"192.168.50.28",
"nextcloud",
"cloud.gertex.de",
"gertex.net",
"192.168.50.47"
],
"datadirectory": "REMOVED SENSITIVE VALUE",
"overwrite.cli.url": "https://cloud.gertex.de/",
"dbtype": "mysql",
"version": "14.0.0.19",
"dbname": "REMOVED SENSITIVE VALUE",
"dbhost": "REMOVED SENSITIVE VALUE",
"dbport": "",
"dbtableprefix": "oc_",
"mysql.utf8mb4": true,
"dbuser": "REMOVED SENSITIVE VALUE",
"dbpassword": "REMOVED SENSITIVE VALUE",
"installed": true,
"instanceid": "REMOVED SENSITIVE VALUE",
"quota_include_external_storage": false,
"maintenance": false,
"mail_smtpmode": "smtp",
"log_rotate_size": "10485760",
"memcache.local": "\OC\Memcache\Redis",
"filelocking.enabled": true,
"memcache.distributed": "\OC\Memcache\Redis",
"memcache.locking": "\OC\Memcache\Redis",
"redis": {
"host": "REMOVED SENSITIVE VALUE",
"port": 0,
"timeout": 0,
"dbindex": 0,
"password": "REMOVED SENSITIVE VALUE"
},
"htaccess.RewriteBase": "/",
"ldapIgnoreNamingRules": false,
"ldapProviderFactory": "\OCA\User_LDAP\LDAPProviderFactory",
"mail_from_address": "REMOVED SENSITIVE VALUE",
"mail_smtpauthtype": "LOGIN",
"mail_domain": "REMOVED SENSITIVE VALUE",
"mail_smtphost": "REMOVED SENSITIVE VALUE",
"loglevel": 1,
"updater.release.channel": "production",
"theme": ""
}
}
Are you using external storage, if yes which one: local/smb/sftp/...
SMB
Are you using encryption: yes/no
No
Are you using an external user-backend, if yes which one: LDAP/ActiveDirectory/Webdav/...
LDAP
LDAP configuration (delete this part if not used)
LDAP config
| hasMemberOfFilterSupport | 1 |
| hasPagedResultSupport | |
| homeFolderNamingRule | |
| lastJpegPhotoLookup | 0 |
| ldapAgentName | CN=User,OU=Group,DC=domain,DC=net |
| ldapAgentPassword | *** |
| ldapAttributesForGroupSearch | |
| ldapAttributesForUserSearch | |
| ldapBackupHost | nothing to see here |
| ldapBackupPort | nothing to see here |
| ldapBase | DC=domain,DC=net |
| ldapBaseGroups | DC=domain,DC=net |
| ldapBaseUsers | DC=domain,DC=net |
| ldapCacheTTL | 1200 |
| ldapConfigurationActive | 1 |
| ldapDefaultPPolicyDN | |
| ldapDynamicGroupMemberURL | |
| ldapEmailAttribute | mail |
| ldapExperiencedAdmin | 0 |
| ldapExpertUUIDGroupAttr | |
| ldapExpertUUIDUserAttr | sAMAccountName |
| ldapExpertUsernameAttr | sAMAccountName |
| ldapGidNumber | gidNumber |
| ldapGroupDisplayName | cn |
| ldapGroupFilter | (&(|(objectclass=group))(|(cn=somegroup)(cn=somegroup)(cn=somegroup))) |
| ldapGroupFilterGroups | somegroup;somegroup;somegroup |
| ldapGroupFilterMode | 0 |
| ldapGroupFilterObjectclass | group |
| ldapGroupMemberAssocAttr | member |
| ldapHost | some ip |
| ldapIgnoreNamingRules | |
| ldapLoginFilter | (&(&(|(objectclass=user))(|(|(memberof=CN=group,CN=Users,DC=domain,DC=net)(primaryGroupID=8715))))(|(samaccountname=%uid)(|(mailPrimaryAddress=%uid)(mail=%uid))(|(sAMAccountName=%uid)))) |
| ldapLoginFilterAttributes | sAMAccountName |
| ldapLoginFilterEmail | 1 |
| ldapLoginFilterMode | 0 |
| ldapLoginFilterUsername | 1 |
| ldapNestedGroups | 0 |
| ldapOverrideMainServer | |
| ldapPagingSize | 500 |
| ldapPort | 389 |
| ldapQuotaAttribute | |
| ldapQuotaDefault | |
| ldapTLS | 0 |
| ldapUserAvatarRule | default |
| ldapUserDisplayName | displayname |
| ldapUserDisplayName2 | |
| ldapUserFilter | (&(|(objectclass=user))(|(|(memberof=CN=group ,CN=Users,DC=domain,DC=net)(primaryGroupID=some ID)))) |
| ldapUserFilterGroups | Group |
| ldapUserFilterMode | 0 |
| ldapUserFilterObjectclass | user |
| ldapUuidGroupAttribute | auto |
| ldapUuidUserAttribute | auto |
| turnOffCertCheck | 0 |
| turnOnPasswordChange | 0 |
| useMemberOfToDetectMembership | 1 |
+-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
Client configuration
Browser:
Google Chrome
Version 69.0.3497.100
Operating system:
Windows 10
Version 1803
Build 17134.286
Logs
Nextcloud log (data/nextcloud.log)
Nextcloud log
The text was updated successfully, but these errors were encountered: