网卡配置linux centos&ubuntu(生产环境)

root@app53:~$ip route default via 17.2.32.1 dev eth1 17.2.32.0/24 dev eth1 proto kernel scope link src 17.2.32.199 10.4.30.0/23 dev eth0 proto kernel scope link src 10.4.30.54 10.4.33.0/24 via 10.4.30.254 dev eth0 17.22.0.0/16 via 10.4.30.254 dev eth0 169.254.0.0/16 dev eth0 scope link metric 1002 169.254.0.0/16 dev eth1 scope link metric 1003 root@app53:~$cat /etc/sysconfig/network-scripts/ifcfg- ifcfg-eth0 ifcfg-eth1 ifcfg-lo root@app53:~$cat /etc/sysconfig/network-scripts/ifcfg-eth0 NM_CONTROLLED=no IPV6INIT=no DEVICE="eth0" ONBOOT="yes" BOOTPROTO="none" #DNS1=10.0.2.1 IPADDR=10.4.30.54 PREFIX=23 root@app53:~$cat /etc/sysconfig/network-scripts/ifcfg-eth1 NM_CONTROLLED=no IPV6INIT=no DEVICE="eth1" ONBOOT="yes" [阅读全文]

脚本一键批量分发公钥ssh远程批量管理服务

#!/bin/bash #ssh批量分发脚本,以及检测分发情况 #172.16.1.5 lb01 #172.16.1.6 lb02 #172.16.1.7 web01 #172.16.1.8 web02 #172.16.1.9 web03 #172.16.1.51 db01 #172.16.1.31 nfs01 #172.16.1.41 backup #172.16.1.61 m01 #172.16.1.62 jumpserver #判断脚本后面是否接参数了 #试验环境清空~/.ssh/文件夹 [阅读全文]

获取exsi信息统计

通过连接vcenter 管理服务器,获取其下所有的:存储,网络,ESXI实体机,虚拟机相关信息的脚本: pip3 install pyVmomi python3 esxi.py -s 10.41.2.2 -uadministrator@vsphere.local -p 1qSX >esxi.txt #!/opt/python3/bin/python3 #Author: zhaoyong """ 只用于模拟 [阅读全文]

蓝鲸CMDB自动发现–手工部署agent

#!/bin/sh ip=`ifconfig | grep "inet addr" | grep Bcast |grep -v '172.'| awk -F '[ :]+' '{print $4}'` echo '10.4.31.165 cmdb.xikang365.net' >> /etc/hosts [ -d /tmp/agents ] || mkdir -p /tmp/agents LC_ALL=C ls -rtlh --color=never LC_ALL=C rm -f /tmp/agents/agent_setup_pro.sh LC_ALL=C curl -o /tmp/agents/agent_setup_pro.sh http://10.4.31.165:80/download/agent_setup_pro.sh chmod a+x /tmp/agents/agent_setup_pro.sh LC_ALL=C /tmp/agents/agent_setup_pro.sh -m client -g 10.4.31.165:80 sleep 10 curl -s -X POST -H 'cache-control: no-cache' -H 'content-type: application/x-www-form-urlencoded' -H 'BK_USER: admin' -H 'HTTP_BLUEKING_SUPPLIER_ID: [阅读全文]

蓝鲸运维磁盘满处理

mysql\kafka比较占用空间,满了cmdb打不开 du -sk *|sort -n|cut -f2|xargs -d ‘\n’ du -sh 到10.4.31.166节点 /data/bkce/service/mysql/bin/mysql mysql> set global expire_logs_days=2; mysql> purge binary logs to ‘mysql-bin.000162’; 各节点的kafka [阅读全文]

虚拟机根分区扩容

增加磁盘后查看磁盘信息 创建物理卷 查看物理卷信息 pvdisplay vgdisplay 将新增加的分区/dev/sdb1加入到根目录分区centos_mb-centos7中 进行卷 [阅读全文]

记gitlib搭建与pycharm连接

# 安装gitlib vim /etc/yum.repos.d/gitlab-ce.repo [gitlab-ce] name=gitlab-ce baseurl=http://mirrors.tuna.tsinghua.edu.cn/gitlab-ce/yum/el6 repo_gpgcheck=0 gpgcheck=0 enabled=1 gpgkey=https://packages.gitlab.com/gpg.key yum install curl openssh-server openssh-clients postfix cronie service postfix start chkconfig postfix on yum install gitlab-ce gitlab-ctl reconfigure cat /opt/gitlab/embedded/service/gitlab-rails/VERSION 一些命令 gitlab-ctl start gitlab-ctl reconfigure 默认用户名 admin@local.host 密码 5iveL!fe 把github的代码弄到git [阅读全文]

辽宁科技馆办公平台项目分享

辽宁科技馆办公平台项目分享 https://www.ohwyaa.com/neusoft.com/blog/732f4494-43bf-40ff-8bfa-f34b19a3ba45/view/text 1、系统架构的设计原则和方法 1.1 设计原则 根据科技馆新馆的发展理念和信息化建设需求,我们了解到新馆信息化具有难度大、 [阅读全文]