Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game. |
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.
|
|
12-12-2006, 04:40 PM
|
#1
|
LQ Newbie
Registered: May 2003
Location: Allentown, PA
Distribution: Red Hat Linux 9
Posts: 6
Rep:
|
Symbolic link to Windows mshome path
I have a WindowsXP machine containing most of my programming tools, and a laptop with the latest version of Fedora. Source code is on my XP machine in the workgroup "MSHOME". What I would like to do is create a symbolic link on the Linux machine (ln -s) to the directory on the Windows machine that contains the code, so that I can continue to edit it on the XP machine but compile it on the Linux machine.
I tried looking this stuff up, found some advice using smbfs, and found out that Fedora uses cifs, which doesn't like the workgroup name. I'm using DHCP, so specifying IP is inconvenient.
Thanks in advance.
|
|
|
12-12-2006, 05:53 PM
|
#2
|
LQ Guru
Registered: Jan 2003
Location: Seymour, Indiana
Distribution: Distribution: RHEL 5 with Pieces of this and that.
Kernel 2.6.23.1, KDE 3.5.8 and KDE 4.0 beta, Plu
Posts: 5,700
Rep:
|
Have you mounted the share from the windows machine?
Then you should be able to use the ln command to the mounted directory.
It may be better to just create a share of the directory itself.
Brian
|
|
|
12-13-2006, 08:44 AM
|
#3
|
LQ Newbie
Registered: May 2003
Location: Allentown, PA
Distribution: Red Hat Linux 9
Posts: 6
Original Poster
Rep:
|
When mounting, I have to use the CIFS file system. It requires specification of the address of my PC, and it doesn't accept Samba addresses. How can I specify the address of the WinXP machine without specifying the IP address (which will vary due to VNC)?
Thank you.
|
|
|
12-13-2006, 12:33 PM
|
#4
|
LQ Newbie
Registered: May 2003
Location: Allentown, PA
Distribution: Red Hat Linux 9
Posts: 6
Original Poster
Rep:
|
In particular, using the CIFS file system, what would the mount command-line look like if I wish to mount the directory at mshome/hppav/c/work/source/.
Thank you!
|
|
|
12-13-2006, 05:48 PM
|
#5
|
LQ Guru
Registered: Jan 2003
Location: Seymour, Indiana
Distribution: Distribution: RHEL 5 with Pieces of this and that.
Kernel 2.6.23.1, KDE 3.5.8 and KDE 4.0 beta, Plu
Posts: 5,700
Rep:
|
Is the dhcp server a linux machine or a store bought router?
Brian
|
|
|
12-13-2006, 09:51 PM
|
#6
|
Member
Registered: Sep 2004
Location: Philippines
Distribution: Slackware
Posts: 143
Rep:
|
have you tried mounting it and editing /etc/fstab
so that the fstab will auto mount it at startup
hope this helps| £Ä3
Last edited by kenji; 12-13-2006 at 10:04 PM.
|
|
|
12-14-2006, 12:30 AM
|
#7
|
LQ Newbie
Registered: May 2003
Location: Allentown, PA
Distribution: Red Hat Linux 9
Posts: 6
Original Poster
Rep:
|
The DHCP server is a Linksys router. Thank you for the tip on auto-mounting, thus far however I haven't been able to get the mount command to work.
Is there something about the Windows workgroup that makes it difficult for the mount command to find it?
Thanks in advance!
|
|
|
12-14-2006, 03:42 AM
|
#8
|
Member
Registered: Sep 2004
Location: Philippines
Distribution: Slackware
Posts: 143
Rep:
|
try this. hope this helps|£Ä3
mount -t smbfs -o username=username //hostname/mount_folder /folder
editing fstab
#
# /etc/fstab
#
# <device> <mountpoint> <filesystemtype><options> <dump> <fsckorder>
/dev/hdb5 / ext2 defaults 1 1
/dev/hdb2 /home ext2 defaults 1 2
/dev/hdc /mnt/cdrom iso9660 noauto,ro,user 0 0
/dev/hda1 /mnt/dos/c msdos defaults 0 0
/dev/hdb1 /mnt/dos/d msdos defaults 0 0
/dev/fd0 /mnt/floppy ext2 noauto,user 0 0
/dev/hdb4 none ignore defaults 0 0
none /proc proc defaults
/dev/hdb3 none swap sw
# Windows Share
//hostname/mount_folder /folder vfat defaults 0 0
Last edited by kenji; 12-14-2006 at 03:54 AM.
|
|
|
12-14-2006, 06:54 AM
|
#9
|
LQ Newbie
Registered: May 2003
Location: Allentown, PA
Distribution: Red Hat Linux 9
Posts: 6
Original Poster
Rep:
|
Thank you - this is mounting with smbfs, which apparently works under other Linux flavors, but Fedora (apparently) doesn't provide smbfs so I have to use cifs. I haven't figured out how to specify the path to the target machine with cifs.
|
|
|
12-14-2006, 05:36 PM
|
#10
|
LQ Guru
Registered: Jan 2003
Location: Seymour, Indiana
Distribution: Distribution: RHEL 5 with Pieces of this and that.
Kernel 2.6.23.1, KDE 3.5.8 and KDE 4.0 beta, Plu
Posts: 5,700
Rep:
|
You should be able to mount using workgroup and share names. There are some links in google search mention Fedora leaves some of the support to use share names with cifs. smbfs should be present in the default fedora kernel.
But the big issue is you cannot use the share name unless you have it mapped to an IP in your /etc/hosts file. Since you can only use DHCP to get an IP and not use a static IP then this will not work for you.
I have not seen any scripts out there to generate a fresh hosts file every so often. What I think it would involve is using nmap to search a certain range of IPs. Take that data and use the smbclient program to generate a list of shares and machine names with IPs. From there take the data from smbclient compare it to a second data file with the share names and when the sharename from the smbclient data matches from the list data file. One can then generate a updated /etc/hosts file. You can then add a cron timetable to run the app every so often to keep up dated but will start to become a mess between other machine reboots and shares that are already mounted. If you managed this then one should unmount all shares and then reboot other machines.
No really easy way I know of like Windows does to list shares it finds.
When mention the dhcp I was hoping for a linux dhcp server. You can have it check with a list of mac addresses so when a machine tries to contact the dhcp server it will always be giving a certain IP. From that you can have a static /etc/hosts file. You can always disable the DHCP on the router and run a DHCP server on the Linux box if you wish.
Brian
|
|
|
All times are GMT -5. The time now is 10:35 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
|
|