Symbolic link permission denied, shared folder over cifs

Solution 1:

You can't create symlinks on CIFS/samba shares. Symbolic links are intrinsic parts of the filesystem where the files are stored (aka the remote physical disk) and you can't modify the inodes of those unless you have direct access to the drive, which you don't due the characteristics of the CIFS protocol.

Simply put, you can't unless you are in the remote system itself.

There's an extension that would allow you to create symlinks from the remote server, but both the server must support it and you must mount the share which such option:

sfu

When the CIFS Unix Extensions are not negotiated, attempt to create device files and fifos in a format compatible with Services for Unix (SFU). In addition retrieve bits 10-12 of the mode via the SETFILEBITS extended attribute (as SFU does). In the future the bottom 9 bits of the mode mode also will be emulated using queries of the security descriptor (ACL). [NB: requires version 1.39 or later of the CIFS VFS. To recognize symlinks and be able to create symlinks in an SFU interoperable form requires version 1.40 or later of the CIFS VFS kernel module.

Your user would also need permission in the server side to create symlinks.