?
Solved

perl link

Posted on 2011-03-08
4
Medium Priority
?
666 Views
Last Modified: 2013-11-17
My perl should be usr/bin/perl and not /usr/local/bin/perl, what should I do to modify this.

root@csc06r11 # which perl
/usr/local/bin/perl

My env is

MANPATH=/usr/man:/usr/autotree/autosys/doc
LANG=en_US
WSM_WS_CMD="startsrc -s http4websm"
VVTERMCAP=//vvtermcap
LOGIN=root
SQRTOOLS=/usr/sqr6/syb/bin
PAGER=pg
PATH=/usr/autotree/autosys/bin:/usr/bin:/usr/local/lib:/usr/local/bin:/sybase/ASE-12_0/bin:/sybase/OCS-12_0/bin:/usr/bin:/etc:/usr/sbin:/usr/ucb:/usr/bin/X11:/sbin:/usr/java130/jre/bin:/usr/java130/bin
SQRDIR=/usr/sqr6/syb/bin
SYBPLATFORM=rs6000
ORACLE_BASE=/optware/oracle
AUTOSERV=LMQ
LC__FASTMSG=true
CGI_DIRECTORY=/var/docsearch/cgi-bin
LOGNAME=root
MAIL=/usr/spool/mail/root
LOCPATH=/usr/lib/nls/loc
PS1=[$PWD]
WSM_DOC_DIR="/usr/websm/http/com.ibm.websm.http.server_1.0.0"
DOCUMENT_SERVER_MACHINE_NAME=localhost
USER=root
DSQUERY=prodlmdb
AUTHSTATE=files
DEFAULT_BROWSER=netscape
SHELL=/usr/bin/ksh
ODMDIR=/etc/objrepos
DOCUMENT_SERVER_PORT=49213
HOME=/
AUTOUSER=/usr/autotree/autouser
TERM=xterm
MAILMSG=[YOU HAVE NEW MAIL]
ORACLE_HOME=/optware/oracle/product/9.2.0/db_1
PWD=/usr/opt
DOCUMENT_DIRECTORY=/usr/docsearch/html
TZ=EST5EDT
WSM_CGI_DIR=
A__z=! LOGNAME
NLSPATH=/usr/lib/nls/msg/%L/%N:/usr/lib/nls/msg/%L/%N.cat
LIBPATH=/usr/lib:/usr/local/lib:.:
LD_LIBRARY_PATH=/usr/lib:/usr/local/lib:/optware/oracle/product/11.1.0/client_1/


0
Comment
Question by:mnis2008
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
4 Comments
 
LVL 9

Expert Comment

by:svs
ID: 35071374
If you have root access, run  
ln -s /usr/local/bin/perl /usr/bin/perl

Open in new window

0
 

Author Comment

by:mnis2008
ID: 35071406
How do I actually set it in my enviroment such that it searches for perl in /usr/bin and not in /usr/local/bin
0
 

Author Comment

by:mnis2008
ID: 35071413
I need to link /usr/bin/perl to /usr/opt/perl5/bin/perl5.8.2_64bit
0
 
LVL 79

Accepted Solution

by:
arnold earned 2000 total points
ID: 35072021
You can redefine the $PATH $path variable depending on your shell.
This is the search path
echo $PATH
echo $path
The search is from left to right.
changing the order of entries will change where an item that exists in two places is located
PATH=/usr/bin:/usr/local/bin:$PATH
will mean that when you run perl, /usr/bin/perl will be found versus /usr/local/bin/perl.
alternatively, if for what you want to do, you must use /usr/bin/perl, use /usr/bin/perl Makefile.PL

you could add /usr/opt/perl5/bin/ as the first entry in the $PATH
export PATH=/usr/opt/perl5/bin:$PATH
presumably there is a perl within that location that links to perl5.8.2_64bit.
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

When you do backups in the Solaris Operating System, the file system must be inactive. Otherwise, the output may be inconsistent. A file system is inactive when it's unmounted or it's write-locked by the operating system. Although the fssnap utility…
This tech tip describes how to install the Solaris Operating System from a tape backup that was created using the Solaris flash archive utility. I have used this procedure on the Solaris 8 and 9 OS, and it shoudl also work well on the Solaris 10 rel…
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
Learn how to navigate the file tree with the shell. Use pwd to print the current working directory: Use ls to list a directory's contents: Use cd to change to a new directory: Use wildcards instead of typing out long directory names: Use ../ to move…
Suggested Courses

765 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question