genel's picture

I am using proxmox 2.2.  I have tried to set up two of the Turnkey packages (several times) and I have the same problem.  When I try to use cifs to mount a share from my file server I get:

mount error: cifs filesystem not supported by the system
mount error(19): No such device
Refer to the mount.cifs(8) manual page (e.g. man mount.cifs)

I have tried the mount from webmin and from the command line, I get the same results.

The appliances I have tried are openphoto and owncloud.

I have done:

apt-get install samba

apt-get install cifs-util

apt-get install smbfs

(The last should be redundant with the second, but when things don't work you try stuff :()

Here is a typical command line:

mount -t cifs //vixen/c /tmp -o user=genel

I am prompted for my password and then I get the error above.

Without access to the files server the appliances are not of much use to me and it looks like a nice way to get some of the functionality I need.

Any help would be appreciated.






Jeremy Davis's picture

Firstly assuming that you are trying to share folders between TKL instances then IMO Samba/CIFS is not an ideal plan. Samba is Windows file sharing and there are other better options when sharing files Linux->Linux IMO. So my answer isn't really addressing your problem/errors, but suggesting a different way of acheiving your ends. I hope it is relevant...

Assuming that you are trying to share folders between TKL appliances running as OVZ containers on PVE then the best way IMO is to bind mount the folders you wish to share to the 'guest' appliance within PVE. No software to install and from within the container it appears to be part of the native filesystem. I don't recall the exact steps OTTOMH but if you search the Proxmox forums/wiki then you will find them.

Be aware though that for permissions to work as you would expect, the user IDs will need to match between appliances (which AFAIK they should by default for the default users - will only potentially be an issue if you have configured additional user accounts).

The other option (if they aren't both running as OVZ containers or are on different hosts - even if they are physical machines) is sshfs. You will need to install it on your guest appliance ('apt-get install sshfs') and if you aren't using the root user you will also need to configure fuse (have a google for 'sshfs' for details). Nothing needs to be configured on the host (although if you don't want to use root, then you'll need to configure a user account with the relevant permissions). On the guest you can manually mount the shares with the command:

sshfs <username>@<ipaddress-or-FQDN>:/remote/path /local/mount/path

You can also set it up in fstab to auto mount (although again you'll need to google as I don't recall the exact line OTTOMH).

Perhaps you could post back with the exact commands when you get it working to save others the effort of googling?

genel's picture

First thanks for taking the time to answer, I do appreciate you taking the time.  However I really need CIFS.

I have two machines I need to access files from.  The lesser important is my desktop machine which runs Windows 7.  The more important is a Ubuntu server running Greyhole (as part of Amahi).  Greyhole is a disk pooling service that runs in coordination with Samba, and only works through Samba.  I have commited to using this as my file service solution, since it provides some services I want and "everyone" supports CIFS.  So I need Samba to work if the OVZ containers are going to be able to access the file server where the data I would like to publish is located.

The file server does run as a virtual machine under proxmox (not a container but a VM).  But I think that is immaterial since the mount does not work against the Windows machine either (the example mount command was against vixen which is windows 7).

In light of your message and with so many options, I have to wonder if no one else is trying to do this.

Thanks again, for the information.


Jeremy Davis's picture

Sorry my answer wasn't relevant, but perhaps someone else will find it useful! :)

Looks like Eric has supplied some relevant info for you below. And whilst I don't use Samba much it should work (as Eric says). 

Good luck!

Eric (tssgery)'s picture

I used VMware vSphere but the steps should be the same no matter what hypervisor you use. Here are the steps I use:


1) Install smbfs. If I remember correctly, smbfs pulls in both cifs-utils and samba-common

apt-get install smbfs

2) Mount the remote filesystem. I normally do this via /etc/fstab but your mount command example should work as well. I just tried your mount command and it worked fine.

sudo mount -t cifs //diskstation/video /mnt/ttt -o user=eric


Note #1: If your cifs share is being exported from a machine running samba and you're using password authentication, have you run smbpasswd to set the password for your userid? I don;t think that's what you're hitting, but maybe?

Note #2: In your example you were trying to mount a remote filesystem to the /tmp mountpoint. I would NOT do that, /tmp is used by lots of things and it would be much better to have it local to the machine itself.

genel's picture

I thought I had tried that, but just to be sure, I did it again.  Here is what I got:

root@owncloud ~# apt-get install smbfs
Reading package lists... Done
Building dependency tree
Reading state information... Done
smbfs is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 12 not upgraded.
root@owncloud ~# mkdir /vixen
root@owncloud ~# mount -t cifs //vixen/c /vixen -o user=genel
mount error: cifs filesystem not supported by the system
mount error(19): No such device
Refer to the mount.cifs(8) manual page (e.g. man mount.cifs)

(I understand about tmp, it was just for the test at hand, so I made a new directory.)  I entered the correct password, interestingly I get the same error regardless of what I enter for password.

I tried to run smbpasswd, this is what I get:

root@owncloud ~# smbpasswd
New SMB password:
Retype new SMB password:
Failed to find entry for user root.

root@owncloud ~# smbpasswd genel
New SMB password:
Retype new SMB password:
Failed to find entry for user genel.

I will tell you that right now my working theory is that the message is literally true and something is missing from the kernel.  I don't know enough about OVZ to know if its a problem with the template or something in the proxmox build.  I am game to try whatever anyone suggests.


genel's picture

I found this.


I have not gotten the suggested fix to work, but I will look into it some more tomorrow.  I am off to bed.

Eric (tssgery)'s picture

Please let us know if this works, it would certainly explain why I have no issue and you do.

Jeremy Davis's picture

Ahh. Looks like it is a OVZ/PVE issue. Workaround looks easy enough though... Install Samba client on PVE host, mount --bind share to container.

Eric Thibodeau's picture

I struggled for 45 minutes on this one until I realized I had to specify the 'target' UID as in:

mount.cifs \\\\\\storage /mnt/xfer/ -o user=kyron -o uid=1001

Of course, this is the UID of the user (kyron here) on the PDC appliance.

Otherwise, I would keep getting this on the PDC:

[2014/04/23 02:58:13.733241,  0] smbd/trans2.c:1259(unix_filetype)
  unix_filetype: unknown filetype 0

And this on the client side:

kyron ~ # touch /mnt/xfer/test
touch: cannot touch ‘/mnt/xfer/test’: Permission denied


Jeremy Davis's picture

That's great info that I'm sure someone will benefit from! :) I imagine that it's something that would be intuitive for some but would be a major stumbling block for someone without the curse of knowledge! :)

Eric Thibodeau's picture

I no longer get orgasmic from my ignorance, so I try to remain blissful about it.

Other than that, I am seeking a much better solution to this 'uid' hack since, IMHO, Samba should be configured/be able to "write to folder using authe'd UID"... instead of having to feed the server the ID it should be using/translating to... (It's like the worst of both Samba and NFS :D) All of this is quite ironic given I onlt have Macs and Linux boxes...using samba to share data...phew!

Sooo...if anyone out there is more versed in Samba...

Jeremy Davis's picture

It would be nice if you could mount a Samba share unauthenticated at boot then write to it with the relevant user credentials once logged in.

I just don't think it's possible though. Even in Windows you need to mount a remote share with authentication details of an account on the remote PC. The only way around that is if both computers are part of a domain (which users are already authenticated against). Even then really the details of the user exist on both local and remote computer.

Just rereading your last post perhaps part of the issue is that you have the same username on both machines? And Mac being Unix based your server is getting confused...?

Add new comment