[27955] in Perl-Users-Digest

home help back first fref pref prev next nref lref last post

Perl-Users Digest, Issue: 9319 Volume: 10

daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Tue Jun 20 06:05:53 2006

Date: Tue, 20 Jun 2006 03:05:05 -0700 (PDT)
From: Perl-Users Digest <Perl-Users-Request@ruby.OCE.ORST.EDU>
To: Perl-Users@ruby.OCE.ORST.EDU (Perl-Users Digest)

Perl-Users Digest           Tue, 20 Jun 2006     Volume: 10 Number: 9319

Today's topics:
        fork messing up parent filehandle <darksaga_work@yahoo.com>
    Re: How to pass a control-6 in Net::Telnet <hoosier45678@hotmail.com>
        new CPAN modules on Tue Jun 20 2006 (Randal Schwartz)
    Re: noob asks: differences Activestate 5.8.x vs 5.6.x.  <sisyphus1@nomail.afraid.org>
        OO Perl help for a dot Net convert? ben.wilder@gmail.com
        Out of memory <janicehwang1325@yahoo.com>
    Re: Out of memory <xemoth@gmail.com>
    Re: Out of memory <janicehwang1325@yahoo.com>
    Re: output unbuffered ? <tadmc@augustmail.com>
        Posting Guidelines for comp.lang.perl.misc ($Revision:  tadmc@augustmail.com
    Re: question on "make test" <"v.niekerk at hccnet.nl">
    Re: question on "make test" <"v.niekerk at hccnet.nl">
    Re: question on "make test" <"v.niekerk at hccnet.nl">
    Re: Rpmdrake won't start :( <tomee@ZMIEN-tlen-NA-kadu.tlen.net>
        Digest Administrivia (Last modified: 6 Apr 01) (Perl-Users-Digest Admin)

----------------------------------------------------------------------

Date: 20 Jun 2006 02:08:54 -0700
From: "darksaga" <darksaga_work@yahoo.com>
Subject: fork messing up parent filehandle
Message-Id: <1150794534.686530.86780@h76g2000cwa.googlegroups.com>

hi everybody,

i wrote a script where i use the fork command to speed up computation
of a program. the parent process spawns a limited number of children,
which process something. after a child process finishes its task a new
child is generated. this is repeated until the parent process reaches
the end of a file it runs through.

problem is that the fork command seems to mess up the parent filehandle
to my file, altough the children do not use this filehandle. when
looping through the file, the filehandle is magically reset to the
beginning of the file, or a position near the beginning. (see code
below)

i've read some other posts about the same prob. e.g.:
http://snipurl.com/s0pq
http://snipurl.com/s0ps
but there was no solution :/.

only thing was a workaround to read the file before forking into an
array, this solution is suboptimal for me coz my file could be >1GB.

sysnfo:
os: sun4u sparc 5.8
perl: v5.8.6 built for sun4-solaris

maybe there's someone out there, who knows a solution...

greets darksaga
____________________
#! /usr/bin/env perl -w
use strict;
use FileHandle;

my %children;
my $maxChildren = 10;
my $fileHandle = undef;

my $file = 'testFile';
createTestFile($file);

# start of main prog.
print "initial child spawning...\n";
for (1..$maxChildren)
{
	if(my $line = getNextLine($file))
	{
		print "$line\n";
		if(scalar(keys(%children)) < $maxChildren)
		{
			my $delay = int(rand 2)+1;
  			my $child = create_child($delay);
			$children{$child} = "(slept $delay seconds)";
		}
	}
}
print "initial child spawning done...\n";

while(1) # loop until all done
{
  	my @pids = sort keys %children;
  	if (@pids)
	{
		#print "currently active children: @pids\n";
		if(my $line = getNextLine($file))
		{
			print "$line\n";
			if(scalar(keys(%children)) < $maxChildren)
			{
				my $delay = int(rand 2)+1;
  				my $child = create_child($delay);
				$children{$child} = "(slept $delay seconds)";
			}
		}
  	}
	else
	{
    		print "all child processes are finished...\n";
  	}
  	if (($_ = wait) == -1)
	{
    		print "wait() says no more children...\n";
    		last;
  	}
	else
	{
		#print "child $_ has finished processing...". $children{$_} ."\n";
		delete $children{$_};
 	}
}
print "parent is done...\n";


sub create_child
{
	my ($delay) = @_;
  	my $pid = fork();
  	die "Unable to fork: $!" unless defined $pid;
  	return $pid if $pid;          # Parent
  	child_routine($delay);          # Child
  	die "Child $$ returned when it should have exited";
}

sub child_routine
{
	my ($delay) = @_;
  	#print "Child $$ sleeping for $delay seconds\n";
  	sleep $delay;
  	#print "Child $$ exiting\n";
  	exit 0;
}

sub getNextLine
{
	my ($fileName) = @_;
	if (!$fileHandle)
	{
		$fileHandle = new FileHandle;
		$fileHandle->open("< $fileName") or die $!;
	}
	my $entry = $fileHandle->getline();
	unless($entry)
	{
    		close $fileHandle;
    		return undef;
  	}
	chomp($entry);
	return 	$entry;
}

sub createTestFile
{
	my ($fileName) = @_;
	open(my $write, ">", "$file") or die $!;
	for(1..30)
	{
		print $write "$_\n";
	}
	close $write;	
}



------------------------------

Date: Tue, 20 Jun 2006 00:06:31 -0500
From: James <hoosier45678@hotmail.com>
Subject: Re: How to pass a control-6 in Net::Telnet
Message-Id: <pan.2006.06.20.05.06.26.625462@hotmail.com>

On Mon, 19 Jun 2006 08:21:59 -0700, pablo.barbachano wrote:

> Hi, I'm just developing a small script that communicates with a small
> piece of hw. The hw switches between modes when you press Control-6. How
> can I send that from Net::Telnet? I suppose that the ->put($value) is the
> most suitable since it doesn't add a "\n" at the end, but what is the
> $value I have to put there? AFAIK control-6 is not one of the ASCII escape
> sequences, is it?
> 
> Thanks in advance
> Pablo


This is untested, so ymmv...

I used xev to get the XLookupString of C-6, which was 0x1e.

This can be packed into a binary char using:
$mode_switch = pack ("c", 0x1e);

 ...which can hopefully be sent using $t->put($mode_string), unless
translation happens at some other level.  Let me know how it goes.  I use
Net::Telnet* and Net::SSH2 all the time for screen scraping, and this
might come up in the future.


------------------------------

Date: Tue, 20 Jun 2006 04:42:07 GMT
From: merlyn@stonehenge.com (Randal Schwartz)
Subject: new CPAN modules on Tue Jun 20 2006
Message-Id: <J156E7.BqK@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-MetaSyntactic-0.79
http://search.cpan.org/~book/Acme-MetaSyntactic-0.79/
Themed metasyntactic variables names
----
Algorithm-Cluster-1.32
http://search.cpan.org/~mdehoon/Algorithm-Cluster-1.32/
Perl interface to the C Clustering Library.
----
Algorithm-Pair-Swiss-0.13
http://search.cpan.org/~ggoudsmit/Algorithm-Pair-Swiss-0.13/
Generate unique pairings for tournaments
----
Apache-SPARQL-0.22
http://search.cpan.org/~areggiori/Apache-SPARQL-0.22/
mod_perl handler base class to implement a SPARQL query service using HTTP bindings.
----
Apache-SPARQL-RDFStore-0.3
http://search.cpan.org/~areggiori/Apache-SPARQL-RDFStore-0.3/
A mod_perl handler which implements SPARQL HTTP bindings with RDFStore
----
Boost-Graph-1.2
http://search.cpan.org/~dburdick/Boost-Graph-1.2/
Perl interface to the Boost-Graph C++ libraries.
----
CPANPLUS-0.070_04
http://search.cpan.org/~kane/CPANPLUS-0.070_04/
Command-line access to the CPAN interface
----
Continuity-0.7
http://search.cpan.org/~awwaiid/Continuity-0.7/
Abstract away statelessness of HTTP using continuations, for stateful Web applications
----
Date-HolidayParser-0.2
http://search.cpan.org/~zerodogg/Date-HolidayParser-0.2/
Parser for .holiday-files
----
Ezmlm-0.07.2
http://search.cpan.org/~sumpfrall/Ezmlm-0.07.2/
Object Methods for Ezmlm Mailing Lists
----
Formatter-HTML-MPS-0.1
http://search.cpan.org/~vetler/Formatter-HTML-MPS-0.1/
----
Games-Mastermind-Solver-0.01
http://search.cpan.org/~mbarbon/Games-Mastermind-Solver-0.01/
a Master Mind puzzle solver
----
Getopt-GUI-Long-0.6
http://search.cpan.org/~hardaker/Getopt-GUI-Long-0.6/
----
Handel-0.33
http://search.cpan.org/~claco/Handel-0.33/
Simple commerce framework with AxKit/TT/Catalyst support
----
Log-Dispatch-Wx-0.01
http://search.cpan.org/~mbarbon/Log-Dispatch-Wx-0.01/
Object for logging through Wx::Log*
----
MARC-Lint-1.42
http://search.cpan.org/~eijabb/MARC-Lint-1.42/
Perl extension for checking validity of MARC records
----
Mac-Carbon-0.75
http://search.cpan.org/~cnandor/Mac-Carbon-0.75/
Access to Mac OS Carbon API
----
Mac-PropertyList-SAX-0.02
http://search.cpan.org/~kulp/Mac-PropertyList-SAX-0.02/
work with Mac plists at a low level (with real XML parsers)
----
Mac-PropertyList-SAX-0.03
http://search.cpan.org/~kulp/Mac-PropertyList-SAX-0.03/
work with Mac plists at a low level (with real XML parsers)
----
Net-FTP-Throttle-0.31
http://search.cpan.org/~lbrocard/Net-FTP-Throttle-0.31/
----
Net-GPSD-0.25
http://search.cpan.org/~mrdvt/Net-GPSD-0.25/
Provides a perl interface to the gpsd daemon.
----
PDF-API2-0.53
http://search.cpan.org/~areibens/PDF-API2-0.53/
A Perl Module Chain to faciliate the Creation and Modification of High-Quality "Portable Document Format (aka. PDF)" Files.
----
PITA-Test-Image-Qemu-0.02
http://search.cpan.org/~adamk/PITA-Test-Image-Qemu-0.02/
A tiny Qemu test image that only boots and pings
----
QWizard-3.0
http://search.cpan.org/~hardaker/QWizard-3.0/
Display a series of questions, get the answers, and act on the answers.
----
RDFStore-0.51
http://search.cpan.org/~areggiori/RDFStore-0.51/
Perl extesion to store and query RDF graphs
----
Test-Base-0.52
http://search.cpan.org/~ingy/Test-Base-0.52/
A Data Driven Testing Framework
----
Test-WWW-Mechanize-1.10
http://search.cpan.org/~petdance/Test-WWW-Mechanize-1.10/
Testing-specific WWW::Mechanize subclass
----
Tie-CheckVariables-0.01
http://search.cpan.org/~reneeb/Tie-CheckVariables-0.01/
check/validate variables for their datatype
----
Tk-Wizard-Bases-1.9451
http://search.cpan.org/~lgoddard/Tk-Wizard-Bases-1.9451/
----
Unicode-Japanese-0.35
http://search.cpan.org/~hio/Unicode-Japanese-0.35/
Japanese Character Encoding Handler
----
WWW-Bugzilla-0.8
http://search.cpan.org/~bmc/WWW-Bugzilla-0.8/
Handles submission/update of bugzilla bugs via WWW::Mechanize.
----
WWW-Search-DrugBank-0.01
http://search.cpan.org/~diberri/WWW-Search-DrugBank-0.01/
Access DrugBank's database of pharmaceuticals
----
WWW-Search-HGNC-0.02
http://search.cpan.org/~diberri/WWW-Search-HGNC-0.02/
Access HGNC's database of proteins
----
cPanel-SyncUtil-v0.0.2
http://search.cpan.org/~dmuey/cPanel-SyncUtil-v0.0.2/
Perl extension for creating utilities that work with cpanelsync aware directories
----
dmake-4.5-20060619-SHAY
http://search.cpan.org/~shay/dmake-4.5-20060619-SHAY/
----
mp3cut-1.11
http://search.cpan.org/~jv/mp3cut-1.11/
split MP3 files according to cue sheets
----
mp3info-1.06
http://search.cpan.org/~jv/mp3info-1.06/
prints MP3 header info
----
parrot-0.4.5
http://search.cpan.org/~ltoetsch/parrot-0.4.5/


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: Tue, 20 Jun 2006 17:53:15 +1000
From: "Sisyphus" <sisyphus1@nomail.afraid.org>
Subject: Re: noob asks: differences Activestate 5.8.x vs 5.6.x. pros vs cons of each?
Message-Id: <4497aa46$0$26423$afc38c87@news.optusnet.com.au>


"Phil" <boardhead62@hotmail.com> wrote in message
news:boardhead62-1906061513330001@u87.n24.queensu.ca...
> There is a bug in the memory handling of ActivePerl 5.8.x which
> may cause EXTREME slowdowns when handling large blocks of memory.
> One of my scripts was around 100x slower running on 5.8.x as
> compared to the speed on 5.6.x.  Other people have experienced
> this problem as well.
>

Sounds interesting .... can you post a simple demo (or provide more info ...
eg a relevant link) ?

Cheers,
Rob




------------------------------

Date: 20 Jun 2006 02:12:29 -0700
From: ben.wilder@gmail.com
Subject: OO Perl help for a dot Net convert?
Message-Id: <1150794749.421759.108400@h76g2000cwa.googlegroups.com>

Hello all,

I am making the transition from .Net to Perl for a new project and i
have a few questions about OO Perl, that i would be most grateful if
someone could comment on / answer!

Many thanks for any of your help,


This problem is conceptual, in that i am waiting to learn about certain
features before trying to actually implement this - so i'll put
together a dummy OO module and a calling script.

------------------------------------------------------------------------------------------
****************
* Perl Module  *
****************
package MyPackage;


#Use definitions
use strict;


#Contructor for MyPackage Class
sub new {
  my ($class, %arg) = @_;
  bless {
        _myFirstName		=>	$arg{myFirstName},
        _myLastName 		=>	$arg{myLastName},
	_myAge			=>	$arg{myAge},
	_myFavouriteArtists	=>	$arg{myFavouriteArtists},
  	}, $class;
}


sub ShowAgeAndArtists{

my $self = $_[0];

#Dereference array
my @myFavouriteArtists = @{$self->{_myFavouriteArtists}};

my $artist = '';

foreach $artist ( @myFavouriteArtists )
{
	print "$self->{_myFirstName} aged  $self->{_myAge}, likes $artist\n";
}


}

1;
------------------------------------------------------------------------------------------


------------------------------------------------------------------------------------------
********************
*  Calling script  *
********************
#!/usr/bin/perl -w

use strict;
use MyPackage;

my $myFirstName = 'Ben';
my $myLastName = 'Wilder';
my $myAge = 28;
my @myFavouriteArtists = qw[Wolfmother LedZep ChesneyHawkes];

#Instantiate MyPackage class
my $myPackage =
MyPackage->new(myFirstName=>$myFirstName,myLastName=>$myLastName,myAge=>$myAge,myFavouriteArtists=>\@myFavouriteArtists);

$myPackage->ShowAgeAndArtists();

------------------------------------------------------------------------------------------

Now that i have my example, i'd like to ask a few questions:

1. I am passing a reference to the @myFavouriteArtists array, however
with objects being in my mind, an encapsulation of data, it this the
most effective way to pass array data to an object? Can i pass the data
by value so that the object deals with its own copy of the data - or am
i being silly?


2. In MS .Net there is the principle of object fields, object instance
scoped, not class scoped, that are not accessible through any public
methods, but are used possibly by methods private to the class. For
example - in the above scenario i may want to implement a boolean flag
"IsTooOld" that can be set by a private internal method for the
purposes of a logical decision elsewhere in the module. How can i
define such a variable in perl? It seems that since i am blessing the
hash into object-hood, that is where i will have to put the definition,
but i dont want the constructor to be able to alter this definition!
Any ideas (please let me know if i havent put explained this well
enough!)


Thanks again for any help!

Now go easy on the perl noob guys *backs into corner*


Ben



------------------------------

Date: 19 Jun 2006 22:39:26 -0700
From: "janicehwang1325@yahoo.com" <janicehwang1325@yahoo.com>
Subject: Out of memory
Message-Id: <1150781965.448703.205100@i40g2000cwc.googlegroups.com>

Hi,

I have a server running daemon and using thread to handle multiple
clients. However, when there is a huge data cominig from to the server,
the error prompt out saying it's out of memory. What is the cause of
that?



------------------------------

Date: 19 Jun 2006 23:14:36 -0700
From: "Owen" <xemoth@gmail.com>
Subject: Re: Out of memory
Message-Id: <1150784076.550966.33470@i40g2000cwc.googlegroups.com>


janicehwang1325@yahoo.com wrote:
> Hi,
>
> I have a server running daemon and using thread to handle multiple
> clients. However, when there is a huge data cominig from to the server,
> the error prompt out saying it's out of memory. What is the cause of
> that?

Generally it is because you have used up your allowed memory.

You don't say but do you have cpu/memory quotas on your server? For
example on one server I have a 3% allowance of the available memory.
Opening the same file file 6000 odd times gives me a "out of memory
error"

Could mean there is some wrong logic in your script


Xemoth



------------------------------

Date: 20 Jun 2006 00:54:46 -0700
From: "janicehwang1325@yahoo.com" <janicehwang1325@yahoo.com>
Subject: Re: Out of memory
Message-Id: <1150790086.083628.242910@u72g2000cwu.googlegroups.com>

Basically i don't set any memory quotas for my server. I will try to
check the logic of the program to see if there is any wrong. However,
it is just a simple program. Thank you very much

Owen wrote:
> janicehwang1325@yahoo.com wrote:
> > Hi,
> >
> > I have a server running daemon and using thread to handle multiple
> > clients. However, when there is a huge data cominig from to the server,
> > the error prompt out saying it's out of memory. What is the cause of
> > that?
>
> Generally it is because you have used up your allowed memory.
>
> You don't say but do you have cpu/memory quotas on your server? For
> example on one server I have a 3% allowance of the available memory.
> Opening the same file file 6000 odd times gives me a "out of memory
> error"
> 
> Could mean there is some wrong logic in your script
> 
> 
> Xemoth



------------------------------

Date: Mon, 19 Jun 2006 23:33:48 -0500
From: Tad McClellan <tadmc@augustmail.com>
Subject: Re: output unbuffered ?
Message-Id: <slrne9eulc.o1a.tadmc@magna.augustmail.com>

mkjindal@gmail.com <mkjindal@gmail.com> wrote:

> What is the meaning of "$| = 1;  # make output unbuffered" ?


All of Perl's special variables are documented in:

   perldoc perlvar

Note that the comment above is not correct, output will still
be buffered.


> - "$|" is the OR of regexp after dollar sign.


The funny characters mean different things when used in different places.

The funny characters above do not appear in a regex, so their
regex meanings are irrelevant.


-- 
    Tad McClellan                          SGML consulting
    tadmc@augustmail.com                   Perl programming
    Fort Worth, Texas


------------------------------

Date: 20 Jun 2006 07:22:46 GMT
From: tadmc@augustmail.com
Subject: Posting Guidelines for comp.lang.perl.misc ($Revision: 1.5 $)
Message-Id: <4497a246$0$57731$ae4e5890@news.nationwide.net>

Outline
   Before posting to comp.lang.perl.misc
      Must
       - Check the Perl Frequently Asked Questions (FAQ)
       - Check the other standard Perl docs (*.pod)
      Really Really Should
       - Lurk for a while before posting
       - Search a Usenet archive
      If You Like
       - Check Other Resources
   Posting to comp.lang.perl.misc
      Is there a better place to ask your question?
       - Question should be about Perl, not about the application area
      How to participate (post) in the clpmisc community
       - Carefully choose the contents of your Subject header
       - Use an effective followup style
       - Speak Perl rather than English, when possible
       - Ask perl to help you
       - Do not re-type Perl code
       - Provide enough information
       - Do not provide too much information
       - Do not post binaries, HTML, or MIME
      Social faux pas to avoid
       - Asking a Frequently Asked Question
       - Asking a question easily answered by a cursory doc search
       - Asking for emailed answers
       - Beware of saying "doesn't work"
       - Sending a "stealth" Cc copy
      Be extra cautious when you get upset
       - Count to ten before composing a followup when you are upset
       - Count to ten after composing and before posting when you are upset
-----------------------------------------------------------------

Posting Guidelines for comp.lang.perl.misc ($Revision: 1.5 $)
    This newsgroup, commonly called clpmisc, is a technical newsgroup
    intended to be used for discussion of Perl related issues (except job
    postings), whether it be comments or questions.

    As you would expect, clpmisc discussions are usually very technical in
    nature and there are conventions for conduct in technical newsgroups
    going somewhat beyond those in non-technical newsgroups.

    The article at:

        http://www.catb.org/~esr/faqs/smart-questions.html

    describes how to get answers from technical people in general.

    This article describes things that you should, and should not, do to
    increase your chances of getting an answer to your Perl question. It is
    available in POD, HTML and plain text formats at:

     http://mail.augustmail.com/~tadmc/clpmisc.shtml

    For more information about netiquette in general, see the "Netiquette
    Guidelines" at:

     http://andrew2.andrew.cmu.edu/rfc/rfc1855.html

    A note to newsgroup "regulars":

       Do not use these guidelines as a "license to flame" or other
       meanness. It is possible that a poster is unaware of things
       discussed here.  Give them the benefit of the doubt, and just
       help them learn how to post, rather than assume 

    A note about technical terms used here:

       In this document, we use words like "must" and "should" as
       they're used in technical conversation (such as you will
       encounter in this newsgroup). When we say that you *must* do
       something, we mean that if you don't do that something, then
       it's unlikely that you will benefit much from this group.
       We're not bossing you around; we're making the point without
       lots of words.

    Do *NOT* send email to the maintainer of these guidelines. It will be
    discarded unread. The guidelines belong to the newsgroup so all
    discussion should appear in the newsgroup. I am just the secretary that
    writes down the consensus of the group.

