PDA

View Full Version : can't mount my samba share



grocanar
23rd June 2008, 10:21 AM
i m trying to mount a samba share on my F9 machine

i type

mount --verbose -t cifs -o user=doutrele //wpublic.int-evry.fr/doutrele /tmp/toto
parsing options: rw,user=doutrele
Password:

mount.cifs kernel mount options unc=//wpublic.int-evry.fr\doutrele,ip=157.159.10.215,pass=xxxxxxxxx, ver=1,rw,user=doutrele
mount error 2 = No such file or directory
Refer to the mount.cifs(8) manual page (e.g.man mount.cifs)

if i use smbclient
smbclient //wpublic.int-evry.fr/doutrele -U doutrele
Enter doutrele's password:
Domain=[MICRO] OS=[Unix] Server=[Samba 3.0.25b-1.el5_1.4]
smb: \>

it works

Have someone already seen that problem?

jayaram
23rd June 2008, 11:15 AM
Try the following.

mount.cifs //wpublic.int-evry.fr/doutrele /mnt/mountpoint ľo username=username password=password domain=domainname

grocanar
23rd June 2008, 12:41 PM
thzanks for your answer but it doesn't work
it keep on asking for the password and i got the same error message

forkbomb
23rd June 2008, 02:12 PM
Out of morbid curiosity, what happens if you use whacks (\\) for the share name instead of slashes (//)?

mount --verbose -t cifs -o user=doutrele \\wpublic.int-evry.fr\doutrele /tmp/toto


I'm no Samba expert, but maybe that makes a difference? (Doubt it...)

grocanar
23rd June 2008, 02:39 PM
well the same error
i had to escape the \ but i got the same result :(

jayaram
24th June 2008, 06:46 AM
Are you able to view the samba share in GUI ? Have you tried it in "run command" ? is it working ?

And what is the error message for

mount.cifs //wpublic.int-evry.fr/doutrele /mnt/mountpoint ľo username=username password=password domain=domainname

glennzo
24th June 2008, 09:36 AM
sudo mount -t cifs //johnbonham/temp /media/test/ -o username=glenn,password="",uid=500,gid=500 was a successful command here. The folder johnbonham/temp mounted to a local folder /media/test without error.

grocanar
24th June 2008, 10:08 AM
well the share is not browseable as it s a "home" folder of unix machine

the result of the command is
mount.cifs //wpublic.int-evry.fr/doutrele /mnt/mountpoint ľo username=username password=password domain=domainname

mount error 2 = No such file or directory
Refer to the mount.cifs(8) manual page (e.g.man mount.cifs)

glennzo
24th June 2008, 10:32 AM
Shouldn't it be mount -t cifs and not mount.cifs?

grocanar
24th June 2008, 03:29 PM
i got exactly the same result

glennzo
24th June 2008, 05:35 PM
I may be wrong but I think great difficulty is encountered when one tries to share "home".

bbfuller
24th June 2008, 10:26 PM
Just to add to the variety of mount commands, I use:


mount -t cifs //atx13/boxroom /mnt -o username=bbfuller

where the boxroom share is a directory 'boxroom' in bbfuller's home area on the remote machine atx13.

The catch that I find is that by default, sharing part of your home area, even to yourself, is blocked by SELinux if you have it enabled.


setsebool -P samba_enable_home_dirs=1

enables such sharing.

I've only used that once just during testing so I can't verify it directly now as I don't usually have SELinux enabled.

I also made a note that if I wanted to make a share directly off '/' say for example:


/testsamba

and call the samba share testsamba as well as calling the directory that, I needed to run the command:


chcon -R -t samba_share_t 'testsamba'

granade
27th June 2008, 02:08 PM
Would this work? I want to access my fedora samba share from another fedora laptop i want to use as a picture frame.

By bbfuller:

Now as an example:

mount -t cifs //192.168.0.13/fedora /mnt -o username=valid_samba_user

should make the share (in this case fedora) you have set on the machine 192.168.0.13 appear under /mnt on the machine you issued the command from.

If you want to address the machines by name instead of number then edit the file:

/etc/nsswitch.conf

so that the line:

hosts: files dns

reads:

hosts: files wins dns

you may well find extra entries in the hosts line, it appears important that wins appears immediately after 'files' and before any other entries.

Now the command above can be modified to read:

mount -t cifs //atx9/fedora /mnt -o username=valid_samba_user

bbfuller
27th June 2008, 11:14 PM
Hello granade

Well, it still works for me.

I'm not sure of the thread you got this from and how much we had discussed the provisos first though.

When I do this I have a samba user and a Fedora user of the same name both with the same password.

I have a samba server running on all machines I want to address by name.

The samba and Fedora users are the same on each machine.

I don't run SELinux or when I do I make special provision for samba sharing.

I've taken all the steps to allow samba through the Fedora firewall.

granade
1st July 2008, 03:05 PM
Sorry for taking so long i responding. I setup a samba share instead of a mount.

bbfuller
1st July 2008, 03:28 PM
Hello granade

They are usually the same thing, certainly anywhere I use the mount command I do it to to a share I have made.

Once I have made that share I can also use the "Gnome Menu - Places - Network" to access it as well.