
linux 环境 shell
紫气迷城
这个作者很懒,什么都没留下…
展开
-
log4rc
## log4rclog proxy for http and https remote call.http / https 的通用代理服务,记录详细的请求及返回日志。主要为了解决系统中调用http请求时需要留存原始日志的场景,基本可以0成本添加所有请求的完整日志。可以在Release 中直接下载可执行程序部署运行## help```log4rc -hUsage of log4rc:-addr stringhost:port...原创 2020-08-11 13:57:55 · 205 阅读 · 0 评论 -
支持高并发的配置优化
支持高并发的配置优化优化系统内核timewait 的数量,默认是180000。但是多了会影响处理速度,少了无法最大化利用系统性能net.ipv4.tcp_max_tw_buckets = 20000允许系统打开的端口范围。不设置的话在高并发的情况下有可能把服务器的端口都占满,那就彻底爆炸了net.ipv4.ip_local_port_range = 10000 65000启转载 2016-11-28 17:32:40 · 925 阅读 · 0 评论 -
添加https证书信任
--------------- Centos 导入https 证书 -------------------Add Install the ca-certificates package:¶yum install ca-certificatesEnable the dynamic CA configuration feature:update-ca-trust ena转载 2015-01-23 11:32:42 · 3306 阅读 · 0 评论 -
centos 添加CA 证书
centos---Install the ca-certificates package:yum install ca-certificatesEnable the dynamic CA configuration feature:update-ca-trust enableAdd it as a new file to /etc/pki/ca-trust/转载 2015-01-07 15:22:16 · 14291 阅读 · 0 评论 -
apache, httpd 启动失败
报错信息: [Wed Mar 11 15:57:46 2009] [crit] (28)No space left on device: mod_rewrite: could not create rewrite_log_lockConfiguration Failed[Wed Mar 11 15:59:22 2009] [notice] suEXEC mechanism ena转载 2014-04-02 12:01:27 · 1317 阅读 · 0 评论 -
centos out of memory
1) Configuring OOM killer: The values in overcommit_memory mean0-Heuristic memory overcommit (default setting)1-Always overcommit2-Disable overcommitWhen overcommit_memory is set to 2转载 2013-12-11 11:04:22 · 1599 阅读 · 0 评论 -
makefile
不会写Makefile 不可怕,会用就好了CXX=g++ -gINC+= -I./ -I../common/ -I../include/LIB=-lpthread -L../lib -lullibSTATER_TARGET=stater.exeALL = $(STATER_TARGET)STATER_OBJ = stater.o main.o conf.o \原创 2013-09-24 17:43:49 · 599 阅读 · 0 评论 -
Centos 安装 atomic 源
Atomic源支持Fedora,RHEL和CentOS的YUM包管理。这里系统是CentOS6.2。安装方法很简单:wget -q -O - http://www.atomicorp.com/installers/atomic | sh安装完后在/etc/yum.repos.d/目录会有一个atomic.repo文件。Atomic仓库支持哪些软件可以到这个地址查看:转载 2013-08-13 17:34:34 · 2712 阅读 · 0 评论 -
Apache、Nginx、Lighttpd对比
Apache* 经典的Web服务器* 除了慢没有别的缺点了* 对了,Apache2对fcgi支持并不好* 非常好用的proxy和proxy_ajp(很多人用它作为tomcat的前端)* 不支持epoll(这年头,epoll几乎是性能的必备)Nginx* 速度快,占用资源少* 杀手级的proxy和rewrite* 非常不错的静态转载 2013-08-13 14:01:27 · 667 阅读 · 0 评论 -
负载平衡 选择 对比
现在网络中常见的的负载均衡主要分为两种:一种是通过硬件来进行进行,常见的硬件有比较昂贵的NetScaler、F5、Radware和Array等商用的负载均衡器,也有类似于LVS、Nginx、HAproxy的基于Linux的开源的负载均衡策略,商用负载均衡里面NetScaler从效果上比F5的效率上更高。对于负载均衡器来说,不过商用负载均衡由于可以建立在四~七层协议之上,因此适用 面更广所以转载 2013-08-13 13:46:37 · 661 阅读 · 0 评论 -
lighttpd流量监控(mod_rrdtool)
lighttpd中带了一个监控模块,可以监控lighttpd服务器的流量。1. 确保安装lighttpd的时候,带了rrdtool模块,如果没有,手动安装参考 这里2. 在/etc/lighttpd/lighttpd.conf中,激活mod_rrdtool模块,并添加以下代码: rrdtool.binary = "/usr/bin/rrdtool" rrdtool.db-n原创 2013-03-06 14:58:14 · 868 阅读 · 0 评论 -
scp ssh 密码
两台机器间的scp, ssh ...... 操作不输入密码 的解决方案方案1:使用机器间信任有资料[1]介绍在两台机器的两个用户之间建立安全的信任关系后,可实现执行scp命令时不需要输入用户密码。我根据该资料介绍的方法测试成功了。 以下是在机器Client的root和机器Server的root之间建立安全信任关系的步骤: 1. 在机器Client上root用户执行ssh转载 2012-09-26 15:45:01 · 698 阅读 · 0 评论 -
yum install rrdtool
RRDTOOL is required by many network utilities, e.g cacti, nagios & many others to plot graphs.By default rrdtool is not included in CentOS. You may need to install it for monitoring purpose. You can原创 2013-03-06 14:09:54 · 838 阅读 · 0 评论 -
使 shell 脚本在关键语句出错时终止执行
转自: 某 个人文章function _do(){ "$@" || { alert "exec failed: ""$@"; exit -1; }}function _do_ex(){ eval "$1" || { alert "exec failed: ""$1"; exit -1; }}_do_ex "statementA | sta转载 2013-03-05 14:15:30 · 1928 阅读 · 0 评论 -
linux centos 端口开关
1、设定[root@localhost ~]# /sbin/iptables -I INPUT -p tcp --dport 80 -j ACCEPT[root@localhost ~]# /sbin/iptables -I INPUT -p tcp --dport 22 -j ACCEPT[root@localhost ~]# /sbin/iptables -I INPU转载 2012-10-30 09:56:48 · 505 阅读 · 0 评论 -
centos,linux,mysql,php,lighttpd手动安装
依赖文件 可以选择性安装 yum install ntp vim-enhanced gcc gcc-c++ gcc-g77 flex bison autoconf automake bzip2-devel ncurses-devel zlib-devel libjpeg-devel libpng-devel libtiff-devel freetype-devel libXpm-devel原创 2012-10-18 22:18:28 · 623 阅读 · 0 评论 -
mysql build and setup on linux
Download MySQL Source Code from http://dev.mysql.com/downloads/shell> groupadd mysqlshell> useradd -g mysql mysqlshell> gunzip shell> cd mysql-VERSIONshell> ./configure --prefix=/usr/local原创 2012-08-29 17:46:04 · 574 阅读 · 0 评论