在ubuntu16.04编译安装httperf

时间:2023-03-09 15:38:39
在ubuntu16.04编译安装httperf

在网上偶尔看到httperf可以在测试中使用。网上苦苦找不到ubuntu编译安装的方法。自己琢磨了一下,现在总结如下:

apt install httperf
vim /etc/security/limits.conf
* hard nofile
* soft nofile
root hard nofile
root soft nofile vim /usr/include/x86_64-linux-gnu/bits/typesizes.h
/* Number of descriptors that can fit in an `fd_set'. */
#define __FD_SETSIZE 1024
改为
#define __FD_SETSIZE 65532 apt install libtool-bin libssl-dev openssl automake libevent-dev autoconf autotools-dev m4 libtoolize
autoreconf -i
aclocal
autoconf
autoheader
automake --add-missing ./configure
make
make install ln /usr/local/bin/httperf httperf

经过以上编译配置,程序就可以运行了。

在ubuntu16.04编译安装httperf

测试效果:

在ubuntu16.04编译安装httperf

参考:

https://poscotso.wordpress.com/2014/09/09/installing-httperf-on-ubuntu/

https://blog.csdn.net/babybirdtofly/article/details/69941756

https://gist.github.com/UKNC/0de259b8a1c9f93f231d89b0ac230ece