Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to map to a windows folder

Status
Not open for further replies.

cb49747

MIS
Apr 23, 2002
181
US
I'm running a linux machine with samba and this is the pdc. There are some folders on the linux box that are shared and these work fine. However all the clients are windows xp machines, and there is one client that is sharing a folder and would like to be able to access it from the linux machine. Can get to it fine from the windows machines.

all machines are in the domain xxx and the windows client machine is yyy-253

I have tried to use mount but get an error that the folder is unacessable.

Appreciate any help.

Thanks

Chris Burger
 
wanted to add.

I using redhat 7.2 samba 2.27

the mount command is mount -t smbfs "//192.168.1.253/projects_bak /mnt/projects_bak

The error I get is this
mount: wrong fs type, bad option, bad superblock on //192.168.1.253/projects_bak, or too many mounted file systems

I have found a similar thread in this forum, and it looks as if the person loaded samba and used the command smbmount. I do not have the command smbmount do I need to reload samba? How do I do it with out loosing the setup I have now? It took me forever to get this setup as a pdc.

Chris
 
mount -t smbfs "//192.168.1.253/projects_bak /mnt/projects_bak
won't work.

You need to tell as who you want to connect. Always use "-o" option for such mount operations. Within the -o option you can define the "username" and "password" for the User who has access to the share.

try something like:
mount -t smbfs -o username=<username>,password=xxx //192.168.1.253/projects_bak /mnt/projects_bak


 

using this
mount -t smbfs -o username=<username>,password=xxx //192.168.1.253/projects_bak /mnt/projects_bak

I still get the same error message
mount: wrong fs type, bad option, bad superblock on //192.168.1.253/projects_bak, or too many mounted file systems

Any other suggestions?

Chris


 
By the way I am using a valid username and password not <username> and xxx
 
what kind of linux are you running?

could you check if you got the samba module support compiled in your kernel.

modprobe -l | grep smbfs

if not you may need to recompile your kernel and set the samba module.

 
When I run the command

modprobe -l | grep smbfs

I get the error message

bash: modprobe: command not found

I'm running as root.
 
?
@cb49747

Ok, no need to matter. i think you got the commands "lsmod, insmod & rmmod?".
The other way you can look for all your modules is:
/lib/modules/2.4.22/kernel/drivers/usb/hid.o

there should be a "fs" directory with all your loadable modules for Filesystems. In my example i took the "usb" directory and loaded the "hid" module.

localhost# insmod hid
localhost# lsmod
Module Size Used by Not tainted
hid 10076 0 (unused)

unload the module with "rmmod",
localhost# rmmod hid
localhost# lsmod
Module Size Used by Not tainted
--snip-snip-----------------------------------------------

hope this helps

rgd´s



 
LGTObug,

OK I got modprobe to work, was trying to run it thru telnet with no avail, hooked of a keyboard and monitor to the server and low and behold it worked.

anyway, the when I run the modprobe command above I get this

/lib/modules/2.4.20-18.7/kernel/fs/smbfs/smbfs.o

not sure what that means, but I guess it means I have the module compiled.

appreciate all your help, anymore ideas?

Chris Burger
 
Wanted to repost this as I did not figure this out yet.

Here is where I am.

I use this command:
mount -t smbfs -o username=user1 //192.168.1.253/projects /mnt/projects_bak

and the message I get back is:
wrong fs type, bad option, bad superblock on //192.168.1.253/projects, or too many mounted file systems

When I run the command:
mount -t smbfs -o username=<user1> //192.168.1.253/projects /mnt/projects_bak

I get the following:
bash:user1: No such file or directory

If anyone has any ideas I would greatly appreciate them.

Chris Burger
 
Yep /mnt/projects_bak is there.

No question is silly if you do not know the answer.

Chris Burger
 
did you load your module with "modprobe smbfs" or "insmod smbfs" ( with insmod you need to be in the directory where the module is located, like: /lib/modules/2.4.20-18.7/kernel/fs/smbfs/smbfs.o ) then type: insmod smbfs.o

to check if the module is loaded, run "lsmod"
to remove a module type: "rmmod <name-of-module>"

hope this helps

regards
 
I went into the /lib/modules/2.4.20-18.7/kernel/fs/smbfs/

and entered insmod smbfs

did a ls

saw smbfs.o

Still have the same problem. However I have not rebooted since then. Could that be the problem, or is that the windows in me coming out again.

Chris
 
rebooting is 'Windows coming out', and not only not necessary, but wrong. The module is unloaded on shutdown and has to be loaded again.

LTGO isn't correct when claiming the issue with directories.
insmod <modulename>
insmod <filename> is both correct, and independent from the directory you're located.
<filename> is usually <modulename>.o, <modulename>.ko for kernel >= 2.6

But modprobe <modulename> is the recommended way.
Note that you usually have to be root to ...mod... something.

But I don't have a real help for you - not using samba.

But samba is a fileserver for windows-clients - I don't understand why you use samba on linux for mounting a filesystem --- the whole idea...?

seeking a job as java-programmer in Berlin:
 
I think theres a work around.

In Unix / Linux, `link -S` allows you to dynamically link a folder across file systems and so if there is a common minimum convention of naming, it might be possible to set it up such that:

The Windows users access thru Samba and the Linux person thru the linked file system.

BTW,

It's some time since I worked with UNIX and very little with Linux. So the flag for `ln` may be wrong.

Also, offhand, I can't say how much additional disk space would be required for this.

End
 
Hmmm. Reread the first message.
The server has a folder
server://foo/bar
and the client want's to use it as
client://home/joe/bar

You could use nfs - network file system.
On the client, in the fstab write:

Code:
server:/home/joe/bar	/home/bar	nfs	defaults,user,rw	0 0
On the server you need a file /etc/exports
man exports should lead you to the details, a poor solution would be:
/foo/bar *(rw)

Of course nfsd has to run on the server.

seeking a job as java-programmer in Berlin:
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top