<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="es">
	<id>https://wiki.cabal.mx/index.php?action=history&amp;feed=atom&amp;title=Comandos_de_la_terminal%2Fln</id>
	<title>Comandos de la terminal/ln - Historial de revisiones</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.cabal.mx/index.php?action=history&amp;feed=atom&amp;title=Comandos_de_la_terminal%2Fln"/>
	<link rel="alternate" type="text/html" href="https://wiki.cabal.mx/index.php?title=Comandos_de_la_terminal/ln&amp;action=history"/>
	<updated>2026-04-04T22:48:21Z</updated>
	<subtitle>Historial de revisiones para esta página en el wiki</subtitle>
	<generator>MediaWiki 1.32.1</generator>
	<entry>
		<id>https://wiki.cabal.mx/index.php?title=Comandos_de_la_terminal/ln&amp;diff=5348&amp;oldid=prev</id>
		<title>Rrc en 20:01 5 abr 2014</title>
		<link rel="alternate" type="text/html" href="https://wiki.cabal.mx/index.php?title=Comandos_de_la_terminal/ln&amp;diff=5348&amp;oldid=prev"/>
		<updated>2014-04-05T20:01:07Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;Página nueva&lt;/b&gt;&lt;/p&gt;&lt;div&gt;__NOTOC__&lt;br /&gt;
