Re: Copying one hard drive to another - links
Alvin Oga <aoga@Mail.Linux-Consulting.com> writes:
> i dont use hardlinks.. ( creates portability problems )
If you have standard Debian software installed, like gzip, then
you use hardlinks.
root@jdc:/# ls -l /bin/*zip*
-rwxr-xr-x 4 root root 46160 Dec 2 1999 /bin/gunzip*
-rwxr-xr-x 4 root root 46160 Dec 2 1999 /bin/gzip*
These files have 4 links to them.
> Maggie:/tmp/test# ln -s ./pinerc023592 x.s
> Maggie:/tmp/test# ln ./pinerc023592 x.h
> Maggie:/tmp/test# ls -la
> total 2
> drwxr-xr-x 2 root root 1024 May 14 20:11 ./
> drwxrwxrwt 4 root root 1024 May 14 20:08 ../
> lrwxrwxrwx 2 root root 24 May 14 20:08 pinerc023592 ->
> /home/alvin/pinerc023592
> lrwxrwxrwx 2 root root 24 May 14 20:08 x.h ->
> /home/alvin/pinerc023592
> lrwxrwxrwx 1 root root 14 May 14 20:11 x.s ->
> ./pinerc023592
What unix are you using? That x.h sure looks like a soft symlink
to me. On my Debian system:
jdc@jdc:/tmp/test% touch .pine
jdc@jdc:/tmp/test% ln -s ./.pine x.s
jdc@jdc:/tmp/test% ln ./.pine x.h
jdc@jdc:/tmp/test% ls -la
total 8
drwx------ 2 jdc jdc 4096 May 15 10:04 ./
drwxrwxrwt 23 root root 4096 May 15 10:03 ../
-rw------- 2 jdc jdc 0 May 15 10:03 .pine
-rw------- 2 jdc jdc 0 May 15 10:03 x.h
lrwxrwxrwx 1 jdc jdc 7 May 15 10:04 x.s -> ./.pine
A hardlink isn't "symbolic" in that the file name of the target
isn't stored. Your test shows a softlink.
Dan
Reply to: