dmucs与distcc
ruanyuan.net/forum.php?mod=post&action=newthread&fid=41
服务器执行:
/etc/default/distcc,设置如下配置项:
STARTDISTCC="true" ALLOWEDNETS="127.0.0.1 192.168.1.0/24"LISTENER="0.0.0.0"
/etc/default/dmucs
yes
/etc/dmucs.conf
# Format: machine number-of-cpus power-index
10.239.65.187 20 20
10.239.82.105 8 8
service distcc start
service dmucs start
loadavg -s 服务器ip &(发送本机负荷的程序)
Error 1:
dmucs Could not open server on port 9714.
Error 2:
sudo service dmucs restart
* Restarting dmucs distcc coordinator dmucs
...done.
* Restarting dmucs client daemon loadavg
No /usr/sbin/dmucs found running; none killed.
客户端执行:
/etc/default/distcc,设置如下配置项:
STARTDISTCC="true" ALLOWEDNETS="127.0.0.1 192.168.1.0/24"LISTENER="0.0.0.0"
/etc/default/dmucs
USE_SERVER=10.239.82.105
~/.bashrc
export DISTCC_HOSTS="192.168.1.11 192.168.1.22 192.168.1.33"
service distcc start
loadavg -s 服务器ip &(发送本机负荷的程序)
distccmon-text 1
Using DistCC to speed up compilation
http://pointclouds.org/documentation/advanced/distcc.php
wget http://download.redis.io/releases/redis-3.0.5.tar.gz
make
CONFIGURE
--CXX="ethost distcc g++" ./configure
Makefile
CXX = g++ 改为 CXX = gethost distcc g++
make -j8 CC=distcc CXX=distcc
5.运行
服务端运行
export PATH=$PATH:服务端distcc程序路径:服务器编译工具路径
distcc --deamon --allow 192.168.0.0/16
客户端运行 :
export PATH=$PATH:客户端distcc程序路径:客户端编译工具路径
export DISTCC_HOSTS="server_ip1 server_ip2 ..."
make -j8 CC=distcc
启动监控:distccd --daemon --allow 10.20.0.0/16
查看监控:distccmon-text 1
使用distcc搭建分布式编译环境
http://blog.chinaunix.net/uid-22315114-id-99967.html
$ distccmon-text
29291 Preprocess probe_64.c 192.168.0.2[0]
30954 Compile apic_noop.c 192.168.0.2[0]
30932 Preprocess kfifo.c 192.168.0.2[0]
30919 Compile blk-core.c 192.168.0.2[1]
30969 Compile i915_gem_debug.c 192.168.0.2[3]
30444 Compile block_dev.c 192.168.0.3[1]
30904 Compile compat.c 192.168.0.3[2]
30891 Compile hugetlb.c 192.168.0.3[3]
30458 Compile catalog.c 192.168.0.4[0]
30496 Compile ulpqueue.c 192.168.0.4[2]
30506 Compile alloc.c 192.168.0.4[0]