Before posting to comp.lang.perl.misc
  Must
    This section describes things that you *must* do before posting to
    clpmisc, in order to maximize your chances of getting meaningful replies
    to your inquiry and to avoid getting flamed for being lazy and trying to
    have others do your work.

    The perl distribution includes documentation that is copied to your hard
    drive when you install perl. Also installed is a program for looking
    things up in that (and other) documentation named 'perldoc'.

    You should either find out where the docs got installed on your system,
    or use perldoc to find them for you. Type "perldoc perldoc" to learn how
    to use perldoc itself. Type "perldoc perl" to start reading Perl's
    standard documentation.

    Check the Perl Frequently Asked Questions (FAQ)
        Checking the FAQ before posting is required in Big 8 newsgroups in
        general, there is nothing clpmisc-specific about this requirement.
        You are expected to do this in nearly all newsgroups.

        You can use the "-q" switch with perldoc to do a word search of the
        questions in the Perl FAQs.

    Check the other standard Perl docs (*.pod)
        The perl distribution comes with much more documentation than is
        available for most other newsgroups, so in clpmisc you should also
        see if you can find an answer in the other (non-FAQ) standard docs
        before posting.

    It is *not* required, or even expected, that you actually *read* all of
    Perl's standard docs, only that you spend a few minutes searching them
    before posting.

    Try doing a word-search in the standard docs for some words/phrases
    taken from your problem statement or from your very carefully worded
    "Subject:" header.

  Really Really Should
    This section describes things that you *really should* do before posting
    to clpmisc.

    Lurk for a while before posting
        This is very important and expected in all newsgroups. Lurking means
        to monitor a newsgroup for a period to become familiar with local
        customs. Each newsgroup has specific customs and rituals. Knowing
        these before you participate will help avoid embarrassing social
        situations. Consider yourself to be a foreigner at first!

    Search a Usenet archive
        There are tens of thousands of Perl programmers. It is very likely
        that your question has already been asked (and answered). See if you
        can find where it has already been answered.

        One such searchable archive is:

         http://groups.google.com/advanced_group_search

  If You Like
    This section describes things that you *can* do before posting to
    clpmisc.

    Check Other Resources
        You may want to check in books or on web sites to see if you can
        find the answer to your question.

        But you need to consider the source of such information: there are a
        lot of very poor Perl books and web sites, and several good ones
        too, of course.

