- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- changing directory problem with symbolic link in c...
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Discussions
Forums
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-05-2008 10:06 AM
тАО03-05-2008 10:06 AM
My S/W developers are using C Shell in HP-UX 11.11.
One of them asked me about changing directory.
For example,
1) The current directory and result of "ls -al" are :
$pwd
/apl1/apl_sw/wsm.ss
$ls -al
lrwxrwxrwx 1 ypark bksuser 42 Mar 3 10:25 test -> /export/bks/wsm/test
2) He changed directory into test :
$cd test
$pwd
/export/bks/wsm/test
3) He tried to return the previous directory, but couldn't :
$cd ..
$pwd
/export/bks/wsm
I guess that it's csh's problem.
Is there anyone who solve it?
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-05-2008 10:14 AM
тАО03-05-2008 10:14 AM
Re: changing directory problem with symbolic link in csh
Make sure the shell patches for Posix, csh and ksh are installed.
Patch database http://itrc.hp.com
SEP
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-05-2008 11:06 AM
тАО03-05-2008 11:06 AM
Re: changing directory problem with symbolic link in csh
thought that "cd .." meant "go up one level
in the directory hierarchy", not "go back to
wherever I was before". "/export/bks/wsm" is
up one level from "/export/bks/wsm/test", so
it's working as I'd expect it to work.
> I guess that it's csh's problem.
That's one way to look at it.
If you want a way to return to a previous
directory, you might investigate pushd and
popd. "man csh".
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-05-2008 01:12 PM
тАО03-05-2008 01:12 PM
Solution"Relative path changes (such as cd ..), when in a symbolically linked directory, cause csh's knowledge of the working directory to be along the symbolic path instead of the physical path."
I read that as saying it should work as Robin99's developers appear to desire. However, in checking, I found the following:
AIX csh goes up the actual path, not the symbolic link. ksh goes back up the sym-link
Linux csh goes back up the symlink
HP-UX 11.0 - csh goes back up the actual path, not the symlink, ksh goes back up the symlink
of course, I'd question why developers "need" the csh....
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-05-2008 01:25 PM
тАО03-05-2008 01:25 PM
Re: changing directory problem with symbolic link in csh
If your developer's are bent on using 'csh' I would install 'tcsh' instead:
http://hpux.cs.utah.edu/hppd/hpux/Shells/tcsh-6.14.06/
I would also suggest reading:
http://www.faqs.org/faqs/unix-faq/shell/csh-whynot/
Regards!
...JRF...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-06-2008 10:38 PM
тАО03-06-2008 10:38 PM
Re: changing directory problem with symbolic link in csh
>I'd question why developers "need" the csh.
Right a real shell works fine, not the scummy csh.
Also, the pwd command will tell you the logical name by default. If you want the physical path, you need "pwd -P".
Also with a real shell, you can use "cd -".
- Tags:
- scummy C shell
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-10-2008 09:06 AM
тАО03-10-2008 09:06 AM
Re: changing directory problem with symbolic link in csh
Frankly speeking, I don't find how to change working directory instead of physical directory.
But my developer decided to use ksh.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-12-2008 01:25 PM
тАО03-12-2008 01:25 PM
Re: changing directory problem with symbolic link in csh
csh thinks they are the same. sh/ksh has the concept of logical or physical path.
>But my developer decided to use ksh.
That's always a good idea. Either sh or ksh.