Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place. |
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
 |
01-09-2002, 04:57 PM
|
#1
|
Member
Registered: Aug 2001
Distribution: Debian Etch
Posts: 510
Rep:
|
mounting samba share
How do I use the mount command to mount a samba share on my local network? I tried looking in the man, but I couldn't figure it out.
|
|
|
01-09-2002, 05:09 PM
|
#2
|
Member
Registered: Nov 2000
Location: Hermon, ME
Distribution: slackware
Posts: 201
Rep:
|
try 'man smbmount'
|
|
|
01-09-2002, 08:13 PM
|
#3
|
Member
Registered: Dec 2001
Distribution: redhat
Posts: 154
Rep:
|
smbmount
if you are using a somewhat new version of smbmount, it could be
smbmount //computer/sharename /mnt/point
or
smbmount //computer/share /mnt/point -o ip=x.x.x.x
check the man page or other docs for other options like username/password
|
|
|
01-09-2002, 10:14 PM
|
#4
|
Member
Registered: Jan 2002
Location: Austin, Texas
Posts: 31
Rep:
|
this is the way I mount samba shares on other machines:
mount -t smbfs -o username=name,password=password //machinename/sharename /mnt/smbshare
This work but I don't know if it's the best way
|
|
1 members found this post helpful.
|
01-10-2002, 06:45 PM
|
#5
|
Member
Registered: Aug 2001
Distribution: Debian Etch
Posts: 510
Original Poster
Rep:
|
When I try this command:
Code:
mount -t smbfs //192.168.168.253/tmp /mnt/smbshare
I get the following error:
Code:
Could not resolve mount point /mnt/smbshare
Do you know what this means?
|
|
|
01-10-2002, 06:50 PM
|
#6
|
Member
Registered: Jan 2002
Location: Austin, Texas
Posts: 31
Rep:
|
i means there is no /mnt/smbshare. create one first:
#mkdir /mnt/smbshare
|
|
|
01-10-2002, 07:06 PM
|
#7
|
Member
Registered: Aug 2001
Distribution: Debian Etch
Posts: 510
Original Poster
Rep:
|
Ahh ok. I thought it would just dynamically create that directory for me. Thanks, now it works.
How do I make it so I do this mount every time my linux box boots?
|
|
|
01-10-2002, 07:11 PM
|
#8
|
Member
Registered: Jan 2002
Location: Austin, Texas
Posts: 31
Rep:
|
that depends on what *nix you are using. If you are using redhat, the simple way is to add that exact mount command to your /etc/rc.d/rc.local file. The right way would be to add it to /etc/fstab but I can't explain how to do that. Try doing a 'man fstab' and hack away.
|
|
|
01-10-2002, 08:54 PM
|
#9
|
Member
Registered: Dec 2001
Distribution: redhat
Posts: 154
Rep:
|
automount
or u could use the automounter... lookup autofs for details
|
|
|
10-01-2003, 05:47 PM
|
#10
|
LQ Newbie
Registered: Oct 2003
Distribution: Ubuntu 6.0
Posts: 14
Rep:
|
ive made an sh file to mount my windows share for me... ive typed this in it...
mount -t smbfs -o username=samba,password=samba //Desktop/Public /mnt/public
ive tried everything i know, including reading the man files... i can't find smbmount either... and both dont work... ive also tried making the credentials file but nothing works... it comes out with an error of the following
mount: mount point \\Desktop\Public does not exist
./mountshares.sh: /mnt/public: is a directory
thing is, i know this directory works because when i use my other home made sh file containing
/usr/local/samba/bin/smbclient \\\\Desktop\\Public -U samba samba
it seems to work fine... and it does connect...
ive also tried to use \\\\Desktop\\Public in the original sh file to mount my shares but it doesn't seem to work, it gives me the same error...
PLEASE HELP ME!!! it seems as if its not working no matter what i try, ive also recompiled samba 3 times and each time it doesn't work...
as a note im running slackware 8.1
Looking forward to getting some help or insight on this... thanks in advance
|
|
|
07-08-2011, 01:29 AM
|
#11
|
LQ Newbie
Registered: Mar 2010
Posts: 1
Rep:
|
hi,
i tried the following command
sudo mount -t smbfs 10.102.11.79:/mnt /home/user/dir
but i get the error:
mount: unknown filesystem type 'smbfs'
What could be the problem?
I have samba installed on both the linux machines.
|
|
|
07-08-2011, 04:38 AM
|
#12
|
Moderator
Registered: Dec 2009
Location: Germany
Distribution: Whatever fits the task best
Posts: 17,148
|
Try it with -t cifs instead of -t smbfs.
|
|
|
07-09-2013, 11:55 PM
|
#13
|
LQ Newbie
Registered: Jul 2013
Posts: 1
Rep: 
|
solution
Quote:
Originally Posted by TobiSGD
Try it with -t cifs instead of -t smbfs.
|
guys the solution is:
# mount -t cifs -o username:<username of the smb server> <nfs-server>:/<share> /mnt/<share-loc>
- dont have to add the password option as it will be prompted when the command is entered.
- make sure the package "smbmount" is installed else install it (i.e. ubuntu --> apt-get install smbmount"
e.g.
# mount -t cifs -o username:john server1:/share1 /mnt/MyShare
|
|
|
07-15-2013, 08:50 PM
|
#14
|
LQ Newbie
Registered: Mar 2009
Distribution: Debian lenny & squeeze servers. Mint 13 and 14 desktops
Posts: 16
Rep:
|
Quote:
Originally Posted by squirrelj
guys the solution is:
# mount -t cifs -o username:<username of the smb server> <nfs-server>:/<share> /mnt/<share-loc>
- dont have to add the password option as it will be prompted when the command is entered.
- make sure the package "smbmount" is installed else install it (i.e. ubuntu --> apt-get install smbmount"
e.g.
# mount -t cifs -o username:john server1:/share1 /mnt/MyShare
|
After months of cifs hell, I decided the right answer was to use NFS, and never looked back :-)
OK that means you need the far end to run *nix as well...
|
|
|
All times are GMT -5. The time now is 11:01 AM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|