1828106 Members
3005 Online
109974 Solutions
New Discussion

ls -L command

 

ls -L command

The ls -L command is not working the way that I would expect it to. For example:

# echo "Testing" > /home/mis/tstanley/FileTest
# cd /
# ln -s /home/mis/tstanley/FileTest xxxx
# ls -L xxxx
xxxx
#

shouldn't the output of the command be the name of the file that I created?
7 REPLIES 7
Patrick Wallek
Honored Contributor

Re: ls -L command

Hmmm...According to the 'ls' man page, you are right.

It is not working for me either. You might check the patch database and see if there is patch for this problem. If not, I'd report it to HP as a bug.
Pete Randall
Outstanding Contributor

Re: ls -L command

The difference is that if you did "ls -l xxxx", you would get "xxxx -> /home/mis/tstanley/FileTest".


Pete

Pete
Simon Hargrave
Honored Contributor

Re: ls -L command

Yes the output you (and I) get in testing appears to differ from what the manpage suggests.

I would infer that the manpage is wrong and it should read that it shows you just the name of the link and not the dereference.
mirco_1
Valued Contributor

Re: ls -L command

hy,

i think to do install patch PHCO_27415

DM.
Patrick Wallek
Honored Contributor

Re: ls -L command

OK, I just got done with an online chat with one of the HP Response Center personnel. He seems to agree that there is a problem.

A quote from our chat -- "Wow ,.. this has opened a can of worms ,.. We just see the short form and no diff between a normal ls with or without -L ,..."

I was advised to open a case so they can route the problem to the correct HP-UX team within HP.

Re: ls -L command

Since my system is HP-UX 11.0, I looked up the equivalent patch to PHCO_27415 (which is PHCO_29217), but the patch details did not mention anything about a fix for this.
Mel Burslan
Honored Contributor

Re: ls -L command

Thomas,

If this is a consolation, I am getting the same result on my 11.i systems, at least the few I was able to test it on. So, WTEC have some work to do on ls comand I presume.
________________________________
UNIX because I majored in cryptology...