Operating System - HP-UX
1823967 Members
4591 Online
109667 Solutions
New Discussion юеВ

Version of Perl on HP-UX Server

 
Gillian Gentile
New Member

Version of Perl on HP-UX Server

How can I find out what version of Perl that is on an HP-UX Server on version 10.2? Our SA did not know, and I am at a loss. I tried to use the perl -V command, but got error "Unrecognized switch: -V".
9 REPLIES 9
linuxfan
Honored Contributor

Re: Version of Perl on HP-UX Server

Hi,

Looks like you are using the /usr/contrib/bin/perl which is version 4.0 and doesn't support the "-V" option.

You will have to use "-v" to get the version.

I would highly recommend you to upgrade to a newer version.

You can download it from
http://hpux.cs.utah.edu/hppd/hpux/Languages/perl-5.6.1
or
http://hpux.ee.ualberta.ca/hppd/hpux/Languages/perl-5.6.1

-HTH
Ramesh
They think they know but don't. At least I know I don't know - Socrates
Santosh Nair_1
Honored Contributor

Re: Version of Perl on HP-UX Server

If you have Q4 (part of installed along with the latest Q4 patch, PHCO_20262 then you probably also have perl in /usr/contrib/Q4/bin/perl and this is version 5.005_02.

-Santosh
Life is what's happening while you're busy making other plans
Insu Kim
Honored Contributor

Re: Version of Perl on HP-UX Server

For instance,

# whereis perl
perl : /usr/bin/perl /usr/contrib/bin/perl

# /usr/bin/perl -v
# /usr/contrib/bin/perl -v

Hope this helps,
Never say "no" first.
Gillian Gentile
New Member

Re: Version of Perl on HP-UX Server

Thank you so much for your responses. I was able to find the version using perl -v. We are on version 4.0. Thanks for the download site links as well!
Patrick Wallek
Honored Contributor

Re: Version of Perl on HP-UX Server

One thing to remember: If you install the version of PERL you get from the Porting Centre, it gets installed in /opt/perl5 so you will need to make sure you specify the correct path to PERL if you use it in a script.

James Lakin
Occasional Advisor

Re: Version of Perl on HP-UX Server

Hello,
On the question of PERL upgrades. Is swinstall a requirement to get it on the box, or can I simply lay down the binaries and run?
If it is swinstall, does it require kernal changes/reboot? I'd like to lay it down without a service interruption. Thanks
Santosh Nair_1
Honored Contributor

Re: Version of Perl on HP-UX Server

You should be able to lay down the binaries and it should work, but remember to copy over the library routines also, which is usually named something like lib/perl5.

-Santosh
Life is what's happening while you're busy making other plans
A. Clay Stephenson
Acclaimed Contributor

Re: Version of Perl on HP-UX Server

Just download it and run the interactive version of swinstall. No reboot is necessary.
About the only thing you have to do is a symbolic link:
ln -s /opt/perl5/bin/perl /usr/bin/perl
and then make sure that /usr/bin precedes /local/contrib/bin (where the old perl is).

Clay
If it ain't broke, I can fix that.
Patrick Wallek
Honored Contributor

Re: Version of Perl on HP-UX Server

If you download the precompiled binaries from the porting center, then you can just install them via swinstall. This does not do any kernel changes nor does it required a reboot. It will be installed to /opt/perl5 so the path to the perl executable is /opt/perl5/bin/perl.