Ask Your Question

Can't access an extern hdd samba share on fedora 19

asked 2014-04-04 13:18:21 -0500

this post is marked as community wiki

This post is a wiki. Anyone with karma >750 is welcome to improve it.

Hi, my name is Lauro, and since fedora 8 I use this os, sometimes fighting with him not a little, trying to get it going when things do not work. Lately with F19 I have a problem that seems trivial that I can't realy resolve. I set a samba share on a usb device attached to my laptop but I can't access it from any other host of the lan; I can access home or other shares and I can view the [extern hdd] share, but there is no way to enter in it. I tried with many usb devices with the same result; it seems samba user does not have the rights to this directory. I post my "/etc/samba/smb.conf" file:

    workgroup = MYGROUP
    server string = Samba Server Version %v
    log file = /var/log/samba/log.%m
    max log size = 50
    security = user
    passdb backend = tdbsam
    load printers = yes
    cups options = raw
    unix extensions = No
    comment = Home Directories
    read only = No
    browseable = No
    comment = All Printers
    path = /var/spool/samba
    printable = Yes
    print ok = Yes
    browseable = No
    path = /home/share
    read only = No
    create mask = 0777
    directory mask = 0777
    guest ok = Yes
[extern hdd]
    path = /run/media/<my user>/MULTIBOOT
    force user = <samba user>
    read only = No
    guest ok = Yes

In F19 the directory and permissions of the mounted media are :

drwx------. 18 <my user> <my user> 8192  1 gen  1970 /run/media/<my user>/MULTIBOOT/

Sorry for my terrible English, hope you have understood me.

edit retag flag offensive close merge delete


Try to follow this answer and tell me if helped you.

NickTux gravatar imageNickTux ( 2014-04-04 17:58:29 -0500 )edit

1 Answer

Sort by ยป oldest newest most voted

answered 2014-04-04 20:46:37 -0500

ElleBi gravatar image

updated 2014-04-05 08:43:13 -0500

I noticed that in addition to impossibility to share external hdd, I cannot yet share internal partitions of the disk with fat32, ntfs or ext4 FS. However I think the problem is due to the fact that I cannot set security = share , as this option is deprecated in samba 4. In fact with a ubuntu system that uses a previous version of samba with security = share , I can normally share usb devices and partitions. Anyway you can share folders in F19 without user/passwd in the same way with the line map to guest = Bad User after security = user. Nevertheless I still cannot share external hdd and internal partitions!

Finally I solved!

Only one word: SELinux; To access the shares must set permissive selinux: sudo setenforce 0. So the samba configuration matters a little, that is you can set a user/password login or not (with that I wrote above) or any option in the [shares] section. What seems strange to me, is the selinux denials were not logged on journal; checking it with sudo journalctl -f command, I would have realized before the problem. However, this is the solution and I can say I won this battle with f19.

edit flag offensive delete link more

Question Tools

1 follower


Asked: 2014-04-04 13:18:21 -0500

Seen: 754 times

Last updated: Apr 05 '14