集群運(yùn)維自動(dòng)化工具ansible的安裝與使用(包括模塊與playbook使用)第1/2頁
我使用過puppet與salt,但這2個(gè)軟件都需要安裝客戶端,并且更新很快,每次更新都是令人蛋疼的事,尤其是salt,喜歡他的命令功能,但bug太多,不敢在公司線上使用,puppet雖然穩(wěn)定,但弄命令執(zhí)行的時(shí)候,需要mco配置,非常麻煩,我公司由于跟多家公司合作,很多業(yè)務(wù)沒辦法安裝客戶端,所以沒辦法使用puppet與salt(雖然salt有ssh,但不太好使),最后找到了ansible,他既有命令執(zhí)行也有配置管理,關(guān)鍵開發(fā)它的語言是python,paramiko進(jìn)行ssh連接,跟我之前開發(fā)的自動(dòng)管理軟件都是使用paramiko進(jìn)行操作,不需要安裝客戶端,滿足我的需求,下面給大家介紹一下我是如何使用的。
一、安裝
1、安裝第三方epel源
centos 5的epel
rpm -ivh http://mirrors.sohu.com/fedora-epel/5/x86_64/epel-release-5-4.noarch.rpm
centos 6的epel
rpm -ivh http://mirrors.sohu.com/fedora-epel/6/x86_64/epel-release-6-8.noarch.rpm
查看系統(tǒng)版本
17:01:30 # cat /etc/issue CentOS release 6.5 (Final) Kernel \r on an \m
由于是6版本所以安裝6的epel
2、安裝ansible
yum install ansible
如果需要自定義module或者想閱讀源碼、使用最新版本,可以去github里下載源碼
git clone https://github.com/ansible/ansible.git
3、添加主機(jī)
17:22:08 # cd /etc/ansible/ root@ip-10-10-10-10:/etc/ansible 17:23:27 # ll total 12 -rw-r--r-- 1 root root 5113 Dec 29 03:00 ansible.cfg -rw-r--r-- 1 root root 965 Dec 29 03:00 hosts 其中ansible.cfg是配置文件,hosts是管理主機(jī)信息 17:24:44 # cat hosts 172.17.0.2:49154 172.17.0.4:49155 [zabbix] 172.17.0.2:49154 172.17.0.4:49155 [vpn] 172.17.0.10
4、使用密碼登陸
ansible支持正則測試
16:20:57 # ansible 127* -m ping
SSH password:
127.0.0.1 | success >> {
"changed": false,
"ping": "pong"
}
root@ip-10-10-10-10:/etc/ansible
16:21:05 # ansible 172* -m ping
SSH password:
172.17.0.5 | success >> {
"changed": false,
"ping": "pong"
}
172.17.0.4 | success >> {
"changed": false,
"ping": "pong"
}
172.17.0.2 | success >> {
"changed": false,
"ping": "pong"
}
如果你有多臺服務(wù)器的話,想并發(fā)運(yùn)行,可以使用-f參數(shù),默認(rèn)是并發(fā)5
5、使用密鑰登陸測試
11:30:35 # ansible vpn -m shell -a "echo $TERM" -u test --private-key=denglei -K SSH password: sudo password [defaults to SSH password]: 172.17.0.10 | success | rc=0 >> xterm
二、模塊應(yīng)用
6、文件傳輸
11:30:44 # ansible vpn -m copy -a "src=/tmp/server dest=/tmp/server" -u test --private-key=denglei -K
SSH password:
sudo password [defaults to SSH password]:
172.17.0.10 | success >> {
"changed": true,
"dest": "/tmp/server",
"gid": 505,
"group": "test",
"md5sum": "e8b32bc4d7b564ac6075a1418ad8841e",
"mode": "0664",
"owner": "test",
"size": 7,
"src": "/home/test/.ansible/tmp/ansible-1402630447.45-253524136818424/source",
"state": "file",
"uid": 503
}
去客戶端查看文件是否傳輸過來
11:34:57 # ansible vpn -m shell -a "ls -l /tmp/" -u test --private-key=denglei -K SSH password: sudo password [defaults to SSH password]: 172.17.0.10 | success | rc=0 >> total 76 -rw-r--r-- 1 root root 41692 May 21 13:02 config -rw-r--r-- 1 root root 1228 Jun 12 18:24 install_pptpd_vpn.sh -rw-rw-r-- 1 test test 7 Jun 13 19:33 server -rw-r--r-- 1 root root 82 Jun 12 18:21 test.log -rw-r--r-- 1 root root 290 Jun 12 18:21 test.sh -rw-r--r-- 1 root root 2444 Apr 28 2012 vpn_centos6.sh -rw------- 1 root root 727 Jun 10 18:21 yum_save_tx-2014-06-10-18-21UrqDAp.yumtx -rw-rw-r-- 1 zabbix zabbix 3124 Jun 12 21:32 zabbix_agentd.log -rw-rw-r-- 1 zabbix zabbix 5 Jun 12 21:32 zabbix_agentd.pid
可以看到已經(jīng)傳過來了
看看文件內(nèi)容
11:35:09 # ansible vpn -m shell -a "cat /tmp/server" -u test --private-key=denglei -K SSH password: sudo password [defaults to SSH password]: 172.17.0.10 | success | rc=0 >> server
內(nèi)容正常
還有另外一個(gè)模塊file,可以修改用戶與權(quán)限
下面是當(dāng)前文件狀態(tài)
13:50:07 # ansible vpn -m shell -a "ls -l /tmp/server" -u test --private-key=denglei -K SSH password: sudo password [defaults to SSH password]: 172.17.0.10 | success | rc=0 >> -rw-rw-r-- 1 test test 7 Jun 13 19:33 /tmp/server
server文件是664權(quán)限,用戶與組都是test
修改一下
13:51:17 # ansible vpn -m file -a "dest=/tmp/server mode=755 owner=root group=root" -u test --private-key=denglei -K
SSH password:
sudo password [defaults to SSH password]:
172.17.0.10 | success >> {
"changed": true,
"gid": 0,
"group": "root",
"mode": "0755",
"owner": "root",
"path": "/tmp/server",
"size": 7,
"state": "file",
"uid": 0
}
root@ip-10-10-10-10:/etc/ansible
13:51:31 # ansible vpn -m shell -a "ls -l /tmp/server" -u test --private-key=denglei -K
SSH password:
sudo password [defaults to SSH password]:
172.17.0.10 | success | rc=0 >>
-rwxr-xr-x 1 root root 7 Jun 13 19:33 /tmp/server
7、安裝軟件
14:20:30 # ansible vpn -m yum -a "name=nmap state=installed" -u test --private-key=denglei -K
SSH password:
sudo password [defaults to SSH password]:
172.17.0.10 | success >> {
"changed": true,
"msg": "",
"rc": 0,
"results": [
"Loaded plugins: fastestmirror, security\nLoading mirror speeds from cached hostfile\n * epel: mirrors.hust.edu.cn\nSetting up Install Process\nResolving Dependencies\n--> Running transaction check\n---> Package nmap.x86_64 2:5.51-3.el6 will be installed\n--> Finished Dependency Resolution\n\nDependencies Resolved\n\n================================================================================\n Package Arch Version Repository Size\n================================================================================\nInstalling:\n nmap x86_64 2:5.51-3.el6 Base 2.7 M\n\nTransaction Summary\n================================================================================\nInstall 1 Package(s)\n\nTotal download size: 2.7 M\nInstalled size: 9.7 M\nDownloading Packages:\nRunning rpm_check_debug\nRunning Transaction Test\nTransaction Test Succeeded\nRunning Transaction\n\r Installing : 2:nmap-5.51-3.el6.x86_64 1/1 \n\r Verifying : 2:nmap-5.51-3.el6.x86_64 1/1 \n\nInstalled:\n nmap.x86_64 2:5.51-3.el6 \n\nComplete!\n"
]
}
三、playbook配置管理
8、playbook
A.進(jìn)行一下shell模塊操作,測試刪除文件
先查看一下客戶端的server-test是否存在
[root@puppet ansible]# ansible vpn -m shell -a "ls -l /tmp/server-test" -u test --private-key=/root/denglei -k SSH password: 172.17.0.10 | success | rc=0 >> -rw-rw-r-- 1 test test 7 Jun 14 00:37 /tmp/server-test
可以看到是存在的
然后寫一個(gè)刪除的playbook
[root@puppet ansible]# cat test.yml --- - hosts: vpn remote_user: test tasks: - name: delete /tmp/server-test shell: rm -rf /tmp/server-test
運(yùn)行
[root@puppet ansible]# ansible-playbook test.yml --private-key=/root/denglei -k [WARNING]: The version of gmp you have installed has a known issue regarding timing vulnerabilities when used with pycrypto. If possible, you should update it (ie. yum update gmp). SSH password: PLAY [vpn] ******************************************************************** GATHERING FACTS *************************************************************** ok: [172.17.0.10] TASK: [delete /tmp/server-test] *********************************************** changed: [172.17.0.10] PLAY RECAP ******************************************************************** 172.17.0.10 : ok=2 changed=1 unreachable=0 failed=0
在查看
[root@puppet ansible]# ansible vpn -m shell -a "ls -l /tmp/server-test" -u test --private-key=/root/denglei -k SSH password: 172.17.0.10 | FAILED | rc=2 >> ls: cannot access /tmp/server-test: No such file or directory
文件已經(jīng)刪除
B.進(jìn)行一下template模塊操作,測試文件傳輸
[root@puppet ansible]# cat copy.yml --- - hosts: vpn remote_user: test tasks: - name: copy local server to client /tmp/server-test template: src=/tmp/server dest=/tmp/server-test [root@puppet ansible]# ansible-playbook copy.yml --private-key=/root/denglei -k [WARNING]: The version of gmp you have installed has a known issue regarding timing vulnerabilities when used with pycrypto. If possible, you should update it (ie. yum update gmp). SSH password: PLAY [vpn] ******************************************************************** GATHERING FACTS *************************************************************** ok: [172.17.0.10] TASK: [copy local server to client /tmp/server-test] ************************** changed: [172.17.0.10] PLAY RECAP ******************************************************************** 172.17.0.10 : ok=2 changed=1 unreachable=0 failed=0 [root@puppet ansible]# ansible vpn -m shell -a "ls -l /tmp/server-test" -u test --private-key=/root/denglei -k SSH password: 172.17.0.10 | success | rc=0 >> -rw-rw-r-- 1 test test 7 Jun 14 17:07 /tmp/server-test
C.使用service模塊,測試一下服務(wù)重啟
[root@puppet ansible]# ansible vpn -m shell -a "/etc/init.d/pptpd stop" -u test --private-key=/root/denglei -k -K -s SSH password: sudo password [defaults to SSH password]: 172.17.0.10 | success | rc=0 >> Shutting down pptpd: [ OK ] [root@puppet ansible]# ansible vpn -m shell -a "/etc/init.d/pptpd stop" -u test --private-key=/root/denglei -k -K -s SSH password: sudo password [defaults to SSH password]: 172.17.0.10 | success | rc=0 >> Shutting down pptpd: [ OK ]
D.多項(xiàng)目同時(shí)更新
[root@puppet ansible]# ansible vpn -m shell -a "ls -l /tmp/" -u test --private-key=/root/denglei -k
SSH password:
172.17.0.10 | success | rc=0 >>
total 84
-rw-r--r-- 1 root root 41692 May 21 13:02 config
-rw-r--r-- 1 root root 1228 Jun 12 18:24 install_pptpd_vpn.sh
-rwxr-xr-x 1 root root 7 Jun 13 19:33 server
-rw-rw-r-- 1 test test 7 Jun 14 17:07 server-test
-rw-r--r-- 1 root root 82 Jun 12 18:21 test.log
-rw-r--r-- 1 root root 290 Jun 12 18:21 test.sh
-rw-r--r-- 1 root root 2444 Apr 28 2012 vpn_centos6.sh
-rw------- 1 root root 727 Jun 10 18:21 yum_save_tx-2014-06-10-18-21UrqDAp.yumtx
-rw-rw-r-- 1 zabbix zabbix 4664 Jun 14 00:30 zabbix_agentd.log
-rw-rw-r-- 1 zabbix zabbix 5 Jun 14 00:30 zabbix_agentd.pid
[root@puppet ansible]# vim multi_copy.yml
[root@puppet ansible]# cat multi_copy.yml
---
- hosts: vpn
remote_user: test
gather_facts: False
tasks:
- name: copy local server to client /tmp/server-test
template: src=/tmp/server dest=/tmp/test-{{item}}
with_items:
- server-1
- server-2
- server-3
[root@puppet ansible]# ansible-playbook multi_copy.yml --private-key=/root/denglei -k
[WARNING]: The version of gmp you have installed has a known issue regarding
timing vulnerabilities when used with pycrypto. If possible, you should update
it (ie. yum update gmp).
SSH password:
PLAY [vpn] ********************************************************************
TASK: [copy local server to client /tmp/server-test] **************************
changed: [172.17.0.10] => (item=server-1)
changed: [172.17.0.10] => (item=server-2)
changed: [172.17.0.10] => (item=server-3)
PLAY RECAP ********************************************************************
172.17.0.10 : ok=1 changed=1 unreachable=0 failed=0
[root@puppet ansible]# ansible vpn -m shell -a "ls -l /tmp/" -u test --private-key=/root/denglei -k
SSH password:
172.17.0.10 | success | rc=0 >>
total 96
-rw-r--r-- 1 root root 41692 May 21 13:02 config
-rw-r--r-- 1 root root 1228 Jun 12 18:24 install_pptpd_vpn.sh
-rwxr-xr-x 1 root root 7 Jun 13 19:33 server
-rw-rw-r-- 1 test test 7 Jun 14 17:07 server-test
-rw-rw-r-- 1 test test 7 Jun 18 00:50 test-server-1
-rw-rw-r-- 1 test test 7 Jun 18 00:50 test-server-2
-rw-rw-r-- 1 test test 7 Jun 18 00:50 test-server-3
-rw-r--r-- 1 root root 82 Jun 12 18:21 test.log
-rw-r--r-- 1 root root 290 Jun 12 18:21 test.sh
-rw-r--r-- 1 root root 2444 Apr 28 2012 vpn_centos6.sh
-rw------- 1 root root 727 Jun 10 18:21 yum_save_tx-2014-06-10-18-21UrqDAp.yumtx
-rw-rw-r-- 1 zabbix zabbix 4664 Jun 14 00:30 zabbix_agentd.log
-rw-rw-r-- 1 zabbix zabbix 5 Jun 14 00:30 zabbix_agentd.pid
E.根據(jù)條件進(jìn)行刪除
[root@puppet ansible]# ansible vpn -m shell -a "ls -l /tmp/" -u test --private-key=/root/denglei -k SSH password: 172.17.0.10 | success | rc=0 >> total 96 -rw-r--r-- 1 root root 41692 May 21 13:02 config -rw-r--r-- 1 root root 1228 Jun 12 18:24 install_pptpd_vpn.sh -rwxr-xr-x 1 root root 7 Jun 13 19:33 server -rw-rw-r-- 1 test test 7 Jun 14 17:07 server-test -rw-rw-r-- 1 test test 7 Jun 18 00:50 test-server-1 -rw-rw-r-- 1 test test 7 Jun 18 00:50 test-server-2 -rw-rw-r-- 1 test test 7 Jun 18 00:50 test-server-3 -rw-r--r-- 1 root root 82 Jun 12 18:21 test.log -rw-r--r-- 1 root root 290 Jun 12 18:21 test.sh -rw-r--r-- 1 root root 2444 Apr 28 2012 vpn_centos6.sh -rw------- 1 root root 727 Jun 10 18:21 yum_save_tx-2014-06-10-18-21UrqDAp.yumtx -rw-rw-r-- 1 zabbix zabbix 4664 Jun 14 00:30 zabbix_agentd.log -rw-rw-r-- 1 zabbix zabbix 5 Jun 14 00:30 zabbix_agentd.pid [root@puppet ansible]# cat delete.yml --- - hosts: vpn remote_user: test gather_facts: True tasks: - name: if system is centos,then rm /tmp/test-server-1 shell: rm -rf /tmp/test-server-1 when: ansible_os_family == "RedHat" [root@puppet ansible]# ansible-playbook delete.yml --private-key=/root/denglei -k [WARNING]: The version of gmp you have installed has a known issue regarding timing vulnerabilities when used with pycrypto. If possible, you should update it (ie. yum update gmp). SSH password: PLAY [vpn] ******************************************************************** GATHERING FACTS *************************************************************** ok: [172.17.0.10] TASK: [if system is centos,then rm /tmp/test-server-1] ************************ changed: [172.17.0.10] PLAY RECAP ******************************************************************** 172.17.0.10 : ok=2 changed=1 unreachable=0 failed=0 [root@puppet ansible]# ansible vpn -m shell -a "ls -l /tmp/" -u test --private-key=/root/denglei -k SSH password: 172.17.0.10 | success | rc=0 >> total 92 -rw-r--r-- 1 root root 41692 May 21 13:02 config -rw-r--r-- 1 root root 1228 Jun 12 18:24 install_pptpd_vpn.sh -rwxr-xr-x 1 root root 7 Jun 13 19:33 server -rw-rw-r-- 1 test test 7 Jun 14 17:07 server-test -rw-rw-r-- 1 test test 7 Jun 18 00:50 test-server-2 -rw-rw-r-- 1 test test 7 Jun 18 00:50 test-server-3 -rw-r--r-- 1 root root 82 Jun 12 18:21 test.log -rw-r--r-- 1 root root 290 Jun 12 18:21 test.sh -rw-r--r-- 1 root root 2444 Apr 28 2012 vpn_centos6.sh -rw------- 1 root root 727 Jun 10 18:21 yum_save_tx-2014-06-10-18-21UrqDAp.yumtx -rw-rw-r-- 1 zabbix zabbix 4664 Jun 14 00:30 zabbix_agentd.log -rw-rw-r-- 1 zabbix zabbix 5 Jun 14 00:30 zabbix_agentd.pid
F.debug輸出
[root@puppet ansible]# cat debug.yml
---
- hosts: vpn
remote_user: test
gather_facts: True
tasks:
- name: debug to print interface
debug: msg="{{item}}"
with_items: ansible_default_ipv4.address
[root@puppet ansible]# ansible-playbook debug.yml --private-key=/root/denglei -k
[WARNING]: The version of gmp you have installed has a known issue regarding
timing vulnerabilities when used with pycrypto. If possible, you should update
it (ie. yum update gmp).
SSH password:
PLAY [vpn] ********************************************************************
GATHERING FACTS ***************************************************************
ok: [172.17.0.10]
TASK: [debug to print interface] **********************************************
ok: [172.17.0.10] => (item=10.10.32.34) => {
"item": "10.10.32.34",
"msg": "10.10.32.34"
}
G.check模式,僅檢測,但不實(shí)行
[root@puppet ansible]# ansible vpn -m shell -a "ls -l /tmp/" -u test --private-key=/root/denglei -k SSH password: 172.17.0.10 | success | rc=0 >> total 92 -rw-r--r-- 1 root root 41692 May 21 13:02 config -rw-r--r-- 1 root root 1228 Jun 12 18:24 install_pptpd_vpn.sh -rwxr-xr-x 1 root root 7 Jun 13 19:33 server -rw-rw-r-- 1 test test 7 Jun 14 17:07 server-test -rw-rw-r-- 1 test test 7 Jun 18 00:50 test-server-2 -rw-rw-r-- 1 test test 7 Jun 18 00:50 test-server-3 -rw-r--r-- 1 root root 82 Jun 12 18:21 test.log -rw-r--r-- 1 root root 290 Jun 12 18:21 test.sh -rw-r--r-- 1 root root 2444 Apr 28 2012 vpn_centos6.sh -rw------- 1 root root 727 Jun 10 18:21 yum_save_tx-2014-06-10-18-21UrqDAp.yumtx -rw-rw-r-- 1 zabbix zabbix 4664 Jun 14 00:30 zabbix_agentd.log -rw-rw-r-- 1 zabbix zabbix 5 Jun 14 00:30 zabbix_agentd.pid [root@puppet ansible]# ansible-playbook copy.yml --private-key=/root/denglei -k --check [WARNING]: The version of gmp you have installed has a known issue regarding timing vulnerabilities when used with pycrypto. If possible, you should update it (ie. yum update gmp). SSH password: PLAY [vpn] ******************************************************************** GATHERING FACTS *************************************************************** ok: [172.17.0.10] TASK: [copy local server to client /tmp/server-test] ************************** changed: [172.17.0.10] => (item=server-1) ok: [172.17.0.10] => (item=server-2) ok: [172.17.0.10] => (item=server-3) PLAY RECAP ******************************************************************** 172.17.0.10 : ok=2 changed=1 unreachable=0 failed=0 PLAY RECAP ******************************************************************** 172.17.0.10 : ok=2 changed=0 unreachable=0 failed=0 H.diff
使用diff與不使用作對比
[root@puppet ansible]# ansible vpn -m shell -a "rm -rf /tmp/test-server-1" -u test --private-key=/root/denglei -k SSH password: 172.17.0.10 | success | rc=0 >> [root@puppet ansible]# ansible vpn -m shell -a "ls -l /tmp/" -u test --private-key=/root/denglei -k SSH password: 172.17.0.10 | success | rc=0 >> total 92 -rw-r--r-- 1 root root 41692 May 21 13:02 config -rw-r--r-- 1 root root 1228 Jun 12 18:24 install_pptpd_vpn.sh -rwxr-xr-x 1 root root 7 Jun 13 19:33 server -rw-rw-r-- 1 test test 7 Jun 14 17:07 server-test -rw-rw-r-- 1 test test 7 Jun 18 00:50 test-server-2 -rw-rw-r-- 1 test test 7 Jun 18 00:50 test-server-3 -rw-r--r-- 1 root root 82 Jun 12 18:21 test.log -rw-r--r-- 1 root root 290 Jun 12 18:21 test.sh -rw-r--r-- 1 root root 2444 Apr 28 2012 vpn_centos6.sh -rw------- 1 root root 727 Jun 10 18:21 yum_save_tx-2014-06-10-18-21UrqDAp.yumtx -rw-rw-r-- 1 zabbix zabbix 4664 Jun 14 00:30 zabbix_agentd.log -rw-rw-r-- 1 zabbix zabbix 5 Jun 14 00:30 zabbix_agentd.pid [root@puppet ansible]# ansible-playbook copy.yml --private-key=/root/denglei -k --diff [WARNING]: The version of gmp you have installed has a known issue regarding timing vulnerabilities when used with pycrypto. If possible, you should update it (ie. yum update gmp). SSH password: PLAY [vpn] ******************************************************************** GATHERING FACTS *************************************************************** ok: [172.17.0.10] TASK: [copy local server to client /tmp/server-test] ************************** --- before +++ after @@ -1,0 +1,1 @@ +server changed: [172.17.0.10] => (item=server-1) ok: [172.17.0.10] => (item=server-2) ok: [172.17.0.10] => (item=server-3) PLAY RECAP ******************************************************************** 172.17.0.10 : ok=2 changed=1 unreachable=0 failed=0
9、主機(jī)信息查看
類似puppet的fact、salt的grains
[root@puppet ansible]# ansible vpn -m setup -u test --private-key=/root/denglei -k
SSH password:
172.17.0.10 | success >> {
"ansible_facts": {
"ansible_all_ipv4_addresses": [
"10.10.32.34",
"10.10.32.34"
],
"ansible_all_ipv6_addresses": [
"fe80::f816:3eff:fe3e:1667"
],
"ansible_architecture": "x86_64",
"ansible_bios_date": "01/01/2007",
"ansible_bios_version": "Bochs",
"ansible_cmdline": {
"KEYBOARDTYPE": "pc",
"KEYTABLE": "us",
"LANG": "zh_CN.UTF-8",
"quiet": true,
"rd_NO_DM": true,
"rd_NO_LUKS": true,
"rd_NO_LVM": true,
"rd_NO_MD": true,
"rhgb": true,
"ro": true,
"root": "UUID=c6042d42-8edb-4bb4-a31b-2197b043500c"
},
數(shù)據(jù)太多,我就展示部分。
- python自動(dòng)化之Ansible的安裝教程
- linux 自動(dòng)化運(yùn)維工具ansible的使用詳細(xì)教程
- 集群運(yùn)維自動(dòng)化工具ansible之使用playbook安裝zabbix客戶端
- ansible作為python模塊庫使用的方法實(shí)例
- Python利用ansible分發(fā)處理任務(wù)
- 集中化管理平臺Ansible詳解
- python將ansible配置轉(zhuǎn)為json格式實(shí)例代碼
- linux系統(tǒng)Ansible自動(dòng)化運(yùn)維部署方法
- python ansible服務(wù)及劇本編寫
- Python集中化管理平臺Ansible介紹與YAML簡介
- Python自動(dòng)化運(yùn)維之Ansible定義主機(jī)與組規(guī)則操作詳解
相關(guān)文章
服務(wù)器維護(hù)小常識(硬盤內(nèi)容增加、數(shù)據(jù)庫優(yōu)化等)
為了能更好的使用和延長服務(wù)器的使用壽命,定期的對服務(wù)器進(jìn)行維護(hù)是非常必要的。但是,在維護(hù)服務(wù)器的時(shí)候一定要小心的處理好維護(hù)的工作,否則出現(xiàn)錯(cuò)誤的話就會(huì)影響很大2012-07-07
ibmx335/ibmx336服務(wù)器做RAID陣列的圖文方法(包括刪除RAID陣列)
X服務(wù)器中有一些集成LSI SCSI控制器的機(jī)型,在開機(jī)自檢時(shí)按CTRL C可以配置兩個(gè)硬盤的鏡像。但是當(dāng)升級BIOS之后,CTRL C中的一些設(shè)置發(fā)生了變化,配置方法也較以前的版本有些差異2012-06-06
游戲服務(wù)器中的Netty應(yīng)用以及源碼剖析
這篇文章主要為大家介紹了游戲服務(wù)器中的Netty應(yīng)用以及源碼剖析,有需要的朋友可以借鑒參考下,希望能夠有所幫助,祝大家多多進(jìn)步,早日升職加薪2022-08-08
iSCSI服務(wù)器CHAP雙向認(rèn)證配置及創(chuàng)建步驟
這篇文章主要介紹了iSCSI服務(wù)器CHAP雙向認(rèn)證配置,本文給大家介紹的非常詳細(xì),對大家的學(xué)習(xí)或工作具有一定的參考借鑒價(jià)值,需要的朋友可以參考下2022-04-04
本地搭建minio文件服務(wù)器(使用bat腳本啟動(dòng))的方法
這篇文章主要介紹了本地搭建minio文件服務(wù)器(使用bat腳本啟動(dòng))的相關(guān)知識,本文給大家介紹的非常詳細(xì),對大家的學(xué)習(xí)或工作具有一定的參考借鑒價(jià)值,需要的朋友可以參考下2022-07-07
ROS參數(shù)服務(wù)器中的理論模型與參數(shù)操作(C++)
在C++中實(shí)現(xiàn)參數(shù)服務(wù)器數(shù)據(jù)的增刪改查,均可以通過兩套API實(shí)現(xiàn)分別是ros::NodeHandle和ros::param,這篇文章主要介紹了ROS參數(shù)服務(wù)器--理論模型與參數(shù)操作(C++),需要的朋友可以參考下2023-08-08
Apache,IIS下Discuz x1.5偽靜態(tài)設(shè)置方法
有時(shí)候我們在假設(shè)論壇的時(shí)候,為了優(yōu)化搜索引擎收錄效果,需要設(shè)為偽靜態(tài),除了后臺的設(shè)置,也需要服務(wù)器支持,下面的具體的實(shí)現(xiàn)方法,2011-05-05