* [[:#ln | ln]]&lt;br /&gt;
&lt;br /&gt;
== ln ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;bash&amp;quot;&amp;gt;&lt;br /&gt;
[root@Llawyr ComandosDeLaTerminal]# ln --help&lt;br /&gt;
Usage: ln [OPTION]... [-T] TARGET LINK_NAME   (1st form)&lt;br /&gt;
  or:  ln [OPTION]... TARGET                  (2nd form)&lt;br /&gt;
  or:  ln [OPTION]... TARGET... DIRECTORY     (3rd form)&lt;br /&gt;
  or:  ln [OPTION]... -t DIRECTORY TARGET...  (4th form)&lt;br /&gt;
In the 1st form, create a link to TARGET with the name LINK_NAME.&lt;br /&gt;
In the 2nd form, create a link to TARGET in the current directory.&lt;br /&gt;
In the 3rd and 4th forms, create links to each TARGET in DIRECTORY.&lt;br /&gt;
Create hard links by default, symbolic links with --symbolic.&lt;br /&gt;
By default, each destination (name of new link) should not already exist.&lt;br /&gt;
When creating hard links, each TARGET must exist.  Symbolic links&lt;br /&gt;
can hold arbitrary text; if later resolved, a relative link is&lt;br /&gt;
interpreted in relation to its parent directory.&lt;br /&gt;
&lt;br /&gt;
Mandatory arguments to long options are mandatory for short options too.&lt;br /&gt;
      --backup[=CONTROL]      make a backup of each existing destination file&lt;br /&gt;
  -b                          like --backup but does not accept an argument&lt;br /&gt;
  -d, -F, --directory         allow the superuser to attempt to hard link&lt;br /&gt;
                                directories (note: will probably fail due to&lt;br /&gt;
                                system restrictions, even for the superuser)&lt;br /&gt;
  -f, --force                 remove existing destination files&lt;br /&gt;
  -i, --interactive           prompt whether to remove destinations&lt;br /&gt;
  -L, --logical               dereference TARGETs that are symbolic links&lt;br /&gt;
  -n, --no-dereference        treat LINK_NAME as a normal file if&lt;br /&gt;
                                it is a symbolic link to a directory&lt;br /&gt;
  -P, --physical              make hard links directly to symbolic links&lt;br /&gt;
  -r, --relative              create symbolic links relative to link location&lt;br /&gt;
  -s, --symbolic              make symbolic links instead of hard links&lt;br /&gt;
  -S, --suffix=SUFFIX         override the usual backup suffix&lt;br /&gt;
  -t, --target-directory=DIRECTORY  specify the DIRECTORY in which to create&lt;br /&gt;
                                the links&lt;br /&gt;
  -T, --no-target-directory   treat LINK_NAME as a normal file always&lt;br /&gt;
  -v, --verbose               print name of each linked file&lt;br /&gt;
      --help     display this help and exit&lt;br /&gt;
      --version  output version information and exit&lt;br /&gt;
&lt;br /&gt;
The backup suffix is &amp;#039;~&amp;#039;, unless set with --suffix or SIMPLE_BACKUP_SUFFIX.&lt;br /&gt;
The version control method may be selected via the --backup option or through&lt;br /&gt;
the VERSION_CONTROL environment variable.  Here are the values:&lt;br /&gt;
&lt;br /&gt;
  none, off       never make backups (even if --backup is given)&lt;br /&gt;
  numbered, t     make numbered backups&lt;br /&gt;
  existing, nil   numbered if numbered backups exist, simple otherwise&lt;br /&gt;
  simple, never   always make simple backups&lt;br /&gt;
&lt;br /&gt;
Using -s ignores -L and -P.  Otherwise, the last option specified controls&lt;br /&gt;
behavior when a TARGET is a symbolic link, defaulting to -P.&lt;br /&gt;
&lt;br /&gt;
Report ln bugs to bug-coreutils@gnu.org&lt;br /&gt;
GNU coreutils home page: &amp;lt;http://www.gnu.org/software/coreutils/&amp;gt;&lt;br /&gt;
General help using GNU software: &amp;lt;http://www.gnu.org/gethelp/&amp;gt;&lt;br /&gt;
For complete documentation, run: info coreutils &amp;#039;ln invocation&amp;#039;&lt;br /&gt;
&lt;br /&gt;
[root@Llawyr ComandosDeLaTerminal]# ln --version&lt;br /&gt;
ln (GNU coreutils) 8.21&lt;br /&gt;
Copyright (C) 2013 Free Software Foundation, Inc.&lt;br /&gt;
License GPLv3+: GNU GPL version 3 or later &amp;lt;http://gnu.org/licenses/gpl.html&amp;gt;.&lt;br /&gt;
This is free software: you are free to change and redistribute it.&lt;br /&gt;
There is NO WARRANTY, to the extent permitted by law.&lt;br /&gt;
&lt;br /&gt;
Written by Mike Parker and David MacKenzie.&lt;br /&gt;
&lt;br /&gt;
[root@Llawyr ComandosDeLaTerminal]# ln STRERR HLSTERR&lt;br /&gt;
&lt;br /&gt;
[root@Llawyr ComandosDeLaTerminal]# ls -ali STRERR HLSTERR &lt;br /&gt;
8521820 -rw------- 2 rrc rrc 44 Nov 16 13:10 HLSTERR&lt;br /&gt;
8521820 -rw------- 2 rrc rrc 44 Nov 16 13:10 STRERR&lt;br /&gt;
&lt;br /&gt;
[root@Llawyr ComandosDeLaTerminal]# rm STRERR &lt;br /&gt;
rm: remove regular file ‘STRERR’? y&lt;br /&gt;
&lt;br /&gt;
[root@Llawyr ComandosDeLaTerminal]# ls -ali STRERR HLSTERR &lt;br /&gt;
ls: cannot access STRERR: No such file or directory&lt;br /&gt;
8521820 -rw------- 1 rrc rrc 44 Nov 16 13:10 HLSTERR&lt;br /&gt;
&lt;br /&gt;
[root@Llawyr ComandosDeLaTerminal]# ln -s HLSTERR STDERR&lt;br /&gt;
&lt;br /&gt;
[root@Llawyr ComandosDeLaTerminal]# ls -ali STDERR &lt;br /&gt;
8523095 lrwxrwxrwx 1 root root 7 Apr  4 15:31 STDERR -&amp;gt; HLSTERR&lt;br /&gt;
&lt;br /&gt;
[root@Llawyr ComandosDeLaTerminal]# rm HLSTERR &lt;br /&gt;
rm: remove regular file ‘HLSTERR’? y&lt;br /&gt;
&lt;br /&gt;
[root@Llawyr ComandosDeLaTerminal]# ls -ali STDERR  HLSTDERR&lt;br /&gt;
ls: cannot access HLSTDERR: No such file or directory&lt;br /&gt;
8523095 lrwxrwxrwx 1 root root 7 Apr  4 15:31 STDERR -&amp;gt; HLSTERR&lt;br /&gt;
&lt;br /&gt;
[rrc@Llawyr ComandosDeLaTerminal]$ ln -s ../../../var/www/html/linuxcabal.org &lt;br /&gt;
&lt;br /&gt;
[rrc@Llawyr ComandosDeLaTerminal]$ ls -al linuxcabal.org&lt;br /&gt;
lrwxrwxrwx 1 rrc rrc 36 Apr  4 16:31 linuxcabal.org -&amp;gt; ../../../var/www/html/linuxcabal.org/&lt;br /&gt;
&lt;br /&gt;
[rrc@Llawyr ComandosDeLaTerminal]$ ln -s ../../var/www/html/richard &lt;br /&gt;
ln: failed to create symbolic link ‘./richard’: File exists&lt;br /&gt;
&lt;br /&gt;
[rrc@Llawyr ComandosDeLaTerminal]$ ln -sf ../../var/www/html/richard &lt;br /&gt;
&lt;br /&gt;
[rrc@Llawyr ComandosDeLaTerminal]$ ls -al richard&lt;br /&gt;
lrwxrwxrwx 1 rrc rrc 26 Apr  4 16:34 richard -&amp;gt; ../../var/www/html/richard&lt;br /&gt;
&lt;br /&gt;
[root@pridd ComandosDeLaTerminal]# ln -is ../../../var/www/html/richard &lt;br /&gt;
ln: replace ‘./richard’? &lt;br /&gt;
&lt;br /&gt;
[root@pridd ComandosDeLaTerminal]# ls -al richard&lt;br /&gt;
lrwxrwxrwx 1 root root 29 Apr  5 13:51 richard -&amp;gt; ../../../var/www/html/richard/&lt;br /&gt;
&lt;br /&gt;
[root@pridd ComandosDeLaTerminal]# ln -sr /var/www/html &lt;br /&gt;
&lt;br /&gt;
[root@pridd ComandosDeLaTerminal]# ls -al html&lt;br /&gt;
lrwxrwxrwx 1 root root 21 Apr  5 13:53 html -&amp;gt; ../../../var/www/html/&lt;br /&gt;
&lt;br /&gt;
[root@pridd ComandosDeLaTerminal]# ls -al C1/C2/C3&lt;br /&gt;
total 12&lt;br /&gt;
drwxrwxrwx 3 rrc rrc 4096 Mar 22 16:03 ./&lt;br /&gt;
drwxrwxrwx 3 rrc rrc 4096 Mar 22 16:03 ../&lt;br /&gt;
drwxrwxrwx 3 rrc rrc 4096 Mar 22 16:04 C4/&lt;br /&gt;
&lt;br /&gt;
[root@pridd ComandosDeLaTerminal]# ln -st C1/C2/C3 /var/www/html/richard&lt;br /&gt;
[root@pridd ComandosDeLaTerminal]# ls -al C1/C2/C3&lt;br /&gt;
total 12&lt;br /&gt;
drwxrwxrwx 3 rrc  rrc  4096 Apr  5 13:57 ./&lt;br /&gt;
drwxrwxrwx 3 rrc  rrc  4096 Mar 22 16:03 ../&lt;br /&gt;
drwxrwxrwx 3 rrc  rrc  4096 Mar 22 16:04 C4/&lt;br /&gt;
lrwxrwxrwx 1 root root   21 Apr  5 13:57 richard -&amp;gt; /var/www/html/richard/&lt;br /&gt;
&lt;br /&gt;
[root@pridd ComandosDeLaTerminal]# ln -irst C1/C2/C3 /var/www/html/richard&lt;br /&gt;
ln: replace ‘C1/C2/C3/richard’? y&lt;br /&gt;
&lt;br /&gt;
[root@pridd ComandosDeLaTerminal]# ls -al C1/C2/C3&lt;br /&gt;
total 12&lt;br /&gt;
drwxrwxrwx 3 rrc  rrc  4096 Apr  5 13:57 ./&lt;br /&gt;
drwxrwxrwx 3 rrc  rrc  4096 Mar 22 16:03 ../&lt;br /&gt;
drwxrwxrwx 3 rrc  rrc  4096 Mar 22 16:04 C4/&lt;br /&gt;
lrwxrwxrwx 1 root root   38 Apr  5 13:57 richard -&amp;gt; ../../../../../../var/www/html/richard/&lt;br /&gt;
&lt;br /&gt;
[root@pridd ComandosDeLaTerminal]# ln -sriv /var/www/html/richard&lt;br /&gt;
ln: replace ‘./richard’? y&lt;br /&gt;
‘./richard’ -&amp;gt; ‘../../../var/www/html/richard’&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Category:Comandos de la terminal]]&lt;/div&gt;</summary>
		<author><name>Rrc</name></author>
		
	</entry>
</feed>