Subject: Re: distcc and pkgsrc
To: NetBSD Help <netbsd-help@netbsd.org>
From: wrzymski <wrzymski@gmail.com>
List: netbsd-help
Date: 02/04/2006 00:01:03
2006/2/3, Jarmo Jaakkola <jarmo.jaakkola@tut.fi>:
> Hi!
> First let me explain the setup I have this far:
>   - three computers: host1 800 MHz, host2 433MHz and host3 233MHz.
>   - all disks are local on host1.  host2 and host3 boot over network
>     and use NFS.
>   - host1 has the following in /etc/mk.conf
>         MAKEFLAGS=3D-j6
>         PKGSRC_COMPILER=3Ddistcc gcc
>     and the following is set in the environment:
>         DISTCC_HOSTS=3Dlocalhost host2 host3
>   - all hosts are running distccd (also host1 just in case I'd someday
>     like to build on host2 or host3)

Your configuration looks fine for me. You could try also installing
ccache then change PKGSRC_COMPILER=3Dccache distcc gcc

> I also tried to build slrn and couple of times it seemed to get
> stuck somewhere before it even got to compiling and once it compiled
> all right, but stuck looping the question for root password ("becoming
> root for install.. interrupted by signal 22" or something), never
> showing the password prompt.

For installing packages you need to become root first. There is no way
to "ask" you during this stage. Next time become root first (not
recomended) or issue "make" from normal user account then su for make
install/package stage.

> x11/xsnow managed to compile and install OK but as was with all the
> others, distcc seemed to bring no additional speed-up.

With such configuration you can't expect almost any boost with typical
c programs.

> For what I have witnessed, distcc never contacts any other hosts than
> the first one in DISTCC_HOSTS, at least for those three example
> packages I have tried.

You can watch distcc work by running distccmon-text or by installing
gtk version from pkgsrc. With your configuration you need to start it
at 'localhost' from user that makes compilation.

#wrz#