Re: how to create a link of another directory in home directory ...2
On Sun, Apr 28, 2002 at 08:39:02PM -0400, Shawn McMahon wrote: > begin Eric G. Miller quotation: > > > > And, in the context of using "ln", your point is? > > That question is unanswerable, because it contains a faulty assumption. And the faulty assumption is? The OP was asking about linking to an existing directory and wanted to know the difference between symbolic and hard links. My original statement about avoiding hard links was made in that context. Being pedantic about the fact that all filesystem entries have a least one hard link is ignoring the context of the discussion and why it might be preferable to use symlinks vs. hard links to existing filesystem entries. If you want to address the merits of such arguments, fine. But I don't see any benefit in pursuing this tangent any further. -- Eric G. Miller -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: how to create a link of another directory in home directory ...2
begin Eric G. Miller quotation: > > And, in the context of using "ln", your point is? That question is unanswerable, because it contains a faulty assumption. -- Shawn McMahon| McMahon's Laws of Linux support: http://www.eiv.com | 1) There's more than one way to do it AIM: spmcmahonfedex, smcmahoneiv | 2) Somebody thinks your way is wrong pgph9mK6RZNt4.pgp Description: PGP signature
Re: how to create a link of another directory in home directory ...2
On Sun, Apr 28, 2002 at 10:42:06AM -0400, Shawn McMahon wrote: > begin Eric G. Miller quotation: > > > > Some might argue that hard links are a bad thing and should be > > avoided. > > Others might point out that there is at least one hard link to EVERY > file that appears in a directory listing. And, in the context of using "ln", your point is? -- Eric G. Miller -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: how to create a link of another directory in home directory ...2
begin Eric G. Miller quotation: > > Some might argue that hard links are a bad thing and should be > avoided. Others might point out that there is at least one hard link to EVERY file that appears in a directory listing. -- Shawn McMahon| McMahon's Laws of Linux support: http://www.eiv.com | 1) There's more than one way to do it AIM: spmcmahonfedex, smcmahoneiv | 2) Somebody thinks your way is wrong pgp1NVfKRtx2Z.pgp Description: PGP signature
Re: how to create a link of another directory in home directory ...2
On Sat, Apr 27, 2002 at 07:32:15PM -0700, faisal gillani wrote: > > what is the diffrence between a symbolic & a hard link ? A symbolic link is basically a pointer to the real file. If you remove the real file, the symbolic link is broken. A hard link is essentially the same as a "real" file in the sense that it creates another name for the data and the reference count for the data goes up. If you delete the original file name, the data will still exist and the "hard link" will still resolve to the data. Maybe a diagram: ---> ---> ---> -- |--> -- There are some different rules about the two. Hard links can't be made to directories (generally) and can't cross filesystem boundaries. Some might argue that hard links are a bad thing and should be avoided. -- Eric G. Miller -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: how to create a link of another directory in home directory ...2
faisal gillani <[EMAIL PROTECTED]> writes: > what is the diffrence between a symbolic & a hard link ? A symbolic link is a directory entry that points to the name of another file. For example: dmaze% echo hello > foo dmaze% ln -s foo bar dmaze% ls -l bar lrwxrwxrwx1 dmazedmaze 3 Apr 27 23:55 bar -> foo dmaze% cat bar hello dmaze% echo goodbye > foo dmaze% cat bar goodbye On the other hand, a hard link means giving two names to the same file. This means you can do things like this: dmaze% echo hello > foo dmaze% ln foo bar dmaze% ls -i foo bar 32412 bar32412 foo dmaze% rm foo dmaze% cat bar hello dmaze% echo goodbye > foo dmaze% cat bar hello (With a symbolic link, the fourth and fifth commands would produce an error; bar would be a 'dangling' symlink, pointing to a nonexistent file named foo.) In general, symbolic links are used over hard links, since it is much easier to tell what is intended to be a link and what isn't. It also means that, if you want to replace the file that the links point to, you can just do that without worrying about rebinding the links to the new file. It is also the case that, except under certain restricted conditions, you cannot create hard links to directories; you must use symbolic links. -- David Maze [EMAIL PROTECTED] http://people.debian.org/~dmaze/ "Theoretical politics is interesting. Politicking should be illegal." -- Abra Mitchell -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: how to create a link of another directory in home directory ...2
On Sat, Apr 27, 2002 at 07:32:15PM -0700, faisal gillani wrote: | | what is the diffrence between a symbolic & a hard link ? One (symlink) is a pointer to the filename. It can point to directories and can cross filesystem boundaries. The other (hard link) is a second name that refers to the same inode. It can't refer to a directory or cross fs boundaries. If you have 2 hard links to an inode, removing one doesn't remove the file. If you have a symlink to another "file" (which is a hard link to an inode), removing the symlink has no effect on the file and removing the file leaves a dangling symlink. Files are stored in inodes with the first being a list of all the successive ones (basically). Directories are inodes that list the names and starting inode of all the files in the directory. This is getting into the details of how a unix filesystem is implemented. Find a good book on fs or OS design and study it :-). -D -- If any of you lacks wisdom, he should ask God, who gives generously to all without finding fault, and it will be given to him. But when he asks he must believe and not doubt, because he who doubts is like a wave of the sea, blown and tossed by the wind. James 1:5-6 GnuPG key : http://dman.ddts.net/~dman/public_key.gpg pgps5a3OTN4Cm.pgp Description: PGP signature
Re: how to create a link of another directory in home directory ...2
what is the diffrence between a symbolic & a hard link ? thanks for the reply Dayalan Manohar <[EMAIL PROTECTED]> wrote: hi,try man ln to read the help.the command isln -s /other/directory /home/faisal/linknameln -s is to create a symbolic link.without s option hard link is created.hth,dayalanfaisal gillani wrote:> i want to create a link of another directory in my home directory .. > as i dont want to type huge command to reach there ..>> i do know how to create from gui mode .. but i wana create it in the > command mode ..>> >> thanks *º¤ ., ¸¸,.¤º*¨¨¨* ¤ Allah-hu-Akber* º¤., ¸¸,.¤º *¨¨*¤>>> > Do You Yahoo!?> Yahoo! Games - > play chess, backgammon, pool and more *º¤., ¸¸,.¤º*¨¨¨*¤ Allah-hu-Akber*º¤., ¸¸,.¤º*¨¨*¤Do You Yahoo!? Yahoo! Health - your guide to health and wellness
Re: how to create a link of another directory in home directory ...
ln -s the_existing_path your_alias_for_it -- Sincerely, David Smead http://www.amplepower.com. On Fri, 26 Apr 2002, faisal gillani wrote: > > i want to create a link of another directory in my home directory .. as i > dont want to type huge command to reach there .. > > i do know how to create from gui mode .. but i wana create it in the command > mode .. > > > > thanks > > > *º¤., ¸¸,.¤º*¨¨¨*¤ Allah-hu-Akber*º¤., ¸¸,.¤º*¨¨*¤ > > > - > Do You Yahoo!? > Yahoo! Games - play chess, backgammon, pool and more -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
RE: how to create a link of another directory in home directory ...
Is this a kind of promotional email for something so obvious? Looking at the way this email got posted to debian group in BCC and Sun group, I get my own doubts. Who knows how many more lists were copied in Bcc? > i want to create a link of another directory in my home directory .. > as i dont want to type huge command to reach there .. > > *º¤., ¸¸,.¤º*¨¨¨*¤ Allah-hu-Akber*º¤., ¸¸,.¤º*¨¨*¤ -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: how to create a link of another directory in home directory ...
ln -sf /home/user /etc/imduser much better do `man ln` it always work :) louie > i want to create a link of another directory in my home directory .. > as i dont want to type huge command to reach there .. > > i do know how to create from gui mode .. but i wana create it in the > command mode .. > > thanks > > *º¤., ¸¸,.¤º*¨¨¨*¤ Allah-hu-Akber*º¤., ¸¸,.¤º*¨¨*¤ > > - > Do You Yahoo!? > Yahoo! Games - play chess, backgammon, pool and more -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
Re: how to create a link of another directory in home directory ...
faisal gillani <[EMAIL PROTECTED]> writes: > 1. (*) text/plain ( ) text/html (Unnecessary, and irritating on public mailing lists; please configure your mailer to send plain text only.) > i want to create a link of another directory in my home directory > .. as i dont want to type huge command to reach there .. > > i do know how to create from gui mode .. but i wana create it in the > command mode .. See ln(1). -- David Maze [EMAIL PROTECTED] http://people.debian.org/~dmaze/ "Theoretical politics is interesting. Politicking should be illegal." -- Abra Mitchell -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
how to create a link of another directory in home directory ...
i want to create a link of another directory in my home directory .. as i dont want to type huge command to reach there .. i do know how to create from gui mode .. but i wana create it in the command mode .. thanks*º¤., ¸¸,.¤º*¨¨¨*¤ Allah-hu-Akber*º¤., ¸¸,.¤º*¨¨*¤Do You Yahoo!? Yahoo! Games - play chess, backgammon, pool and more