Solved

perl link

Posted on 2011-03-08
4
656 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
  • 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 77

Accepted Solution

by:
arnold earned 500 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

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

Suggested Solutions

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…
Why Shell Scripting? Shell scripting is a powerful method of accessing UNIX systems and it is very flexible. Shell scripts are required when we want to execute a sequence of commands in Unix flavored operating systems. “Shell” is the command line i…
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…
In a previous video, we went over how to export a DynamoDB table into Amazon S3.  In this video, we show how to load the export from S3 into a DynamoDB table.

860 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