Posting to comp.lang.perl.misc
    There can be 200 messages in clpmisc in a single day. Nobody is going to
    read every article. They must decide somehow which articles they are
    going to read, and which they will skip.

    Your post is in competition with 199 other posts. You need to "win"
    before a person who can help you will even read your question.

    These sections describe how you can help keep your article from being
    one of the "skipped" ones.

  Is there a better place to ask your question?
    Question should be about Perl, not about the application area
        It can be difficult to separate out where your problem really is,
        but you should make a conscious effort to post to the most
        applicable newsgroup. That is, after all, where you are the most
        likely to find the people who know how to answer your question.

        Being able to "partition" a problem is an essential skill for
        effectively troubleshooting programming problems. If you don't get
        that right, you end up looking for answers in the wrong places.

        It should be understood that you may not know that the root of your
        problem is not Perl-related (the two most frequent ones are CGI and
        Operating System related), so off-topic postings will happen from
        time to time. Be gracious when someone helps you find a better place
        to ask your question by pointing you to a more applicable newsgroup.

  How to participate (post) in the clpmisc community
    Carefully choose the contents of your Subject header
        You have 40 precious characters of Subject to win out and be one of
        the posts that gets read. Don't waste them. Take care while
        composing them, they are the key that opens the door to getting an
        answer.

        Spend them indicating what aspect of Perl others will find if they
        should decide to read your article.

        Do not spend them indicating "experience level" (guru, newbie...).

        Do not spend them pleading (please read, urgent, help!...).

        Do not spend them on non-Subjects (Perl question, one-word
        Subject...)

        For more information on choosing a Subject see "Choosing Good
        Subject Lines":

         http://www.cpan.org/authors/id/D/DM/DMR/subjects.post

        Part of the beauty of newsgroup dynamics, is that you can contribute
        to the community with your very first post! If your choice of
        Subject leads a fellow Perler to find the thread you are starting,
        then even asking a question helps us all.

    Use an effective followup style
        When composing a followup, quote only enough text to establish the
        context for the comments that you will add. Always indicate who
        wrote the quoted material. Never quote an entire article. Never
        quote a .signature (unless that is what you are commenting on).

        Intersperse your comments *following* each section of quoted text to
        which they relate. Unappreciated followup styles are referred to as
        "top-posting", "Jeopardy" (because the answer comes before the
        question), or "TOFU" (Text Over, Fullquote Under).

        Reversing the chronology of the dialog makes it much harder to
        understand (some folks won't even read it if written in that style).
        For more information on quoting style, see:

         http://web.presby.edu/~nnqadmin/nnq/nquote.html

    Speak Perl rather than English, when possible
        Perl is much more precise than natural language. Saying it in Perl
        instead will avoid misunderstanding your question or problem.

        Do not say: I have variable with "foo\tbar" in it.

        Instead say: I have $var = "foo\tbar", or I have $var = 'foo\tbar',
        or I have $var = <DATA> (and show the data line).

    Ask perl to help you
        You can ask perl itself to help you find common programming mistakes
        by doing two things: enable warnings (perldoc warnings) and enable
        "strict"ures (perldoc strict).

        You should not bother the hundreds/thousands of readers of the
        newsgroup without first seeing if a machine can help you find your
        problem. It is demeaning to be asked to do the work of a machine. It
        will annoy the readers of your article.

        You can look up any of the messages that perl might issue to find
        out what the message means and how to resolve the potential mistake
        (perldoc perldiag). If you would like perl to look them up for you,
        you can put "use diagnostics;" near the top of your program.

    Do not re-type Perl code
        Use copy/paste or your editor's "import" function rather than
        attempting to type in your code. If you make a typo you will get
        followups about your typos instead of about the question you are
        trying to get answered.

    Provide enough information
        If you do the things in this item, you will have an Extremely Good
        chance of getting people to try and help you with your problem!
        These features are a really big bonus toward your question winning
        out over all of the other posts that you are competing with.

        First make a short (less than 20-30 lines) and *complete* program
        that illustrates the problem you are having. People should be able
        to run your program by copy/pasting the code from your article. (You
        will find that doing this step very often reveals your problem
        directly. Leading to an answer much more quickly and reliably than
        posting to Usenet.)

        Describe *precisely* the input to your program. Also provide example
        input data for your program. If you need to show file input, use the
        __DATA__ token (perldata.pod) to provide the file contents inside of
        your Perl program.

        Show the output (including the verbatim text of any messages) of
        your program.

        Describe how you want the output to be different from what you are
        getting.

        If you have no idea at all of how to code up your situation, be sure
        to at least describe the 2 things that you *do* know: input and
        desired output.

    Do not provide too much information
        Do not just post your entire program for debugging. Most especially
        do not post someone *else's* entire program.

    Do not post binaries, HTML, or MIME
        clpmisc is a text only newsgroup. If you have images or binaries
        that explain your question, put them in a publically accessible
        place (like a Web server) and provide a pointer to that location. If
        you include code, cut and paste it directly in the message body.
        Don't attach anything to the message. Don't post vcards or HTML.
        Many people (and even some Usenet servers) will automatically filter
        out such messages. Many people will not be able to easily read your
        post. Plain text is something everyone can read.

  Social faux pas to avoid
    The first two below are symptoms of lots of FAQ asking here in clpmisc.
    It happens so often that folks will assume that it is happening yet
    again. If you have looked but not found, or found but didn't understand
    the docs, say so in your article.

    Asking a Frequently Asked Question
        It should be understood that you may have missed the applicable FAQ
        when you checked, which is not a big deal. But if the Frequently
        Asked Question is worded similar to your question, folks will assume
        that you did not look at all. Don't become indignant at pointers to
        the FAQ, particularly if it solves your problem.

    Asking a question easily answered by a cursory doc search
        If folks think you have not even tried the obvious step of reading
        the docs applicable to your problem, they are likely to become
        annoyed.

        If you are flamed for not checking when you *did* check, then just
        shrug it off (and take the answer that you got).

    Asking for emailed answers
        Emailed answers benefit one person. Posted answers benefit the
        entire community. If folks can take the time to answer your
        question, then you can take the time to go get the answer in the
        same place where you asked the question.

        It is OK to ask for a *copy* of the answer to be emailed, but many
        will ignore such requests anyway. If you munge your address, you
        should never expect (or ask) to get email in response to a Usenet
        post.

        Ask the question here, get the answer here (maybe).

    Beware of saying "doesn't work"
        This is a "red flag" phrase. If you find yourself writing that,
        pause and see if you can't describe what is not working without
        saying "doesn't work". That is, describe how it is not what you
        want.

    Sending a "stealth" Cc copy
        A "stealth Cc" is when you both email and post a reply without
        indicating *in the body* that you are doing so.

  Be extra cautious when you get upset
    Count to ten before composing a followup when you are upset
        This is recommended in all Usenet newsgroups. Here in clpmisc, most
        flaming sub-threads are not about any feature of Perl at all! They
        are most often for what was seen as a breach of netiquette. If you
        have lurked for a bit, then you will know what is expected and won't
        make such posts in the first place.

        But if you get upset, wait a while before writing your followup. I
        recommend waiting at least 30 minutes.

    Count to ten after composing and before posting when you are upset
        After you have written your followup, wait *another* 30 minutes
        before committing yourself by posting it. You cannot take it back
        once it has been said.

AUTHOR
    Tad McClellan <tadmc@augustmail.com> and many others on the
    comp.lang.perl.misc newsgroup.



------------------------------

Date: Tue, 20 Jun 2006 06:17:14 +0200
From: Huub <"v.niekerk at hccnet.nl">
Subject: Re: question on "make test"
Message-Id: <449776cd$0$26334$e4fe514c@dreader32.news.xs4all.nl>

Tad McClellan wrote:
> Huub <> wrote:
> 
>> What is the best thing to do?
> 
> 
> The best thing to do is to spend some tiny bit of effort to find
> the solution to your problems *before* asking hundreds of other
> people to help.
> 

I do.

> Have you tried googling for the error message text?
> 

Using altavista I found a few that were about Java. Nothing else.

> 
> I'm afraid I'm going to have to finally give up on you. 
> 
> It appears that reform is not forthcoming.
> 

What reform? I am rather new to Perl. Everything I did so far was trying 
to install Perl modules.

Thanks for responding anyway.


------------------------------

Date: Tue, 20 Jun 2006 06:21:55 +0200
From: Huub <"v.niekerk at hccnet.nl">
Subject: Re: question on "make test"
Message-Id: <449777f7$0$27468$e4fe514c@dreader26.news.xs4all.nl>

J. Gleixner wrote:
> Huub wrote:
>> Hi,
>>
>> After a successful "make", "make test" goes wrong with this:
> 
> A successful make of what?

"look DBD::mysql"
"perl Makefile.PL --testhost=<hostname>"
"make"

> YAATCBFUSE (Yet Another Answer That Could Be Found Using a Search Engine)
> 
> I entered "cannot restore segment prot after reloc", in my favorite 
> search engine, and found a bunch of helpful sites.  Nothing to do with 
> perl, everything to do with your OS.

I only found some site on this error with Java. Nothing with Perl. I'm 
running Fedora Core 5, btw.

Thank you for your response.


------------------------------

Date: Tue, 20 Jun 2006 07:23:09 +0200
From: Huub <"v.niekerk at hccnet.nl">
Subject: Re: question on "make test"
Message-Id: <4497863d$0$6897$e4fe514c@dreader14.news.xs4all.nl>

Thank you all. The problem is solved by disabling SELinux, which means 
it was the O.S. after all.

Thank you for your patience with me.


------------------------------

Date: Tue, 20 Jun 2006 10:16:43 +0200
From: Tomek Jarzynka <tomee@ZMIEN-tlen-NA-kadu.tlen.net>
Subject: Re: Rpmdrake won't start :(
Message-Id: <1439368.CdJzJlf60L@arista.4mind.pl>

Nudna wrotka - J. Gleixner napisal w <yIClg.5$oX2.1433@news.uswest.net>:

>> What can that mean? Where to look? I'm confused :|
>> I am a total perl idiot.
> You don't have to know perl to use a search engine.  Simply entering
> "rpmdrake.pm: in Google showed the following link, which seems to be
> quite similar.
> http://www.linuxquestions.org/questions/showthread.php?p=2226828

Yes, thanks, I found that later.
Earlier, I was googling for the exact error message "can not find 
function c::bind_textdomain_codeset" and "bind_textdomain_codeset" 
and were getting either no or thousands of irrelevant results.

Anyway, now I know what I need to fix.

-- 
tomasz k. jarzynka / 601 706 601 / tomee(a-t)kadu(d-o-t)net

"If it Smells it's Chemistry, if it Crawls it's Biology, if it doesn't work
it's Physics."



------------------------------

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 V10 Issue 9319
***************************************


home help back first fref pref prev next nref lref last post