[29771] in Perl-Users-Digest
Perl-Users Digest, Issue: 1014 Volume: 11
daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Thu Nov 8 06:09:36 2007
Date: Thu, 8 Nov 2007 03:09:02 -0800 (PST)
From: Perl-Users Digest <Perl-Users-Request@ruby.OCE.ORST.EDU>
To: Perl-Users@ruby.OCE.ORST.EDU (Perl-Users Digest)
Perl-Users Digest Thu, 8 Nov 2007 Volume: 11 Number: 1014
Today's topics:
Re: CPU limits <ivan@0x4849.net>
Re: Forking problem <ced@blv-sam-01.ca.boeing.com>
Re: Forking problem <ced@blv-sam-01.ca.boeing.com>
new CPAN modules on Thu Nov 8 2007 (Randal Schwartz)
Re: Newbie doesn't quite understand pointers with hashe <RedGrittyBrick@SpamWeary.foo>
Re: problems building perl modules, path question <mmccaws@comcast.net>
Re: problems building perl modules, path question <mmccaws@comcast.net>
Digest Administrivia (Last modified: 6 Apr 01) (Perl-Users-Digest Admin)
----------------------------------------------------------------------
Date: Wed, 07 Nov 2007 23:09:11 -0800
From: Ivan Novick <ivan@0x4849.net>
Subject: Re: CPU limits
Message-Id: <1194505751.087906.225590@v23g2000prn.googlegroups.com>
On Nov 7, 11:10 am, all mail refused <elvis-85...@notatla.org.uk>
wrote:
> On 2007-11-07, alexxx.ma...@gmail.com <alexxx.ma...@gmail.com> wrote:
> You should be able to use BSD::Resource on linux to get at
> the ulimit and setrlimit() sort of stuff. This can limit
> total CPU usage of a program - killing it when exceeded.
>
> If you want to ration CPU usage to some fraction of the total,
> or to a certain one of several CPUs etc that's a different
> question that I don't know the answer to.
You can use a VM and assign only one of the CPU's to the VM :)
Regards,
Ivan Novick
http://www.0x4849.net
------------------------------
Date: 7 Nov 2007 21:30:00 -0800
From: "comp.llang.perl.moderated" <ced@blv-sam-01.ca.boeing.com>
Subject: Re: Forking problem
Message-Id: <1194479959.686081.151620@y27g2000pre.googlegroups.com>
On Nov 4, 3:35 pm, David Knell <david.kn...@gmail.com> wrote:
> Hi -
>
> I've the following bit of code in a scripts:
> $SIG{CHLD} = 'IGNORE';
> while (1) {
> if ($fs->accept("127.0.0.1", $socket)) {
> $pid = fork();
> last if ((defined($pid)) && ($pid == 0));
> }}
>
> ..rest of code..
>
> - roughly speaking, $fs is a thing with a listening socket; the loop
> should wait
> for connections, fork, the inbound connection is handled by ..rest of
> code..
> and the loop goes round indefinitely.
>
> What actually happens is that, every now and again (like every few
> days) the
> main loop exist. No obvious errors appear on the console, and the
> child
> processes continue to run correctly until they terminate, which
> implies that
> the parent's not being killed.
>
> As far as I can see, this shouldn't happen - if the fork fails, pid
> should be
> undefined; if it succeeds, $pid should be non-zero for the parent
> process.
> Either way, the parent process should go round the loop again.
>
> I'm using perl 5.8.8, running on CentOS 5.0.
>
If the program aborts with no forensic trace,
you might try wrapping the program in a shell script which'll mail
back the program's exit status. This could potentially catch something
like an uncaught signal for example.
Hope this helps,
--
Charles DeRykus
------------------------------
Date: 7 Nov 2007 22:07:47 -0800
From: "comp.llang.perl.moderated" <ced@blv-sam-01.ca.boeing.com>
Subject: Re: Forking problem
Message-Id: <1194476625.230781.176910@v23g2000prn.googlegroups.com>
On Nov 4, 3:35 pm, David Knell <david.kn...@gmail.com> wrote:
> Hi -
>
> I've the following bit of code in a scripts:
> $SIG{CHLD} = 'IGNORE';
> while (1) {
> if ($fs->accept("127.0.0.1", $socket)) {
> $pid = fork();
> last if ((defined($pid)) && ($pid == 0));
> }}
>
> ..rest of code..
>
> - roughly speaking, $fs is a thing with a listening socket; the loop
> should wait
> for connections, fork, the inbound connection is handled by ..rest of
> code..
> and the loop goes round indefinitely.
>
> What actually happens is that, every now and again (like every few
> days) the
> main loop exist. No obvious errors appear on the console, and the
> child
> processes continue to run correctly until they terminate, which
> implies that
> the parent's not being killed.
>
> As far as I can see, this shouldn't happen - if the fork fails, pid
> should be
> undefined; if it succeeds, $pid should be non-zero for the parent
> process.
> Either way, the parent process should go round the loop again.
>
> I'm using perl 5.8.8, running on CentOS 5.0.
>
If the program aborts with no forensic trace,
you might try wrapping the program in a shell script which'll mail
back the program's exit status. This could potentially catch something
like an uncaught signal for example.
Hope this helps,
--
Charles DeRykus
------------------------------
Date: Thu, 8 Nov 2007 05:42:16 GMT
From: merlyn@stonehenge.com (Randal Schwartz)
Subject: new CPAN modules on Thu Nov 8 2007
Message-Id: <Jr6AIG.1BJs@zorch.sf-bay.org>
The following modules have recently been added to or updated in the
Comprehensive Perl Archive Network (CPAN). You can install them using the
instructions in the 'perlmodinstall' page included with your Perl
distribution.
Acme-6502-0.70
http://search.cpan.org/~andya/Acme-6502-0.70/
Pure Perl 65C02 simulator.
----
Archive-Zip-1.23
http://search.cpan.org/~adamk/Archive-Zip-1.23/
Provide an interface to ZIP archive files.
----
Authen-SASL-Authd-0.04
http://search.cpan.org/~sasha/Authen-SASL-Authd-0.04/
Client authentication via Cyrus saslauthd or Dovecot authentication daemon.
----
CPAN-FindDependencies-1.1
http://search.cpan.org/~dcantrell/CPAN-FindDependencies-1.1/
find dependencies for modules on the CPAN
----
CPANPLUS-Dist-Mdv-0.2.2
http://search.cpan.org/~jquelin/CPANPLUS-Dist-Mdv-0.2.2/
a cpanplus backend to build mandriva rpms
----
Captcha-reCAPTCHA-0.91
http://search.cpan.org/~andya/Captcha-reCAPTCHA-0.91/
A Perl implementation of the reCAPTCHA API
----
Catalyst-Model-Xapian-0.03
http://search.cpan.org/~mramberg/Catalyst-Model-Xapian-0.03/
Catalyst model for Search::Xapian.
----
Catalyst-Plugin-Log-Dispatch-0.07
http://search.cpan.org/~shot/Catalyst-Plugin-Log-Dispatch-0.07/
Log module of Catalyst that uses Log::Dispatch
----
Class-Factory-Enhanced-0.04
http://search.cpan.org/~marcel/Class-Factory-Enhanced-0.04/
more functionality for Class::Factory
----
Class-Factory-Enhanced-0.05
http://search.cpan.org/~marcel/Class-Factory-Enhanced-0.05/
more functionality for Class::Factory
----
Class-Framework-0.01
http://search.cpan.org/~marcel/Class-Framework-0.01/
large-scale OOP application support
----
Class-Scaffold-0.01
http://search.cpan.org/~marcel/Class-Scaffold-0.01/
large-scale OOP application support
----
Class-Scaffold-0.02
http://search.cpan.org/~marcel/Class-Scaffold-0.02/
large-scale OOP application support
----
Class-Std-Slots-0.2
http://search.cpan.org/~andya/Class-Std-Slots-0.2/
Provide signals and slots for standard classes.
----
Class-Value-0.01
http://search.cpan.org/~marcel/Class-Value-0.01/
foobar
----
Class-Value-0.02
http://search.cpan.org/~marcel/Class-Value-0.02/
the Value Object design pattern
----
Class-Value-Contact-0.01
http://search.cpan.org/~marcel/Class-Value-Contact-0.01/
contact-related value objects
----
Class-Value-Net-0.01
http://search.cpan.org/~marcel/Class-Value-Net-0.01/
network-related value objects
----
Crossfire-1.11
http://search.cpan.org/~mlehmann/Crossfire-1.11/
Crossfire maphandling
----
DBIx-Web-0.71
http://search.cpan.org/~makarow/DBIx-Web-0.71/
Active Web Database Layer
----
Data-Conveyor-0.01
http://search.cpan.org/~marcel/Data-Conveyor-0.01/
stage-based conveyor-belt-like ticket handling system
----
Data-Storage-0.01
http://search.cpan.org/~marcel/Data-Storage-0.01/
generic abstract storage mechanism
----
Data-Storage-0.02
http://search.cpan.org/~marcel/Data-Storage-0.02/
generic abstract storage mechanism
----
Data-Storage-0.03
http://search.cpan.org/~marcel/Data-Storage-0.03/
generic abstract storage mechanism
----
DateTimeX-Easy-0.04
http://search.cpan.org/~rkrimen/DateTimeX-Easy-0.04/
Use ::F::Flexible and ::F::Natural for quick and easy DateTime creation
----
DateTimeX-Easy-0.042
http://search.cpan.org/~rkrimen/DateTimeX-Easy-0.042/
Use ::F::Flexible and ::F::Natural for quick and easy DateTime creation
----
DateTimeX-Easy-0.050
http://search.cpan.org/~rkrimen/DateTimeX-Easy-0.050/
Use DT::F::Flexible and DT::F::Natural for quick and easy DateTime creation
----
DateTimeX-Easy-0.060
http://search.cpan.org/~rkrimen/DateTimeX-Easy-0.060/
Use DT::F::Flexible and DT::F::Natural for quick and easy DateTime creation
----
Devel-CheckOS-1.3
http://search.cpan.org/~dcantrell/Devel-CheckOS-1.3/
check what OS we're running on
----
Devel-CheckOS-1.4
http://search.cpan.org/~dcantrell/Devel-CheckOS-1.4/
check what OS we're running on
----
Devel-CheckOS-1.41
http://search.cpan.org/~dcantrell/Devel-CheckOS-1.41/
check what OS we're running on
----
Devel-TraceLoad-0.9.0
http://search.cpan.org/~andya/Devel-TraceLoad-0.9.0/
Discover which modules a Perl program loads.
----
Devel-TraceLoad-0.9.1
http://search.cpan.org/~andya/Devel-TraceLoad-0.9.1/
Discover which modules a Perl program loads.
----
Devel-TraceLoad-1.0.0
http://search.cpan.org/~andya/Devel-TraceLoad-1.0.0/
Discover which modules a Perl program loads.
----
Dist-Joseki-0.03
http://search.cpan.org/~marcel/Dist-Joseki-0.03/
tools for the prolific module author
----
Dist-Joseki-0.04
http://search.cpan.org/~marcel/Dist-Joseki-0.04/
tools for the prolific module author
----
Email-Folder-POP3-1.013
http://search.cpan.org/~rjbs/Email-Folder-POP3-1.013/
Email::Folder Access to POP3 Folders
----
Jifty-DBI-0.46
http://search.cpan.org/~jesse/Jifty-DBI-0.46/
An object-relational persistence framework
----
LaTeX-Table-0.6.0
http://search.cpan.org/~limaone/LaTeX-Table-0.6.0/
Perl extension for the automatic generation of LaTeX tables.
----
Language-Befunge-Debugger-0.2.0
http://search.cpan.org/~jquelin/Language-Befunge-Debugger-0.2.0/
a graphical debugger for Language::Befunge
----
MIME-tools-5.424
http://search.cpan.org/~doneill/MIME-tools-5.424/
----
Module-ExtractUse-0.20
http://search.cpan.org/~domm/Module-ExtractUse-0.20/
Find out what modules are used
----
Net-DRI-0.81
http://search.cpan.org/~pmevzek/Net-DRI-0.81/
Interface to Domain Name Registries/Registrars/Resellers
----
Net-Kotonoha-0.01
http://search.cpan.org/~mattn/Net-Kotonoha-0.01/
A perl interface to kotonoha.cc
----
Net-Scan-HTTP-Server-Version-0.04
http://search.cpan.org/~mcantoni/Net-Scan-HTTP-Server-Version-0.04/
grab HTTP server version
----
Object-InsideOut-3.29
http://search.cpan.org/~jdhedden/Object-InsideOut-3.29/
Comprehensive inside-out object support module
----
Parse-Marpa-0.001_036
http://search.cpan.org/~jkegl/Parse-Marpa-0.001_036/
Jay Earley's general parsing algorithm with LR(0) precomputation
----
Parse-RecDescent-FAQ-5.08
http://search.cpan.org/~tbone/Parse-RecDescent-FAQ-5.08/
the official, authorized FAQ for Parse::RecDescent.
----
Solstice-1440
http://search.cpan.org/~mcrawfor/Solstice-1440/
Solstice is a Web application development framework for Perl. Based on the MVC programming paradigm, it provides a sensible layout for Web applications that helps you write applications faster and wit
----
Sys-Syslog-0.22
http://search.cpan.org/~saper/Sys-Syslog-0.22/
Perl interface to the UNIX syslog(3) calls
----
TRL-Microarray-0.24
http://search.cpan.org/~cjones/TRL-Microarray-0.24/
A Perl module for creating and manipulating microarray objects
----
Template-Alloy-1.009
http://search.cpan.org/~rhandom/Template-Alloy-1.009/
TT2/3, HT, HTE, Tmpl, and Velocity Engine
----
Template-Parser-CET-0.05
http://search.cpan.org/~rhandom/Template-Parser-CET-0.05/
Template::Alloy based parser for the TT2 engine
----
Text-ASCIIMathML-0.6
http://search.cpan.org/~nodine/Text-ASCIIMathML-0.6/
Perl extension for parsing ASCIIMathML text into MathML
----
Text-CSV-0.99_05
http://search.cpan.org/~makamaka/Text-CSV-0.99_05/
comma-separated values manipulator (using XS or PurePerl)
----
Text-CSV-0.99_06
http://search.cpan.org/~makamaka/Text-CSV-0.99_06/
comma-separated values manipulator (using XS or PurePerl)
----
Text-Quoted-2.03
http://search.cpan.org/~ruz/Text-Quoted-2.03/
Extract the structure of a quoted mail message
----
Tie-Cycle-Sinewave-0.05
http://search.cpan.org/~dland/Tie-Cycle-Sinewave-0.05/
Cycle through a series of values on a sinewave
----
Tk-Pod-0.9937
http://search.cpan.org/~srezic/Tk-Pod-0.9937/
Pod browser toplevel widget
----
URI-Match-0.00001
http://search.cpan.org/~dmaki/URI-Match-0.00001/
Match URLs By Parts
----
V-0.13
http://search.cpan.org/~abeltje/V-0.13/
Print version of the specified module(s).
----
WAP-wmls-1.12
http://search.cpan.org/~perrad/WAP-wmls-1.12/
----
WWW-Dattebayo-0.0.2
http://search.cpan.org/~sepp/WWW-Dattebayo-0.0.2/
Perl module for checking the Dattebayo tracker
----
WWW-UsePerl-Journal-0.20
http://search.cpan.org/~barbie/WWW-UsePerl-Journal-0.20/
A use.perl.org journal tool
----
WebService-Backlog-0.01_03
http://search.cpan.org/~yamamoto/WebService-Backlog-0.01_03/
Perl interface to Backlog.
----
Win32-WebBrowser-1.01
http://search.cpan.org/~darnold/Win32-WebBrowser-1.01/
open the default web browser on Win32
----
XML-Atom-Ext-OpenSearch-0.01
http://search.cpan.org/~bricas/XML-Atom-Ext-OpenSearch-0.01/
XML::Atom extension for OpenSearch data
----
XML-Bare-0.23
http://search.cpan.org/~codechild/XML-Bare-0.23/
Minimal XML parser implemented via a C state engine
----
XML-RPC-0.5
http://search.cpan.org/~daan/XML-RPC-0.5/
Pure Perl implementation for an XML-RPC client and server.
----
XML-Twig-3.31
http://search.cpan.org/~mirod/XML-Twig-3.31/
A perl module for processing huge XML documents in tree mode.
If you're an author of one of these modules, please submit a detailed
announcement to comp.lang.perl.announce, and we'll pass it along.
This message was generated by a Perl program described in my Linux
Magazine column, which can be found on-line (along with more than
200 other freely available past column articles) at
http://www.stonehenge.com/merlyn/LinuxMag/col82.html
print "Just another Perl hacker," # the original
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
<merlyn@stonehenge.com> <URL:http://www.stonehenge.com/merlyn/>
Perl/Unix/security consulting, Technical writing, Comedy, etc. etc.
See PerlTraining.Stonehenge.com for onsite and open-enrollment Perl training!
------------------------------
Date: Thu, 08 Nov 2007 10:27:01 +0000
From: RedGrittyBrick <RedGrittyBrick@SpamWeary.foo>
Subject: Re: Newbie doesn't quite understand pointers with hashes.
Message-Id: <4732e47a$0$21087$da0feed9@news.zen.co.uk>
keersarge wrote:
> Help a newbie moving way too far out in left field, given my current
> knowledge of Perl - but it is fun, anyway.
>
> (Perl 5.8.8 on Debian Etch.)
>
> I am building an object to build some HTML forms. My routine reads in a
> config file that has the following line.
>
> ...
> <input type="text" name="Address" value=$submithash{Address} size="40">
> ...
>
> I want to replace the hash key with the actual value. The Perl script
> reads the file in line by line is parsed out on the spaces. The following
> is not really the program, just a boiled down test script that I am using
> to try to understand what is going on.
>
> ...
> $z = <F1>; #read a line
> @parsearray = split(' ', $z); #break it apart at the spaces
> $parsearray[3] =~ s/value=//; #get rid of all but the hash key
> ...
>
> Now $parsearray[3] holds the string $submithash{Address}.
>
> I can't get from the string representation of the hash key to the actual
> value (although I have discovered a ton of interesting stuff while
> trying).
>
> If I print $parsearray[3], I get the string $submithash{Address}.
>
> print \$parsearray[3] gives me a SCALAR pointer.
>
> print \%parsearray[3] blows up on a use strict error.
>
> Anybody?
As Uri and Jürgen said, you seem to be looking for eval, but that's
often very insecure. A templating system would be better - have a look
in CPAN.
For a one-off I'd do something like
$z =~ s/\$submithash{Address}/$submithash{Address}/;
You should be able to capture and eval:
$z =~ s/\$submithash{Address}/eval($1)/e;
Which is less typing but probably less efficient (if that matters) but
perhaps part way to a more general solution. Maybe "Address" could be
replaced with an expression that matches possible keys? Maybe \w+ if you
don't care too much.
A block of such statements might serve to document what you consider to
be expressions that can *safely* be evaluated. This is safer than simply
using eval on unknown content. I'd worry about code injection attacks.
For anything non-trivial I'd not reinvent the templating wheel :-)
> Thanks
> Keersarge
>
> (Late of Delphi, which is the only thing I regret leaving behind when I
> left Windows).
I greatly enjoyed using Delphi versions 1 and 2 in the distant past. For
me, Perl replaced Turbo Pascal 3 and Java replaced Delphi.
------------------------------
Date: 7 Nov 2007 21:51:44 -0800
From: mmccaws2 <mmccaws@comcast.net>
Subject: Re: problems building perl modules, path question
Message-Id: <1194486282.873761.79060@t8g2000prg.googlegroups.com>
On Nov 7, 1:29 pm, mmccaws2 <mmcc...@comcast.net> wrote:
> On Nov 7, 12:12 pm, elsiddik <elsid...@gmail.com> wrote:
>
> > On Nov 7, 7:05 pm, mmccaws2 <mmcc...@comcast.net> wrote:
>
> > > On Nov 7, 8:59 am, Ben Morrow <b...@morrow.me.uk> wrote:
>
> > > > Quoth mmccaws2 <mmcc...@comcast.net>:
>
> > > > > On Oct 29, 2:53 pm, Ben Morrow <b...@morrow.me.uk> wrote:
> > > > > > Quoth Ron Bergin <r...@i.frys.com>:
>
> > > > > > > Try doing:
>
> > > > > > > $sudobash
> > > > > > > [pass your login credentials]
>
> > > > > > > #perl-MCPAN -e shell
>
> > > > > > > Note the difference between the $ prompt and the # prompt.
>
> > > > > > It would be better to avoid performing the Makefile.PL and make=
steps as
> > > > > > root, if possible. Since CPAN (at least recent versions) has su=
pport for
> > > > > > usingsudofor make install, it would be better to take advantage=
of it.
>
> > > > > So, I think I have made a few mistakes here and I need to correct
> > > > > them. I had installed several modules by getting into perl -MCPA=
N -e
> > > > > shell using sudo. The reason is I get this error message
>
> > > > > $ perl -MCPAN -e shell
> > > > > CPAN: File::HomeDir loaded ok (v0.66)
> > > > > mkdir /home/mccannm/.cpan/CPAN: Permission denied at /opt/perl_32=
/lib/
> > > > > 5.8.8/CPAN/HandleConfig.pm line 539
>
> > > > > when I tried logging in as my self.
> > > > > What happened is this, right after the reinstallation of perl, we=
're
> > > > > on 5.8.8 now, I need to install a module that required root acces=
s=2E I
> > > > > had tried to install that module previously and it said trying to
> > > > > install the module I needed root access. It was the POE module f=
or
> > > > > non-blocking ping. I used sudo perl -MCPAN -e shell to intall it.
> > > > > Since then I can't install any module without using sudo perl -MC=
PAN -
> > > > > e shell.
>
> > > > What has happened is that running CPAN under sudo has created
> > > > /home/mccannm/.cpan as root, so you can't run CPAN as yourself any =
more.
> > > > You need to su(do) to root, and either delete the entire directory =
or
> > > > chown -R it to yourself. Then you need to set CPAN up to use sudo to
> > > > install (as yourself):
>
> > > > $ perl -MCPAN -eshell
> > > > cpan> o conf make_install_make_command "sudo make"
> > > > cpan> o conf mbuild_install_build_command "sudo ./Build"
> > > > cpan> o conf commit
> > > > cpan> quit
> > > > $
>
> > > > You will of course need sudo rights to perform both those commands;=
but
> > > > it seems as though you have localhost=3D(root) ALL rights anyway.
>
> > > > > Also, do I uninstall the ones that I have already installed as ro=
ot or
> > > > > do I change file permissions for directories, I really don't
> > > > > understand this part of administration.
>
> > > > No, all the modules already installed should be fine (you might wan=
t to
> > > > check that everything under /opt/perl_32/lib is owned by root). It's
> > > > just your CPAN config that's been messed up.
>
> > > > Ben
>
> > > well chown -R worked.
>
> > > now the next part, and sorry for being so dense, But I don't sudo perl
> > > -MCPAN -e shell but run those commands after entering perl -MCPAN -e
> > > shell. Correct?
>
> > > also the /opt/perl_32/lib/5.8.8/ has a lot of files with read only
> > > permissions. Would the correct approach be chmod -R 644 /opt/perl_32/
> > > lib/5.8.8/ or is that too broad of a command?
>
> > > $ ls -l /opt/perl_32/lib/5.8.8/
>
> > > gives
>
> > > total 4784
> > > dr-xr-xr-x 3 bin bin 96 Nov 2 12:54 ActivePerl
> > > -r--r--r-- 1 bin bin 3112 Aug 3 05:50
> > > ActivePerl.pm
> > > dr-xr-xr-x 2 bin bin 96 Nov 2 12:54 ActiveState
> > > -r--r--r-- 1 bin bin 2594 Aug 3 05:50
> > > AnyDBM_File.pm
> > > dr-xr-xr-x 3 bin bin 96 Nov 2 12:54 Apache
> > > drwxr-xr-x 2 root sys 96 Nov 6 21:58 App
> > > dr-xr-xr-x 4 bin bin 96 Nov 2 12:54 Archive
> > > dr-xr-xr-x 2 bin bin 96 Nov 2 12:54 Attribute
> > > -r--r--r-- 1 bin bin 11794 Aug 3 05:50
> > > AutoLoader.pm
> > > -r--r--r-- 1 bin bin 15699 Aug 3 05:50 AutoSplit.pm
> > > dr-xr-xr-x 2 bin bin 96 Nov 2 12:54 B
> > > -r--r--r-- 1 bin bin 28524 Aug 3 05:50 Benchmark.pm
> > > dr-xr-xr-x 3 bin bin 96 Nov 2 12:54 Bundle
> > > dr-xr-xr-x 3 bin bin 8192 Nov 2 12:54 CGI
> > > -r--r--r-- 1 bin bin 249942 Aug 3 05:50 CGI.pm
> > > dr-xr-xr-x 4 bin bin 8192 Nov 3 07:18 CPAN
> > > -r--r--r-- 1 root sys 441448 Sep 28 00:06 CPAN.pm
> > > dr-xr-xr-x 2 bin bin 96 Nov 2 12:54 Carp
> > > -r--r--r-- 1 bin bin 7608 Aug 3 05:50 Carp.pm
> > > dr-xr-xr-x 2 bin bin 96 Nov 2 12:54 Class
> > > dr-xr-xr-x 3 bin bin 96 Nov 2 12:54 Convert
> > > -r--r--r-- 1 bin bin 19229 Aug 3 05:50 DB.pm
> > > dr-xr-xr-x 2 bin bin 8192 Nov 2 12:54 DBM_Filter
> > > -r--r--r-- 1 bin bin 14415 Aug 3 05:50
> > > DBM_Filter.pm
> > > dr-xr-xr-x 3 bin bin 96 Nov 2 12:54 Data
> > > dr-xr-xr-x 2 bin bin 96 Nov 2 12:54 Devel
> > > dr-xr-xr-x 2 bin bin 8192 Nov 2 12:54 Digest
> > > -r--r--r-- 1 bin bin 10316 Aug 3 05:50 Digest.pm
> > > -r--r--r-- 1 bin bin 1899 Aug 3 05:50 DirHandle.pm
> > > -r--r--r-- 1 bin bin 16897 Aug 3 05:50 Dumpvalue.pm
> > > dr-xr-xr-x 2 bin bin 8192 Nov 2 12:54 Encode
> > > -r--r--r-- 1 bin bin 4519 Aug 3 05:50 English.pm
> > > -r--r--r-- 1 bin bin 5170 Aug 3 05:50 Env.pm
> > > dr-xr-xr-x 2 bin bin 96 Nov 2 12:54 Exporter
> > > -r--r--r-- 1 bin bin 14481 Aug 3 05:50 Exporter.pm
> > > dr-xr-xr-x 6 bin bin 8192 Nov 2 12:54 ExtUtils
> > > -r--r--r-- 1 bin bin 5208 Aug 3 05:50 Fatal.pm
> > > dr-xr-xr-x 3 bin bin 8192 Nov 2 12:54 File
> > > -r--r--r-- 1 bin bin 5405 Aug 3 05:50 FileCache.pm
> > > -r--r--r-- 1 bin bin 6771 Aug 3 05:50
> > > FileHandle.pm
> > > dr-xr-xr-x 2 bin bin 96 Nov 2 12:54 Filter
> > > -r--r--r-- 1 bin bin 5668 Aug 3 05:50 FindBin.pm
> > > dr-xr-xr-x 3 bin bin 96 Nov 2 12:54 Font
> > > dr-xr-xr-x 2 bin bin 96 Nov 2 12:54 Getopt
> > > dr-xr-xr-x 4 bin bin 8192 Nov 2 12:54 HTML
> > > dr-xr-xr-x 5 bin bin 8192 Nov 2 12:54 HTTP
> > > dr-xr-xr-x 3 bin bin 96 Nov 2 12:54 I18N
> > > dr-xr-xr-x 36 bin bin 8192 Nov 2 12:55
> > > IA64.ARCHREV_0-thread-multi
> > > dr-xr-xr-x 2 bin bin 96 Nov 2 12:55 IO
> > > dr-xr-xr-x 2 bin bin 96 Nov 2 12:55 IPC
> > > dr-xr-xr-x 4 bin bin 8192 Nov 2 12:55 LWP
> > > -r--r--r-- 1 bin bin 21427 Jul 19 23:16 LWP.pm
> > > dr-xr-xr-x 3 bin bin 8192 Nov 2 12:55 Locale
> > > -r--r--r-- 1 bin bin 1141 Nov 27 2003 MD5.pm
> > > dr-xr-xr-x 4 bin bin 8192 Nov 2 12:55 Math
> > > dr-xr-xr-x 2 bin bin 8192 Nov 2 12:55 Memoize
> > > -r--r--r-- 1 bin bin 35275 Aug 3 05:50 Memoize.pm
> > > dr-xr-xr-x 3 bin bin 96 Nov 2 12:55 Module
> > > -r--r--r-- 1 bin bin 16122 Aug 3 05:50 NEXT.pm
> > > dr-xr-xr-x 5 bin bin 8192 Nov 6 22:04 Net
> > > dr-xr-xr-x 6 bin bin 8192 Nov 2 12:55 PPM
> > > dr-xr-xr-x 3 bin bin 96 Nov 2 12:55 PerlIO
> > > -r--r--r-- 1 bin bin 10928 Aug 3 05:50 PerlIO.pm
> > > dr-xr-xr-x 4 bin bin 8192 Nov 2 12:55 Pod
> > > dr-xr-xr-x 3 bin bin 96 Nov 2 12:55 SOAP
> > > dr-xr-xr-x 2 bin bin 96 Nov 2 12:55 Search
> > > -r--r--r-- 1 bin bin 1070 Aug 3 05:50
> > > SelectSaver.pm
> > > -r--r--r-- 1 bin bin 13203 Aug 3 05:50
> > > SelfLoader.pm
> > > -r--r--r-- 1 bin bin 8457 Aug 3 05:50 Shell.pm
> > > -r--r--r-- 1 bin bin 28651 Aug 3 05:50 Switch.pm
> > > -r--r--r-- 1 bin bin 4794 Aug 3 05:50 Symbol.pm
> > > drwxr-xr-x 4 root sys 8192 Nov 6 21:58 TAP
> > > dr-xr-xr-x 3 bin bin 8192 Nov 2 12:55 Term
> > > dr-xr-xr-x 4 bin bin 8192 Nov 6 21:58 Test
> > > -r--r--r-- 1 bin bin 28863 Aug 3 05:50 Test.pm
> > > dr-xr-xr-x 2 bin bin 8192 Nov 2 12:55 Text
> > > dr-xr-xr-x 2 bin bin 96 Nov 2 12:55 Thread
> > > -r--r--r-- 1 bin bin 10152 Aug 3 05:50 Thread.pm
> > > dr-xr-xr-x 2 bin bin 8192 Nov 2 12:55 Tie
> > > dr-xr-xr-x 2 bin bin 96 Nov 2 12:55 Time
> > > dr-xr-xr-x 2 bin bin 96 Nov 2 12:55 UDDI
> > > -r--r--r-- 1 bin bin 4052 Aug 3 05:50 UNIVERSAL.pm
> > > dr-xr-xr-x 4 bin bin 8192 Nov 2 12:55 URI
> > > -r--r--r-- 1 bin bin 30307 Nov 5 2004 URI.pm
> > > dr-xr-xr-x 3 bin bin 96 Nov 2 12:55 Unicode
> > > dr-xr-xr-x 2 bin bin 96 Nov 2 12:55 User
> > > dr-xr-xr-x 3 bin bin 96 Nov 2 12:55 WWW
> > > dr-xr-xr-x 8 bin bin 8192 Nov 2 12:55 XML
> > > dr-xr-xr-x 3 bin bin 96 Nov 2 12:55 XMLRPC
> > > -r--r--r-- 1 bin bin 838 Aug 3 05:50 abbrev.pl
> > > -r--r--r-- 1 bin bin 1298 Aug 3 05:50 assert.pl
> > > -r--r--r-- 1 bin bin 12844 Aug 3 05:50
> > > attributes.pm
> > > -r--r--r-- 1 bin bin 4238 Aug 3 05:50 autouse.pm
> > > -r--r--r-- 1 bin bin 6524 Aug 3 05:50 base.pm
> > > -r--r--r-- 1 bin bin 7368
>
> ...
>
> read more =BB
Hi
Could anyone help with this
when I did
chmod -R 644 /opt/perl_32/5.8.8
it must of broke a link or pointer
now perl scripts get this error when I try to start them.
$ perl -MCPAN -e shell
/usr/lib/hpux32/dld.so: Unable to find library 'libperl.so'.
Killed
What's odd to me is there is a /opt/perl_64/5.8.8 directory too. would
loading perl produce both perl_32 and perl_64 directories?
Thanks
Mike
------------------------------
Date: Thu, 08 Nov 2007 00:40:07 -0800
From: mmccaws2 <mmccaws@comcast.net>
Subject: Re: problems building perl modules, path question
Message-Id: <1194511207.726862.26940@e9g2000prf.googlegroups.com>
On Nov 7, 6:26 pm, Ben Morrow <b...@morrow.me.uk> wrote:
> Quoth mmccaws2 <mmcc...@comcast.net>:
>
> > On Nov 7, 12:12 pm, elsiddik <elsid...@gmail.com> wrote:
> > > On Nov 7, 7:05 pm, mmccaws2 <mmcc...@comcast.net> wrote:
> > > > On Nov 7, 8:59 am, Ben Morrow <b...@morrow.me.uk> wrote:
>
> > > > > $ perl -MCPAN -eshell
> > > > > cpan> o conf make_install_make_command "sudo make"
> > > > > cpan> o conf mbuild_install_build_command "sudo ./Build"
> > > > > cpan> o conf commit
> > > > > cpan> quit
> > > > > $
> [snip]
> > > > > No, all the modules already installed should be fine (you might w=
ant to
> > > > > check that everything under /opt/perl_32/lib is owned by root).
>
> > > > well chown -R worked.
>
> Good.
>
> > > > now the next part, and sorry for being so dense, But I don't sudo p=
erl
> > > > -MCPAN -e shell but run those commands after entering perl -MCPAN -e
> > > > shell. Correct?
>
> Correct. Hence the '$' prompt.
>
> > > > also the /opt/perl_32/lib/5.8.8/ has a lot of files with read only
> > > > permissions. Would the correct approach be chmod -R 644 /opt/perl_=
32/
> > > > lib/5.8.8/ or is that too broad of a command?
>
> No! Don't touch anything in there: that's core perl stuff. Why would you
> think it should be writable?
>
> > > > $ ls -l /opt/perl_32/lib/5.8.8/
>
> > > > gives
>
> [lots of stuff that looks fine]
>
> > > ...
>
> > > read more =BB
>
> If you're going to quote someone, please do so in a comprehensible
> manner. Google Groups ne Usenet.
>
> > I now get this error using perl -MCPAN -e shell
>
> > $ perl -MCPAN -e shell
> > /usr/lib/hpux32/dld.so: Unable to find library 'libperl.so'.
>
> Well... what else have you changed? If you've been messing about with
> the permissions of .../lib/5.8.8 then put things back the way they were.
>
> > the permissions for this is
> > ls -l /opt/perl_64/lib/5.8.8/IA64.ARCHREV_0-thread-multi-LP64/CORE/
> > libperl.so
> > -r-xr-xr-x 1 bin bin 4324272 Sep 13 23:24 /opt/perl_64/
> > lib/5.8.8/IA64.ARCHREV_0-thread-multi-LP64/CORE/libperl.so
>
> Uh, why are you showing me a listing for a perl that lives under
> /opt/perl_64 when before you were asking about a perl that lived under
> /opt/perl_32? Are you mixing up 32- and 64-bit perls? That probably
> won't work.
>
> > what should the settings be for libperl.so?
>
> Whatever the ActiveState installer left them as. CPAN.pm won't have
> touched them.
>
> Ben
Actually I thought that, perl_32, was interesting too. So I need to
change the core permissions to back to what they were. The only
command that I applied to the core was chmod -R 644 as I said
earlier. On the other machine, a hpux 11i earlier version 11 or 13,
there is no libperl.so file. There are two libperl file, libperl.a
and libperl.sl, r--r--r-- and r-xr-xr-x respectively. Would the
latter correspond to the libperl.so on the machine that I changed?
As to the two libraries, I don't really understand why there are two,
perl_32 and perl_64 that since I didn't build perl5.8.8. It is a
itanium 64 bit and the OS is a 64 bit OS.
Could using chmod on files break a link?
Thanks for getting back. I have a lot of work to do.
Mike
------------------------------
Date: 6 Apr 2001 21:33:47 GMT (Last modified)
From: Perl-Users-Request@ruby.oce.orst.edu (Perl-Users-Digest Admin)
Subject: Digest Administrivia (Last modified: 6 Apr 01)
Message-Id: <null>
Administrivia:
#The Perl-Users Digest is a retransmission of the USENET newsgroup
#comp.lang.perl.misc. For subscription or unsubscription requests, send
#the single line:
#
# subscribe perl-users
#or:
# unsubscribe perl-users
#
#to almanac@ruby.oce.orst.edu.
NOTE: due to the current flood of worm email banging on ruby, the smtp
server on ruby has been shut off until further notice.
To submit articles to comp.lang.perl.announce, send your article to
clpa@perl.com.
#To request back copies (available for a week or so), send your request
#to almanac@ruby.oce.orst.edu with the command "send perl-users x.y",
#where x is the volume number and y is the issue number.
#For other requests pertaining to the digest, send mail to
#perl-users-request@ruby.oce.orst.edu. Do not waste your time or mine
#sending perl questions to the -request address, I don't have time to
#answer them even if I did know the answer.
------------------------------
End of Perl-Users Digest V11 Issue 1014
***************************************