Unable to connect via SMB

Hi all,

I was forced to reinstall the latest Ubuntu but I managed to back up my ownCloud instance beforehand. This includes the config.php, the data directory, and the MySQL database. Previously, I was using and now I’m using, installed from the Ubuntu package mentioned on the ownCloud homepage. I did run “occ upgrade”.

All seems fine except for one problem (so far). I am no longer able to connect to Samba shares that are on the same server. (i.e., the share is on the same server as ownCloud)

Of course, as this is a new reinstallation, there are many things that could have gone wrong that are not related to ownCloud. However, from another computer, I was able to mount the share (i.e., using the nautilus interface of Gnome). Thus, I think both the share’s configuration and the Samba user have been created correctly.

What happens now is, if I log into the web-based interface, the share is highlighted in red and a message at the top says, “Some of the configured external mount points are not connected. Pleae click on the red row(s) for more information”. When I click on one, it says, “External mount error. There was an error with message: Empty response from the server. Do you want to review mount point config in admin settings page?”

If I click “Yes”, then I can change the configuration but all seems correct…

I also tried to run “occ” as follows:

$ sudo -u www-data php occ files_external:verify 1

  • status: error
  • code: 1
  • message

…I don’t know what to do with this. On this web page, the app External Storage Support v0.5.2 is mentioned and I have not installed it. I am unable to find it in the Market Place. Am I missing something?

Can someone offer suggestions on what might be wrong or where I should go from here? Or even what log file(s) I should look into?

Thank you!


so you have ownCloud-files package.

Did you install the required packages for smb?

Thank you for getting back to me! Yes, I have installed the owncloud-files package by adding the ownCloud repository. The version is 10.0.9-1+1.1 .

I also installed the following packages:

  • php-smbclient
  • smbclient
  • libsmbclient

I think that is all I need? Your query gave me an idea, and I just tried (on the server):

  • smbclient -L localhost -U owncloud
  • smbclient -U owncloud

And both work as expected. In the latter case, I can type “ls” and see a list of files in that share.

Moreover, I just tried adding another Samba share, but one that is on another server but had worked before the upgrade. And that also doesn’t work.

Thank you!


Can you try this?

sudo phpenmod -v ALL smbclient

That didn’t work…but I figured out what I did “wrong”. Actually, it was something that I didn’t have to do in the previous installation but I somehow do now (I don’t know why). I need to specify a “Domain” in the web-based interface. Previously I left it blank.

So, to add a share, one has to enter:

  • Host
  • Share
  • Remote subfolder
  • Domain
  • Username
  • Password

Host, Share, Username, and Password were required and, in the previous version, they were the only values I filled in. After trying what you did, it led me sudo phpquery -v 7.2 -s apache2 -m smbclient, which also indicated that all was fine. (I previously did not know of the phpenmod command – thank you!)

I then tried changing to a more simple password using more verbose output: sudo smbpasswd owncloud -D 10 (Yes, I was getting very desperate…thinking that punctuation marks were being disallowed in the password :sweat_smile: ) and this output caught my eye:

pdb_set_homedir: setting home dir \\[server name]\owncloud, was

Once I tried that, it connected fine! I’m not sure if it was something in ownCloud or Samba…but I am using the same smb.conf file… Anyway, I appreciate your help the past day! It wasn’t the solution to my problem, but it did help me figure out what I should focus on. I’d been stuck for a day before I posted my message… :cry: Thanks a lot!!




Well, I am sorry that I could not help you out but I am glad that you figured it out by yourself :slight_smile:

Not at all! Your suggestions led me to the final solution. I wouldn’t give myself all the credit and say I figured it out all by myself… So, thank you for your time! :grinning:


1 Like