LinuxQuestions.org
Latest LQ Deal: Complete CCNA, CCNP & Red Hat Certification Training Bundle
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 10-20-2008, 09:56 AM   #1
raj_hcl1986@rediffma
LQ Newbie
 
Registered: Oct 2008
Posts: 21

Rep: Reputation: 15
Why Symlink is required?


Hi.

I m newbee in Linux and have a querry, why do we need a symlink and whats its advantage. Pls explain in a simple language.
 
Old 10-20-2008, 10:09 AM   #2
arckane
Member
 
Registered: Sep 2005
Location: UK
Distribution: Gentoo/Debian/Ubuntu
Posts: 307

Rep: Reputation: 38
a symlink is the equiv to a shortcut.

You don't 'need' them, but they can be damn handy.
 
Old 10-20-2008, 10:20 AM   #3
David the H.
Bash Guru
 
Registered: Jun 2004
Location: Osaka, Japan
Distribution: Debian + kde 4 / 5
Posts: 6,834

Rep: Reputation: 1976Reputation: 1976Reputation: 1976Reputation: 1976Reputation: 1976Reputation: 1976Reputation: 1976Reputation: 1976Reputation: 1976Reputation: 1976Reputation: 1976
Quote:
Originally Posted by arckane View Post
a symlink is the equiv to a shortcut.
...only better. At least symlinks work reliably and for the most part transparently; that is, so that you can really access and manipulate the file through its symlink as if it were actually in the symlink's location. I don't think I've ever seen a Windows shortcut that you could do anything useful with.

As for the OP's question, a symlink is just that, a link that lets you access a file from a location other than the one it physically resides in. It's the kind of thing that has a multitude of uses, such as "collecting" a bunch of separate files into one directory without actually moving them from the original location, or giving a file with a hard-to-type name one that's easier to use, again without messing with the original.

A good use of symlinks can be found in the /dev directory. Your disk drive devices might all be labled /dev/hda, /dev/hdb, dev/hdc, and so on, without anything to differentiate them. But you can use udev rules to create symlinks such as /dev/cdrom, /dev/dvd-r, /dev/mainhdd, and so on, so that you can always access the drive you want without confusion.
 
Old 10-20-2008, 10:33 AM   #4
i92guboj
Gentoo support team
 
Registered: May 2008
Location: Lucena, Córdoba (Spain)
Distribution: Gentoo
Posts: 4,074

Rep: Reputation: 386Reputation: 386Reputation: 386Reputation: 386
http://en.wikipedia.org/wiki/Symbolic_link
 
Old 10-20-2008, 11:04 AM   #5
raj_hcl1986@rediffma
LQ Newbie
 
Registered: Oct 2008
Posts: 21

Original Poster
Rep: Reputation: 15
Hey David, thanks.
it was useful.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
Would a symlink help ? budword Linux - Software 4 07-11-2007 01:47 PM
Symlink Fredde87 Linux - General 14 09-30-2005 09:06 PM
symlink mikedelo Linux - Software 2 03-28-2004 01:32 PM
symlink evannextel Linux - Newbie 1 09-17-2003 04:54 PM
Symlink Mestax Linux - Newbie 3 09-04-2003 01:07 PM

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

All times are GMT -5. The time now is 01:39 PM.

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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration