🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: news.software.nntp
13 messages
13 total messages Started by Bettina Fink Fri, 02 Jan 1998 00:00
Size of INN binaries with perl?
#24763
Author: Bettina Fink
Date: Fri, 02 Jan 1998 00:00
21 lines
1221 bytes
Today I recompiled my INN with perl support enabled and I'm
a bit surprised how big the innd/in.nnrpd binaries grow.

Without perl support:
-r-xr-x---   1 news     news        80096 Jan  2 15:49 nnrpd*
-r-xr-x---   1 news     news       127956 Jan  2 15:49 innd*

With perl support:
-r-xr-x---   1 news     news       571456 Jan  2 11:47 nnrpd*
-r-xr-x---   1 news     news       623184 Jan  2 11:47 innd*

All binaries are stripped.

System is:
perl-5.004_04, linux-2.0.32, gcc-2.7.2.3, inn-1.7.2.insync-1.1d.

Is this the price I have to pay for the benefits of Cleanfeed :-)
or is there something I missed?

Re: Size of INN binaries with perl?
#24758
Author: Russ Allbery
Date: Fri, 02 Jan 1998 00:00
23 lines
1686 bytes
Jeff Fisher <rzxtlg@dogbert.ies-energy.com> writes:

> So why not symlink /usr/local/lib/libperl.so to the real libperl.so
> (/usr/local/lib/perl5/.....).  Link your binaries against the
> /usr/local/lib/libperl.so, and change that symlink when you upgrade
> perl.  This should keep you from having to re-link every application
> that uses the perl share library for every upgrade of perl.

The problem I believe is that libperl.so has an unstable interface; in
other words, something linked against libperl.so from 5.004 is not going
to like libperl.so from 5.005.  I could be wrong on that, but that's the
impression I got.

(Of course, I'm wrong on upgrading Perl blowing away the old libperl.so,
and even more wrong if you do what we do and install Perl's library files
under /usr/local/lib/perl5/<version_number>, which is probably the best
solution.)

-- 
Russ Allbery (rra@stanford.edu)         <URL:http://www.eyrie.org/~eagle/>

Re: Size of INN binaries with perl?
#24760
Author: Russ Allbery
Date: Fri, 02 Jan 1998 00:00
30 lines
1926 bytes
Bettina Fink <laura@krell.snafu.de> writes:

> I thought something like that, but the INSTALL file from the perl source
> doesn't sound very friendly about using a libperl.so:

> | The disadvantages are that there may be a significant performance
> | penalty associated with the shared libperl.so, and that the overall
> | mechanism is still rather fragile with respect to different versions
> | and upgrades.

> You have no problems with performance and stability?

The performance problem is with startup time -- a standard Perl script
will take a somewhat longer time to load with a shared libperl if libperl
isn't already in memory.  This isn't going to be an issue with INN, where
the innd process only starts once, and the forking speed of nnrpd
processes isn't really that big of an issue.

As for stability, the problem is that upgrading Perl will blow away your
libperl.so and anything linked against it probably won't work with the new
version of Perl until you recompile it, unless you include the Perl
version number in libperl.so (which is a bit tricky to do in the build
process).  Not a major problem; just be careful when upgrading Perl and
recompile INN too.

-- 
Russ Allbery (rra@stanford.edu)         <URL:http://www.eyrie.org/~eagle/>

Re: Size of INN binaries with perl?
#24772
Author: Jeff Fisher
Date: Fri, 02 Jan 1998 00:00
28 lines
1888 bytes
On 02 Jan 1998 10:03:32 -0800, Russ Allbery
     <rra@stanford.edu> said:
> 
> 
> As for stability, the problem is that upgrading Perl will blow away your
> libperl.so and anything linked against it probably won't work with the new
> version of Perl until you recompile it, unless you include the Perl
> version number in libperl.so (which is a bit tricky to do in the build
> process).  Not a major problem; just be careful when upgrading Perl and
> recompile INN too.

So why not symlink /usr/local/lib/libperl.so to the real libperl.so 
(/usr/local/lib/perl5/.....).  Link your binaries against the 
/usr/local/lib/libperl.so, and change that symlink when you upgrade
perl.  This should keep you from having to re-link every application
that uses the perl share library for every upgrade of perl.

In theory, it should work, but I haven't tried it personally.


-- 
Jeff Fisher                       | ...I want to be on the side of the many.
UNIX Sys Admin - IES Industries   | Therefore, I take great pains to explain
http://opus.ies-energy.com/jeff/  | to as many people as possible.
                                  |                      - Johannes Kepler

Re: Size of INN binaries with perl?
#24775
Author: Bettina Fink
Date: Fri, 02 Jan 1998 00:00
25 lines
1652 bytes
Russ Allbery <rra@stanford.edu> wrote:

>> Today I recompiled my INN with perl support enabled and I'm a bit
>> surprised how big the innd/in.nnrpd binaries grow.

>> -r-xr-x---   1 news     news       571456 Jan  2 11:47 nnrpd*
>> -r-xr-x---   1 news     news       623184 Jan  2 11:47 innd*

> I built Perl shared, which cuts that down quite a bit.  I think it might
> also decrease total memory usage, as with innd, nnrpd, and Perl scripts on
> the system all using Perl, with a shared libperl you can still just have
> one copy in memory.

I thought something like that, but the INSTALL file from the perl
source doesn't sound very friendly about using a libperl.so:

| The disadvantages are that there may be a significant performance
| penalty associated with the shared libperl.so, and that the overall
| mechanism is still rather fragile with respect to different versions
| and upgrades.

You have no problems with performance and stability?

Re: Size of INN binaries with perl?
#24781
Author: Russ Allbery
Date: Fri, 02 Jan 1998 00:00
23 lines
1383 bytes
Bettina Fink <laura@krell.snafu.de> writes:

> Today I recompiled my INN with perl support enabled and I'm a bit
> surprised how big the innd/in.nnrpd binaries grow.

> Without perl support:
> -r-xr-x---   1 news     news        80096 Jan  2 15:49 nnrpd*
> -r-xr-x---   1 news     news       127956 Jan  2 15:49 innd*

> With perl support:
> -r-xr-x---   1 news     news       571456 Jan  2 11:47 nnrpd*
> -r-xr-x---   1 news     news       623184 Jan  2 11:47 innd*

I built Perl shared, which cuts that down quite a bit.  I think it might
also decrease total memory usage, as with innd, nnrpd, and Perl scripts on
the system all using Perl, with a shared libperl you can still just have
one copy in memory.

-- 
Russ Allbery (rra@stanford.edu)         <URL:http://www.eyrie.org/~eagle/>

Re: Size of INN binaries with perl?
#24806
Author: Jeremy
Date: Sat, 03 Jan 1998 00:00
18 lines
1312 bytes
Russ Allbery  <rra@stanford.edu> wrote:

> (Of course, I'm wrong on upgrading Perl blowing away the old libperl.so,
> and even more wrong if you do what we do and install Perl's library files
> under /usr/local/lib/perl5/<version_number>, which is probably the best
> solution.)

I thought this sounded like a good idea, so I tried to build a shared Perl,
and it fails.  The make *segfaults*.  Consistently.  Anyone done this on
BSDI 3.0?  All I did was tell it to go shared, everything else in configure
was the same.

-- 
Jeremy  |  jeremy@exit109.com
"Who's scruffy-looking?"  --Han Solo

Re: Size of INN binaries with perl?
#24813
Author: Russ Allbery
Date: Sat, 03 Jan 1998 00:00
16 lines
1193 bytes
Jeremy <jeremy@exit109.com> writes:

> Perl.  It might just be beyond the capability of BSDI.

Looking over the BSD/OS hint file, which I'm not sure is applicable but
appears to be the closest, there seems to be something about dynamic
libperl.so not supported until 3.1?

I don't see any other reference to BSD problems.  You may want to send a
problem report to perlbug@perl.org.

-- 
Russ Allbery (rra@stanford.edu)         <URL:http://www.eyrie.org/~eagle/>

Re: Size of INN binaries with perl?
#24817
Author: Russ Allbery
Date: Sat, 03 Jan 1998 00:00
14 lines
1145 bytes
Jeremy <jeremy@exit109.com> writes:

> I thought this sounded like a good idea, so I tried to build a shared
> Perl, and it fails.  The make *segfaults*.  Consistently.  Anyone done
> this on BSDI 3.0?  All I did was tell it to go shared, everything else
> in configure was the same.

The make of perl or the make of INN?

-- 
Russ Allbery (rra@stanford.edu)         <URL:http://www.eyrie.org/~eagle/>

Re: Size of INN binaries with perl?
#24818
Author: rjk
Date: Sat, 03 Jan 1998 00:00
36 lines
2108 bytes
Russ Allbery <rra@stanford.edu> writes:

> As for stability, the problem is that upgrading Perl will blow away your
> libperl.so and anything linked against it probably won't work with the new
> version of Perl until you recompile it, unless you include the Perl
> version number in libperl.so (which is a bit tricky to do in the build
> process).  Not a major problem; just be careful when upgrading Perl and
> recompile INN too.

The solution to this problem suggested in the Perl docs is that the
path to libperl.so have the perl version number in it, and use -rpath
to make sure ld can see it.  Then when you upgrade Perl you have a
libperl.so for each version, and binaries linked against it still
work.

: sfere; cat /etc/ld.so.conf 
/usr/local/lib
/usr/X11R5/lib
/usr/lib/libc5-compat
/lib/libc5-compat
/usr/X11R6/lib
/usr/lib/i486-linuxaout
: sfere; echo $LD_LIBRARY_PATH   

: sfere; ldd /usr/local/sbin/innd
        libperl.so => /usr/local/lib/perl5/i586-linux/5.00404/CORE/libperl.so (0x4000b000)
        libm.so.5 => /lib/libm.so.5 (0x400a1000)
        libc.so.5 => /lib/libc.so.5 (0x400aa000)
: sfere; grep \^PERL config.data.1.7.2     
PERL_SUPPORT            DO
PERL_LIB        -L/usr/local/lib/perl5/i586-linux/5.00404/CORE -Wl,-rpath,/usr/local/lib/perl5/i586-linux/5.00404/CORE -lperl -lm
PERL_INC                -I/usr/local/lib/perl5/i586-linux/5.00404/CORE
: sfere; 

Re: Size of INN binaries with perl?
#24850
Author: Brian Young
Date: Sun, 04 Jan 1998 00:00
26 lines
1488 bytes
On 03 Jan 1998 21:45:56 -0800, Russ Allbery <rra@stanford.edu> wrote:

>Jeremy <jeremy@exit109.com> writes:
>
>> Perl.  It might just be beyond the capability of BSDI.
>
>Looking over the BSD/OS hint file, which I'm not sure is applicable but
>appears to be the closest, there seems to be something about dynamic
>libperl.so not supported until 3.1?
>
>I don't see any other reference to BSD problems.  You may want to send a
>problem report to perlbug@perl.org.

Actually, the BSDI hint file is incorrect, version 3.1 should be
lumped in with 3.0.  I understand that the hint file jumped the gun on
what will be supported in 4.0.  And yes, the official name of BSDI is
BSD/OS.



Brian Young
Systems Programmer
Oral Roberts University

Re: Size of INN binaries with perl?
#24863
Author: Jeremy
Date: Sun, 04 Jan 1998 00:00
19 lines
1186 bytes
Russ Allbery  <rra@stanford.edu> wrote:

>> I thought this sounded like a good idea, so I tried to build a shared
>> Perl, and it fails.  The make *segfaults*.  Consistently.  Anyone done
>> this on BSDI 3.0?  All I did was tell it to go shared, everything else
>> in configure was the same.
> 
> The make of perl or the make of INN?

Perl.

It might just be beyond the capability of BSDI.

-- 
Jeremy  |  jeremy@exit109.com
"Bunch of savages in this town!"  --Dante ("Clerks")

Re: Size of INN binaries with perl?
#24865
Author: Ollivier Robert
Date: Mon, 05 Jan 1998 00:00
26 lines
1794 bytes
    [courtesy cc of this posting sent to cited author via email]

In article <m37m8ida8b.fsf@windlord.Stanford.EDU>,
Russ Allbery  <rra@stanford.edu> wrote:
> As for stability, the problem is that upgrading Perl will blow away your
> libperl.so and anything linked against it probably won't work with the new
> version of Perl until you recompile it, unless you include the Perl
> version number in libperl.so (which is a bit tricky to do in the build
> process).  Not a major problem; just be careful when upgrading Perl and
> recompile INN too.

If you're installing Perl as the documentation says, you won't blow your
INN because the shared lib is supposed to be in

$perl/$arch/$version/CORE 

(that's /usr/local/lib/perl5/i386-freebsd/5.00404/CORE here)

That way, it you upgrade to 5.004_05, INN will still be referencing your
old "libperl.so" (unless you don't keep old versions around of course).
-- 
Ollivier ROBERT  -=- FreeBSD: The Power to Serve! -=-  roberto@freebsd.org
Usenet Canal Historique

Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads