lab-bill-common-supcon-davidey

每一个集成环境都缺不了一个中控服务器我们这里姑且叫它操控服务器(supcon)吧,今天介绍一下,该lab-bill-davidey清单里的公共服务(common)模块supcon服务器。

工程化平台就是在这里,ssh免密码登录集成环境的所有主机,这里存放所以的管理脚本。

ssh免密码配置如下:

sudo service sshd start

sudo chkconfig sshd on

vi /etc/ssh/ssh_config

StrictHostKeyChecking no

sudo service sshd restart

ssh-keygen -t ras

ssh-copy-id slave1

ssh [email protected]

configuration is successful!

#!/bin/sh

ssh-keygen -t rsa -P ‘‘ -f ~/.ssh/id_rsa

cp ~/.ssh/id_rsa.pub ~/.ssh/authorized_keys

ssh-keygen一般来说需要输入passphrase,但是一般都是三个回车过去了,我懒的输入,加上-P ‘‘就不用了。

add public key

#!/bin/sh

read -p "please input your IP: "ip

ssh-copy-id -o StrictHostKeyChecking=no -i~/.ssh/id_rsa.pub [email protected]$ip

ssh [email protected]$ip ‘sed -i"s/^#RSAAuthentication\ yes/RSAAuthentication\ yes/g"/etc/ssh/sshd_config‘

ssh [email protected]$ip ‘sed -i"s/^#PubkeyAuthentication\ yes/PubkeyAuthentication yes/g"/etc/ssh/sshd_config‘

ssh [email protected]$ip ‘sed -i"s/^#PermitRootLogin\ yes/PermitRootLogin\ yes/g"/etc/ssh/sshd_config‘

ssh [email protected]$ip ‘service sshd restart‘

hostname=`ssh [email protected]${ip} ‘hostname‘`

echo "add the hostname to local/etc/hosts"

echo "$ip    $hostname" >> /etc/hosts

echo "please check /etc/hosts"

echo "ok"

copy to others

#!/bin/sh

cat /etc/hosts | while read LINE

do

ip=`echo $LINE | awk ‘{print $1}‘ | grep -v "::" | grep -v"127.0.0.1"`

echo "Copying /etc/hosts to ${ip}"

scp -o StrictHostKeyChecking=no /etc/hosts [email protected]${ip}:/etc/

done

很晚完成才文档,尽管每一天工作强度很大,还是愿意与大家一起进步。呵呵每天进步一点。

后续介绍其他模块,有什么问题敬请大家不要吝啬指出,一同改进。欢迎大家和大家的技术发烧友一起加入我们的qq群262407268,共建我们的《云络智慧城市》

时间: 2024-10-15 13:06:17

lab-bill-common-supcon-davidey的相关文章

C# 反射/映射学习

反射其实就是为了能够在程序运行期间动态的加载一个外部的DLL集合,然后通过某种办法找到这个DLL集合中的某个空间下的某个类的某个成员(通过反射可以访问该类所包含的所有成员,不论成员是公有还是私有) 1.运用反射调用其它程序集中的方法:     假设另一个工程中的所有类都编译到一个dll文件中了,在这很多的类当中,有一个类叫StringUtil,名称空间在HSMP.CommonBasic.Common 代码如下 : namespace lab.CommonBasic.Common { class

MIT OS lab Makefile 分析

lab1 中的Makefile主要是根目录下的GNUMakefile, kern/Makefrag, boot/Makefrag, 后两者通过include直接包含到GNUMakefile中. 1 # 2 # This makefile system follows the structuring conventions 3 # recommended by Peter Miller in his excellent paper: 4 # 5 # Recursive Make Considere

Unity 5.4大赞:HTC Vive经典The lab渲染器开源

HTC Vive提供了一个不错的免费VR demo,最近1周仔细体验了一番. 仔细看了其安装文件,竟然是Unity 5.4beta版本(通过查log,知道Valve公司用的是最新的5.4.0b11版本开发的),的确令人信心大振: 要知道,某些创业公司为了打差异化竞争,提高技术门槛,对外称Unreal 4的画质比Unity 5优秀很多,这让很多在Unity技术栈下的公司有些郁闷–多年来Unity画质始终不如Unreal逼格高啊. The Lab 程序路径:Steam\steamapps\commo

嵌入式LAB 1:启动

嵌入式系统Lab 1 启动 1. 画出你所实际实施的连接示意图 2.给出实际拍摄的板卡连接照片 3.给出所用的器材的列表 pcduino(含电源).USB串口线.网线.SD卡.无线网卡 显示屏.鼠标.键盘.支持L2TP路由器.MacBook Air 4.给出得到的pcDuino启动时的输出文字,并逐行解释 U-Boot 2009.08 (Dec 25 2014 - 21:37:33) # U-Boot: Universal Boot Loader, 负责嵌入式 Linux 系统的引导 CPU:

Watch out for these 10 common pitfalls of experienced Java developers & architects--转

原文地址:http://zeroturnaround.com/rebellabs/watch-out-for-these-10-common-pitfalls-of-experienced-java-developers-architects/ Can we start by asking a serious question? How easy is it to find advice for novice Java programmers on the web? Whenever I loo

10 Common Problems Causing Group Policy To Not Apply

10 Common Problems Causing Group Policy To Not Apply Group Policy is a solid tool and is very stable. Microsoft has made constant improvements to it since Windows 2000. It allows for the configuration and deployment of pretty much anything in your Ac

内容为王 - 比尔盖茨 content is king – Bill Gates (1/3/1996)

CONTENT IS KING – BILL GATES (1/3/1996) Content is where I expect much of the real money will be made on the Internet, just as it was in broadcasting. The television revolution that began half a century ago spawned a number of industries, including t

Lab 6-1

LABS The goal of the labs for this chapter is to help you to understand the overall functionality of a program by analyzing code constructs. Each lab will guide you through discovering and analyzing a new code construct. Each lab builds on the previo

Lab 7-3

For this lab, we obtained the malicious executable, Lab07-03.exe, and DLL, Lab07-03.dll, prior to executing. This is important to note because the malware might change once it runs. Both files were found in the same directory on the victim machine. I

CSC 115 - Lab#6 Stacks

CSC 115 - Lab#6 StacksObjectivesDuring Lab#6, week, you will be completing a programming exercise that you will hand inthrough conneX. You will learn: How to implement common operations related to Stacks based on a singly-linked list. How to solve a