Unable to add SMB External Storage using OCC

I was trying to add an external SMB storage via GUI but keep hitting the “Password Incorrect” error that doesn’t seem to have a solution yet. So I am trying to add it via the occ commands however I keep running into errors.

I tried this but I get a “not enough arguments: missing authentication_backend”

sudo -u www-data php occ files_external:create SMBShare ‘smb’ -c host=192.168.1.xx -c share=Nextcloud -c root=/mnt/HomePool -c domain=workgroup -c user=xxxx -c password=xxxx

Would anyone know what I am missing or the correct syntax I should be using since this can’t be done via the gui?

Can’t offer any help, as I am having the same problem. I’m using NextCloud Hub 10 (31.0.8) on OpenSUSE Leap 15.6. If you get any suggestions or a fix, please copy me in

Thanks, I think I’ve tried every possible suggestion for fixing the GUI approach but nothing worked which led me to trying the cli approach but I keep running into issues there too. Was hoping it might just be my syntax being incorrect that someone might correct me on.

If I ever find a solution I’ll be sure to post it here. Ideally maybe the next release fixes this bug which seems to have been around a while.

On my system, I noticed is only on the add SMB or FTP external folder that fails with incorrect password. I tried adding a user that required authorization and that worked! - go figure. Awainting any positive response. Might just keep posting frivolous replies every couple of months just to keep the topic open

I haven’t tried anything other than adding an smb but I have seen that mentioned elsewhere. I tried all the possible solutions but still unable to get it to add. I was hoping the middleware php file hack would worked but it didn’t for me.

For the CLI, the authentication backend needs to be specified. E.g. External storage password error - #5 by wagnbeu0

So I made some progress but I think I may have switched up the share and root.

My configuration is showing as this

I don’t think it’s listed correctly since I am getting an error trying to get into the mounted folder. My path should be /mnt/HomePool/Nextcloud.
Should my share and root have been reversed? If so, how would I change that path now?

sudo -u www-data php occ files_external:create SMBShare smb password::password -c host=192.168.1.xx -c share=Nextcloud -c root=/mnt/HomePool -c -c user=xxxx -c password=xxxx

Making baby steps as I created another smb share flipping the share and root and I think it is correct now but now I am getting a “Connection refused exception error” which I think means my user and password are incorrect however I believe what I am entering is correct.

sudo -u www-data php occ files_external:create SMBShare smb password::password -c host=192.168.1.53 -c share=HomePool -c root=/Nextcloud -c user=xxxx -c password=xxxx

1 Like

Finally got it to work. Here is the syntax I used to connect to my smb share:

sudo -u www-data php occ files_external:create NCsmb smb password::password -c host=192.168.1.53 -c share=Nextcloud -c user=xxxx -c password=xxxx

I removed the root=/Nextcloud and changed share=Nextcloud and renamed the folder to NCsmb. Now my external drive looks like this:

The green checkmark confirms that it’s connected.

Thanks for everyone’s suggestions

2 Likes

Thanks for the guidance, I’ve got it working via OCC too, but would V much prefer to use the GUI

1 Like

This topic was automatically closed 8 days after the last reply. New replies are no longer allowed.