LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 02-22-2004, 10:59 PM   #1
fawkes
LQ Newbie
 
Registered: Feb 2004
Posts: 6

Rep: Reputation: 0
Mounting Windows computer on LAN


I am running Red Hat 9 and I have a windows XP computer on my LAN. I want to beable to access files on it from my Linux box. I do everything through the terminal. I thought the best way to do it was by mounting it and I tried to read the man files to learn how to do it but couldn't get anywhere. Any advice?
Thanks
Michael
 
Old 02-22-2004, 11:07 PM   #2
Demonbane
LQ Guru
 
Registered: Aug 2003
Location: Sydney, Australia
Distribution: Gentoo
Posts: 1,796

Rep: Reputation: 47
here's an example mounting a share say called \\ws1\share
Code:
mount -t smbfs -o username=yourusername,password=yourpass //ws1/share /mount/point
 
Old 02-23-2004, 06:56 AM   #3
fawkes
LQ Newbie
 
Registered: Feb 2004
Posts: 6

Original Poster
Rep: Reputation: 0
Quote:
Originally posted by Demonbane
here's an example mounting a share say called \\ws1\share
Code:
mount -t smbfs -o username=yourusername,password=yourpass //ws1/share /mount/point
I am still a little unsure how to use that comand. I know my windows computer local IP address so how do I put that in? what would the username and password be? also, can I have the mountpoint be anywhere? is smbfs the file system for ntfs?

Thanks agian
 
Old 02-23-2004, 07:40 AM   #4
Demonbane
LQ Guru
 
Registered: Aug 2003
Location: Sydney, Australia
Distribution: Gentoo
Posts: 1,796

Rep: Reputation: 47
It depends on how your winXP shares are configured, if it doesnt require a valid username/password to access then you can leave out the options altogether.
You can substitude the hostname with the IP address, yes the mount point can be anywhere as long as it exists. Smbfs is just a name you give to mount telling it that you want to mount a remote filesystem using SMB(Server Message Block) protocol, which is what Windows file and printer sharing is built on. The remote system can have any type of local filesystem, as long as both sides support SMB protocol, they'll be able to share resources. Like how your Windows machines can browse a webpage from any webserver regardless of the platform and filesystem, as long as both sides can talk in http.

Last edited by Demonbane; 02-23-2004 at 10:00 PM.
 
Old 02-23-2004, 03:52 PM   #5
fawkes
LQ Newbie
 
Registered: Feb 2004
Posts: 6

Original Poster
Rep: Reputation: 0
Ok, I must be doing something really stupid wrong. I mad a directory in my home drive called wind. The is where I want to mount my computer running windows to. so I typed

mount -t smbfs -o //192.168.2.3 ./wind

the windows computer has the local IP of 192.168.2.3. when I type that in it jsut gives me the man pages for mount, so I am not sure if it is how I am typing it in or if it is something else. What I think I might be doing wrong is how my files are getting shared on my Windows computer, how do I go about making it so that the files are shared on Windows (sorry, I know that might be a Windows question). Thanks for your guy's help I am fairly new to this networking stuff.

Thanks
 
Old 02-23-2004, 05:00 PM   #6
mhiggins
Member
 
Registered: Feb 2004
Posts: 140

Rep: Reputation: 15
mount -t smbfs -o username=guest,password= //192.168.2.3/some_share_name ./wind

First you must run this as root or use sudo. If you don't know what sudo is ..man sudo.
This also assumes you allow guest access on your winXP box which is off by default. You may want to add a user to the win box like "linuxuser" with some pass "somePass". You also need the name of the share you are connecting to i.e. share a folder called tolinux. If you do this your command would lok like this.

mount -t smbfs -o username=linuxuser,password=somePass //192.168.2.3/tolinux ./wind

if you want to be prompted for a password

mount -t smbfs -o username=guest,password //192.168.2.3/tolinux ./wind

The reason that mount returned the mount options is because you gave it the -o flag (the options flag) with no options. Here is a breakdown of the command

mount -t smbfs -o username=guest,password //192.168.2.3 ./wind
mount -t filesystem_type -o option1,option2 //where_we_are_mounting_from /where_we_are_mounting_to


I know its so annoying when some one says read the man page or man this or man that but it is important to read them. They are technical documents that you need to learn how to read. The more you read them the better you will get at reading them the more problems you will be able to solve on your own!
 
Old 02-23-2004, 05:34 PM   #7
davidbalt
Member
 
Registered: Feb 2004
Distribution: Gentoo -- always from stage1
Posts: 85

Rep: Reputation: 15
The above post is very correct. I have been working on getting Samba working in various ways for a while. I would say:

1) Make a user on the XP box (linux, linuxuser, whatever)

2) You have to SHARE something on the windows box in order to mount it. Simply putting in your windows' box's ip address won't do.

3) So share something, C: if you want.

4) mount -t smbfs -o username=linux,password=password //192.168.2.3/sharedfolder /mnt/wind

5) if you want to be able to do it next time you reboot, learn about /etc/fstab and how to make sure the Windows box is automounted.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
connecting to a computer in a Lan from outside Tinku Linux - Networking 7 06-03-2005 01:51 PM
How to set up LAN between two computer vanhelsing Linux - Networking 14 07-16-2004 10:47 AM
I can't share my computer on LAN thuongkiet82 Linux - Networking 2 05-20-2004 07:06 AM
Why would a windows computer smoke a linux computer for download speed ? lostboy Linux - General 4 10-21-2003 05:20 PM
How can I get access to a computer on my LAN? teeno Linux - Networking 5 07-17-2001 07:44 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 09:35 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration