Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I'm trying to create a symlink with a network shared folder (located in a windows sys) from my ubuntu system using the command.

ln -s smb://sys-name/www www

It creates a link but it says the link is broken. But the path exists and I can browse to the network folder path.

Could anybody point me the issue?

Basically, I'm trying to create the link as I'm not able to access the network shared files from eclipse, so thought of making use of the symlinks, but didn't work out. Any other workaround for this ?

Thanks in advance, - Pavan Kumar

share|improve this question

migrated from stackoverflow.com Nov 1 '09 at 0:47

This question came from our site for professional and enthusiast programmers.

2 Answers 2

You can't make a link to something which isn't in your filesystem. That you can browse it is a feature of your file browser; that's why it doesn't work with eclipse or ln.

What you want to do is mount the remote filesystem into your filesystem. For example mount -t cifs //sys-name/www www. See man mount.cifs for more details.

share|improve this answer

As others pointed out, mount the folder instead. I'd suggest to create a mount point under /mnt, like /mnt/www (historically, /mnt is used for the non-removable mount points, /media is recommended for removable media only). Then, mount the network share, e.g.:

mount -t cifs //server/share /mnt/www --verbose -o user=username

If you don't want to type this every time you login, you could add an entry to /etc/fstab. If you want to learn more about /etc/fstab, see How to edit and understand /etc/fstab.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.