[Perl-unix-users] SHA and PERL

2006-03-10 Thread Its Azfar
I am running qmail with ldap backend. I have an application (Platypus) which can connect to ldap and make user accounts. It forward plain text password from my database (MS SQL) to ldap hence userPassword fieled remain clear text but base_64 encoded. My old ldap (netscape DS) can automaticay crypt

[Perl-unix-users] how to improve text manipulation

2006-03-10 Thread eyal edri
hi,i need your help in finding the right commands to do a certain log file manipulation.whats needs to be done: 1. Copy all lines from a log file which matches a certain 'datecode' (mmddhh) (the starting column of this code is known) into a new    filename with the same datecode. line example:

Re: [Perl-unix-users] how to improve text manipulation

2006-03-10 Thread $Bill Luebkert
eyal edri wrote: > what i did and it's not good enough: > > 1. i've implemented this using ordinary "foreach $line (@lines)" file > processing, which is very slow when handeling large files. > and then it's quite easy. (using substr and such...). > > what i think needs to be done (and here i

RE: [Perl-unix-users] how to improve text manipulation

2006-03-10 Thread Peter Eisengrein
While the foreach() may be slow, I don't see any way around it if it is possible that the date codes may change. Can you show some code? People may have ideas on how to improve performance of what you've already written.     -Original Message-From: [EMAIL PROTECTED] [mailto:[

Re: [Perl-unix-users] how to improve text manipulation

2006-03-10 Thread eyal edri
here is a snippet of the script, doing the part of:1. reading the file2. writing each line to it's destination target file.3. chopping the line to to the 1st max chars (from the conf file).. if (!open (LOGFILE, $file)) { fatal ("can't open $file\nfile corrupted?\n"); (fatal is just a sub th

[Perl-unix-users] how to improve text manipulation

2006-03-10 Thread eyal edri
it might be that i can assume there's only one datecode per file, if this assumption can speed up the processing significatly, than it's possible. is there away to do 'grep' on a file? (and not an array) Also, the call for sub 'checknumofchars' can be done outside the loop, thus reducing time of th