Web站点性能拨测脚本

#!/usr/bin/env bash #=============================================================================== # # FILE: get_site_status.sh # # USAGE: ./get_site_status.sh <url> # # DESCRIPTION: 使用curl检测url,输出相关指标 # # OPTIONS: --- # REQUIREMENTS: --- # BUGS: --- # NOTES: --- # ORGANIZATION: BlueKing # CREATED: 02/15/2017 16:25 # REVISION: --- #=============================================================================== if [[ -z "$1" ]]; then echo "$0<url>" exit 1 fi echo & [阅读全文]

ansible学习

安装 apt-get install <a href="http://yw8.tech/tag/ansible/" title="查看与 ansible 相关的文章" target="_blank">ansible</a> sshpass -y 批量互信 vi wywip.txt a=`cat /root/wywip.txt` echo $a ssh-keygen -t dsa -f /root/.ssh/id_dsa -N "" for ip in $a; do sshpass -p "weiwei" ssh-copy-id -i /root/.ssh/id_dsa.pub root@$ip -o StrictHostKeyChecking=no ; done 测 [阅读全文]

centos初始化脚本

[root@k8snode03 ~]# cat init_centos.sh #!/bin/bash #检测是否为root用户 if [ $UID -ne 0 ];then echo "Must be root can do this." exit 9 fi #检测网络 echo "检测网络中......" /bin/ping www.baidu.com -c 2 &>/dev/null if [ $? -ne 0 ];then echo "现在网络无 [阅读全文]

centos的基础镜像

在198上,解决中文乱码和程序时区的问题 root@rancher01:~/centos7<a href="http://yw8.tech/tag/docker/" title="查看与 docker 相关的文章" target="_blank">docker</a># cat Dockerfile # Docker file for date and locale set # VERSION 0.0.3 #基础镜像 FROM centos:7 #定 [阅读全文]

cloudboot安装

首先最小化安装centos 6及以上版本系统(64位),本此安装为centos 6.8 /sbin/service firewalld stop /sbin/chkconfig firewalld off /usr/bin/sed -i “/SELINUX/s/enforcing/disabled/” /etc/selinux/config /usr/sbin/setenforce 0 cat /etc/selinux/config /usr/bin/sed -i “s/#UseDNS yes/UseDNS no/g” /etc/ssh/sshd_config cat /etc/ssh/sshd_config |grep DNS /usr/bin/sed -i “s/^GSSAPI/#&/g” /etc/ssh/sshd_config /usr/bin/sed -i “s/^#TCPKeepAlive/TCPKeepAlive/g” [阅读全文]

cronsun 是一个分布式任务系统

cronsun 是一个分布式任务系统,单个结点和 *nix 机器上的 crontab 近似。支持界面管理机器上的任务,支持任务失败邮件提醒,安装简单,使用方便,是替换 crontab 一个不错的选 [阅读全文]

dns服务器配置

dns服务器配置 https://www.cnblogs.com/heiye123/articles/7687922.html [root@ecs-2fee ~]# cat /etc/named.conf // // named.conf // // Provided by Red Hat bind package to configure the ISC BIND named(8) DNS // server as a caching only nameserver (as a localhost DNS resolver only). // // See /usr/share/doc/bind*/sample/ for example named configuration files. // // See the BIND Administrator's Reference Manual (ARM) for details about the // configuration located in [阅读全文]

docker安装ELK和一些注意事项

环境介绍 Centos 7.2 + Docker 17.09.0-ce + Elasticsearch 5.6.3 + elasticsearch-head 5 拉取镜像 docker pull docker.elastic.co/elasticsearch/elasticsearch:5.6.3 docker pull mobz/elasticsearch-head:5 配置文件 elsasticsearch es1.yml cluster.name: “dali” node.name: node1 node.master: true node.data: true head插件设置 http.cors.enabled: true http.cors.allow-origin: “*” 关闭X-Pack xpack.security.enabled: false network.host: 0.0.0.0 discovery.zen.minimum_master_nodes: 1 es2.yml cluster.name: “dali” node.name: node2 [阅读全文]

docker安装zabbix

安装数据库 Zabbix Java gateway zabbix server zabbix-web 安装zabbix-agent 修改zabbix图形界面中文乱码 目录 zabbix-server 部署阶段 要用docker跑zabbix-server [阅读全文]

docker磁盘空间清理

清理日志脚本 #!/bin/sh echo “==================== start clean docker containers logs ==========================” logs=$(find /var/lib/docker/containers/ -name *-json.log) for log in $logs do echo “clean logs : $log” cat /dev/null > $log done echo “==================== end clean docker containers logs ==========================” 我们在使用docker的过程中发现基于swarm使用St [阅读全文]