| xhoster@gmail.com 2007-06-26, 10:03 pm |
| jrpfinch <jrpfinch@gmail.com> wrote:
> Dear gurus,
>
> Please could somebody give me a hint as to why this script at the
> bottom of this post does not work when I remove the nofork=>1 from
> line 19? When I remove it (i.e. the scheduler becomes a forking
> scheduler), checkMsMessages works the first time, but the second time
> I get an error:
Complex protocols often don't work across forks, so this doesn't surprise
me. One possible problem is that I think most SSH ciphers use CBC, which
means encrypted text of one block is used as part of the encryption of the
next block. Since forked sibling processes don't share this state
information, they can't work properly.
>
> bash-2.05# /opt/perl5.8.8/bin/perl distill2.pl
> Scheduling started...
> stdout is beatbox
> Bad packet length 1879469963 at /opt/perl5.8.8/lib/site_perl/5.8.8/Net/
> SSH/Perl/Packet.pm line 175
>
> Ultimately I would like the scheduler to be forking because it will
> have multiple entries all happening at similar times. Any tips on how
> to achieve this would be appreciated. Setting up an SSH login every
> time checkMsMessages is called would be expensive, so I would like to
> avoid this.
It *might* be possible to hack away at SSH to get it to work, but I think a
better avenue would be either to just accept the cost of setting up SSH
login each time, or change the cron to invoke your routine 1/10 (or
whatever) as often and then have the process itself loop 10 times on the
same connection before closing it.
Xho
--
-------------------- http://NewsReader.Com/ --------------------
Usenet Newsgroup Service $9.95/Month 30GB
|