4 月 272013
 

 

VMware vSphere 5.1 的新增功能

 

计算
更大型的虚拟机 — 虚拟机现在可以增长到任何以前版本的2倍,甚至可以支持最高级的应用。虚拟机现在可以拥有多达 64 个虚拟 CPU (vCPU) 和 1 TB 虚拟 RAM (vRAM)。新的虚拟机格式 — vSphere 5.1 中,虚拟机格式(版本 9)具有若干新功能,包括支持更大型的虚拟机、CPU 性能计数器和为增强性能设计的虚拟共享图形加速功能。
存储
针对虚拟桌面基础架构 (VDI) 的灵活、有效利用空间的存储— 新的磁盘格式实现了虚拟桌面空间利用率和 I/O 吞吐量之间的良好平衡。

网络
vSphere 分布式交换机 — 增强功能(例如网络运行状况检查、配置备份和还原、回滚和恢复以及链路聚合控制协议)支持并提供了更多企业级的网络连接功能,为云计算奠定了更加坚实的基础。支持单根 I/O 虚拟化 (SR-IOV) — 对 SR-IOV 的支持优化了复杂应用的性能。

可用性
vSphere vMotion® — 利用 vMotion 的优势(零停机迁移),且无需共享存储配置。这项新的 vMotion 功能可应用于整个网络。
vSphere 数据保护 — 针对虚拟机简单而经济高效的备份和还原。vSphere Data Protection 是基于 EMC Avamar 技术构建的新解决方案,它允许管理员使用内置的重复数据消除功能将虚拟机数据备份到磁盘上,且无需任何代理。本功能取代了 vSphere 之前版本中的 vSphere Data Recovery 产品。
vSphere Replication — vSphere Replication 实现了基于LAN 或 WAN 的、独立于磁盘阵列的虚拟机数据的有效复制。vSphere Replication 简化了管理,实现了虚拟机级的复制并将 RPO 降至最快 15 分钟。
针对 VMware Tools 的零停机升级 — 您将 VMware Tools升级到 5.1 版本后,将来再升级到更高版本时,就不会要求您重启计算机。

 

安全性
VMware vShield Endpoint™ — 提供了适用于任何工作负载且经过验证的端点安全解决方案,并且实现方法简单、有效、支持云计算。 vShield Endpoint 使第三方端点安全解决方案不再需要在虚拟机上使用代理,将部分保护功能分流到安全虚拟设备,并将运行扫描的影响降至最低。
自动化
vSphere Storage DRS™ 和配置文件驱动的存储 — 与VMware vCloud® Director™ 的最新集成,实现了私有云环境下更好的存储效率和自动化。
vSphere Auto Deploy™ — 提供了两种新方法用于在环境中部署新的 vSphere 主机,大大提高了 Auto Deploy 流程的可用性。

管理(使用 vCenter Server)
vSphere Web Client — vSphere Web Client 现在是 vSphere的核心管理界面。这种灵活、功能强大的新型界面能够提供快捷方式导航、自定义标记、增强的可扩展性,并且可以通过支持 Internet Explorer 或 Firefox 的设备在任何地方执行管理操作,因此简化了 vSphere 控制工作。
vCenter 单点登录 — 允许用户登录一次后不必再进行身份验证就能访问 vCenter 的所有实例和层面,显著简化了 vSphere管理。
vCenter Orchestrator — Orchestrator 简化了 vCenter Server中强大的工作流引擎的安装和配置。新设计的工作流增强了易用性,而且还可以直接从新的 vSphere Web Client 启动。

 

4 月 272013
 

VMware vCenter Converter 使用户可以快速、简单、轻松地实现基于 Microsoft Windows 的物理机转换和将第三方映像格式转换为 VMware 虚拟机。它还可以在两个 VMware 平台之间转换虚拟机。
性能和可靠性

多个同时进行的转换可实现大规模虚拟化
在迁移数据前对源计算机上的来宾操作系统执行暂停和拍摄快照操作可确保转换的可靠性
热克隆可实现无中断转换 – 没有源服务器停机或重新启动
基于扇区的复制可加快克隆和转换速度
除了热克隆外还支持冷克隆;(需要服务器停机和重新启动的转换)

管理

集中式管理控制台允许用户对同时进行的多个远程及本地转换进行排队和监视
易于使用的向导可将转换步骤减到最少
对本地和远程克隆的支持可在远程位置(如分支机构)实现转换

互操作性:对源物理机和映像格式的广泛支持

对源物理机和映像格式的广泛支持。

运行 64 位 Windows XP/2003、Windows XP、Windows 2003、Windows Server 2008 和 Linux(RHEL、SUSE 和 Ubuntu)的源物理机
源第三方映像:Microsoft Hyper-V、Microsoft Virtual Server、Microsoft Virtual PC、Parallels Desktop、Symantec Backup Exec System Recovery(以前称为 Live State Recovery)、Norton Ghost、Acronis 和 StorageCraft
源/目标虚拟机:VMware Workstation、VMware GSX Server、VMware Player、VMware Server、VMware Fusion、VMware ESX(由 VMware VirtualCenter 2.x 管理)

内容引用:

http://www.vmware.com/cn/products/datacenter-virtualization/converter/overview.html

4 月 272013
 

优化器的改进

MySQL Optimizer 团队做了大量的工作为了不断的提升 SQL 查询的效率,主要体现在索引条件pushdown以及多范围的读数据。索引条件的pushdown的意思是将 WHERE 条件语句移到存储引擎中去处理,可降低过载;而多范围读意味着当查询使用第二索引时,将进行磁盘块的排序。
InnoDB 改进

MySQL InnoDB 存储引擎团队主要提供了 NoSQL 的访问接口,可通过 Memcached 的 API 直接访问 InnoDB 的表。
使用 memcached API 直接访问 NoSQL

此举可大幅提升 Web 应用中的数据访问性能,适合一些简单的查询。
更好的复制

MySQL 复制模块团队主要改进了数据完整性和可用性以及性能方面的提升。
Performance Schema

Performance Schema 是在 5.5 版本中引入的,5.6 做了改进,提供新功能包括:表锁、表I/O 以及表锁等待。

Continue reading »

4 月 262013
 

yum install subversion

[root@localhost /]# svnadmin create /svn/repo1/
[root@localhost /]# ls /svn/repo1/
conf  db  format  hooks  locks  README.txt

[root@szvs-v04 conf]# vi svnserve.conf
anon-access = none
auth-access = write
password-db = passwd
authz-db = authz

svn://192.168.1.92/repo1

duser01/dpass01

[/]
duser01 = rw

[svn:/repo1]
duser01 = rw

svnserve -d -r /svn/

VSFTP虚拟账户配置

 未分类  VSFTP虚拟账户配置已关闭评论
4 月 232013
 

vsftpd

[root@localhost ~]# yum install vsftpd

备份原始配置文件并启用以下配置

[root@localhost ~]# cd /etc/vsftpd/
[root@localhost vsftpd]# mv vsftpd.conf vsftpd.conf.backup
[root@localhost vsftpd]# vi vsftpd.conf
anon_world_readable_only=NO
anonymous_enable=NO
chroot_local_user=YES
guest_enable=NO
guest_username=ftp
hide_ids=YES
listen=YES
listen_address=192.168.244.128
local_enable=YES
max_clients=100
max_per_ip=2
nopriv_user=ftp
pam_service_name=vsftpd
pasv_max_port=65535
pasv_min_port=64000
session_support=NO
use_localtime=YES
user_config_dir=/etc/vsftpd/users
userlist_enable=YES
userlist_file=/etc/vsftpd/ftpusers
xferlog_enable=YES
anon_umask=0027
local_umask=022
async_abor_enable=YES
connect_from_port_20=YES
dirlist_enable=NO
download_enable=NO

修改PAM认证模块配置
vi /etc/pam.d/vsftpd
auth    required pam_userdb.so db=/etc/vsftpd/accounts
account required pam_userdb.so db=/etc/vsftpd/accounts

添加虚拟帐号及密码
[root@localhost vsftpd]# vi accounts.list
abc
123
cba
321

生成加密的虚拟账户数据库
# db_load -T -t hash -f  /etc/vsftpd/accounts.list /etc/vsftpd/accounts.db

# chmod 600 /etc/vsftpd/accounts.db

创建用户配置文件
[root@localhost vsftpd]# mkdir users
[root@localhost vsftpd]# vi /etc/vsftpd/users/abc
local_root=/vusers/abc/
dirlist_enable=YES
download_enable=YES
write_enable=YES

创建用户目录
[root@localhost vsftpd]# mkdir /vusers
[root@localhost vsftpd]# useradd -d /vusers/abc -s /sbin/nologin abc
[root@localhost vsftpd]# chmod 750 /vusers/abc/

使用Windows FTP客户端登录测试

C:\Users\Harvey>ftp 192.168.244.128
 连接到 192.168.244.128。
 220 (vsFTPd 2.2.2)
 用户(192.168.244.128:(none)): abc
 331 Please specify the password.
 密码:
 230 Login successful.
 ftp> ls
 200 PORT command successful. Consider using PASV.
 150 Here comes the directory listing.
 226 Directory send OK.
 ftp> quit
 221 Goodbye.

C:\Users\Harvey>
4 月 222013
 

yum install zlib-devel perl perl-devel tk gettext

错误分析

cache.h:19:18: warning: zlib.h: No such file or directory

yum install zlib-devel

make[1]: /usr/bin/perl: Command not found

yum install perl perl-devel

GITGUI_VERSION = 0.16.0.15.gf6dd78
* new locations or Tcl/Tk interpreter
GEN git-gui
INDEX lib/
* tclsh failed; using unoptimized loading
MSGFMT    po/de.msg make[1]: *** [po/de.msg] Error 127
make: *** [all] Error 2

yum install tk

/bin/sh: msgfmt: command not found
make: *** [po/build/locale/da/LC_MESSAGES/git.mo] Error 127

yum install gettext

4 月 192013
 

登录被监控主机修改Apache配置文件

login as: root
 root@192.168.1.90's password:
 Last login: Thu Apr 18 14:42:33 2013 from 192.168.1.151
 [root@localhost ~]# vi /etc/httpd/conf/httpd.conf

开启

ExtendedStatus On

#<Location /server-status>
#    SetHandler server-status
#    Order deny,allow
#    Deny from all
#    Allow from .example.com
#</Location>

Allow from 192.168.1.151

[root@localhost ~]# service httpd restart
Stopping httpd:                                            [  OK  ]
Starting httpd:                                            [  OK  ]
[root@localhost ~]#
apache-server-status-01

login as: root
root@192.168.1.91’s password:
Last login: Thu Apr 18 09:11:58 2013 from 192.168.1.151

使用Apache Bench测试工具对指定页面连续发送10万次请求

[root@mail ~]# ab -n 100000 http://192.168.1.90/faq.php
This is ApacheBench, Version 2.3 <$Revision: 655654 $>
Copyright 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/
Licensed to The Apache Software Foundation, http://www.apache.org/

Benchmarking 192.168.1.90 (be patient)
Completed 10000 requests
Completed 20000 requests
^C

Server Software:        Apache/2.2.15
Server Hostname:        192.168.1.90
Server Port:            80

Document Path:          /faq.php
Document Length:        9372 bytes

Concurrency Level:      1
Time taken for tests:   206.254 seconds
Complete requests:      23142
Failed requests:        0
Write errors:           0
Total transferred:      222834318 bytes
HTML transferred:       216886824 bytes
Requests per second:    112.20 [#/sec] (mean)
Time per request:       8.913 [ms] (mean)
Time per request:       8.913 [ms] (mean, across all concurrent requests)
Transfer rate:          1055.07 [Kbytes/sec] received

Connection Times (ms)
min  mean[+/-sd] median   max
Connect:        0    0   0.0      0       1
Processing:     9    9   1.2      9     103
Waiting:        8    8   0.1      8      13
Total:          9    9   1.2      9     103

Percentage of the requests served within a certain time (ms)
50%      9
66%      9
75%      9
80%      9
90%      9
95%      9
98%      9
99%      9
100%    103 (longest request)
[root@mail ~]# ab -n 100000 http://192.168.1.90/faq.php
This is ApacheBench, Version 2.3 <$Revision: 655654 $>
Copyright 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/
Licensed to The Apache Software Foundation, http://www.apache.org/

Benchmarking 192.168.1.90 (be patient)
Completed 10000 requests
Completed 20000 requests
Completed 30000 requests
Completed 40000 requests
Completed 50000 requests
Completed 60000 requests
Completed 70000 requests
Completed 80000 requests
Completed 90000 requests
Completed 100000 requests
Finished 100000 requests

Server Software:        Apache/2.2.15
Server Hostname:        192.168.1.90
Server Port:            80

Document Path:          /faq.php
Document Length:        9372 bytes

Concurrency Level:      1
Time taken for tests:   888.851 seconds
Complete requests:      100000
Failed requests:        0
Write errors:           0
Total transferred:      962900000 bytes
HTML transferred:       937200000 bytes
Requests per second:    112.50 [#/sec] (mean)
Time per request:       8.889 [ms] (mean)
Time per request:       8.889 [ms] (mean, across all concurrent requests)
Transfer rate:          1057.92 [Kbytes/sec] received

Connection Times (ms)
min  mean[+/-sd] median   max
Connect:        0    0   0.0      0       5
Processing:     9    9   0.5      9      44
Waiting:        8    8   0.2      8      39
Total:          9    9   0.5      9      44

Percentage of the requests served within a certain time (ms)
50%      9
66%      9
75%      9
80%      9
90%      9
95%      9
98%      9
99%      9
100%     44 (longest request)
[root@mail ~]#

http://IP/server-status?refresh=N
apache-server-status-02

 

apache-server-status-03

“_” Waiting for Connection,
“S” Starting up,
“R” Reading Request,
“W” Sending Reply,
“K” Keepalive (read),
“D” DNS Lookup,
“C” Closing connection,
“L” Logging,
“G” Gracefully finishing,
“I” Idle cleanup of worker,
“.” Open slot with no current process

apache-server-status-04 apache-server-status-05

Srv    Child Server number – generation
PID    OS process ID
Acc    Number of accesses this connection / this child / this slot
M    Mode of operation
CPU    CPU usage, number of seconds
SS    Seconds since beginning of most recent request
Req    Milliseconds required to process most recent request
Conn    Kilobytes transferred this connection
Child    Megabytes transferred this child
Slot    Total megabytes transferred this slot

4 月 182013
 

创建主机组配置文件

define hostgroup{
 hostgroup_name  IDC
 alias           IDC Servers
 members         mail-server
 }

定义主机和服务

define host{
 use                     linux-server
 host_name               mail-server
 alias                   postfix mail server
 address                 101.78.×××.××
 }
define service{
 use                             generic-service
 host_name                       mail-server
 service_description             Webmail
 check_command                   check_http
 notifications_enabled           0
 }
define service{
 use                             generic-service
 host_name                       mail-server
 service_description             POP3 Service
 check_command                   check_pop!100.0,20%!500.0,60%
 notifications_enabled           0
 }
define service{
 use                             generic-service
 host_name                       mail-server
 service_description             SMTP Service
 check_command                   check_smtp!100.0,20%!500.0,60%
 notifications_enabled           0
 }

完整检测命令的实现

[root@monitor libexec]# ./check_pop -H 101.78.×××.×× -p 110 -w 100.0 -c 200.0
POP OK – 0.051 second response time on port 110 [+OK Dovecot ready.]|time=0.051335s;;500.000000;0.000000;10.000000
[root@monitor libexec]#

[root@monitor libexec]# ./check_smtp -H 101.78.×××.×× -p 25 -4 -w 100 -c 500
SMTP OK – 0.096 sec. response time|time=0.095827s;100.000000;500.000000;0.000000
[root@monitor libexec]#

在nagios web管理界面中看到的新增监控项目

nagios-config-02-01

查看新增的主机组

nagios-config-02-02

主机状态通告显示新增主机为Down状态
原因是目的主机前端防火墙禁止PING响应nagios-config-02-03

 

 

 

nagios-config-02-04

查看主机状态信息并关闭主机活动检测nagios-config-02-05

nagios-config-02-06

成功执行命令

nagios-config-02-07

确认主机活动检测已关闭nagios-config-02-08

nagios-config-02-09

4 月 172013
 

……

在监控主机端安装check_nrpe插件

[root@monitor ~]# tar xzvf nrpe-2.14.tar.gz
[root@monitor ~]# cd nrpe-2.14
[root@monitor nrpe-2.14]# ./configure
[root@monitor nrpe-2.14]# make all
[root@monitor nrpe-2.14]# make install-plugin
[root@monitor nrpe-2.14]# ls /usr/local/nagios/libexec/check_nrpe
 /usr/local/nagios/libexec/check_nrpe
[root@monitor nrpe-2.14]#

在被监控主机端安装nagios plugin与nrpe daemon

[root@localhost nrpe-2.14]# useradd nagios -s /sbin/nologin

安装nagios plugin

[root@localhost nagios-plugins-1.4.16]# ./configure
[root@localhost nagios-plugins-1.4.16]# make
[root@localhost nagios-plugins-1.4.16]# make install
[root@localhost nagios-plugins-1.4.16]# chown -R nagios.nagios /usr/local/nagios/

[root@localhost nrpe-2.14]# yum install gcc make openssl-devel

[root@localhost ~]# yum install xinetd

[root@localhost nrpe-2.14]# ./configure
[root@localhost nrpe-2.14]# make
[root@localhost nrpe-2.14]# make install
[root@localhost nrpe-2.14]# make install-daemon
[root@localhost nrpe-2.14]# make install-daemon-config
[root@localhost nrpe-2.14]# make install-xinetd

修改配置文件中NRPE监听的监控主机IP地址
[root@localhost nrpe-2.14]# vi /etc/xinetd.d/nrpe
only_from       = 127.0.0.1

[root@localhost nrpe-2.14]# vi /etc/services
nrpe            5666/tcp                # NRPE Daemon

[root@localhost nrpe-2.14]# service xinetd start
Starting xinetd:                                           [  OK  ]
[root@localhost nrpe-2.14]#

[root@localhost nrpe-2.14]# netstat -at |grep nrpe
tcp        0      0 *:nrpe                      *:*                         LISTEN
[root@localhost nrpe-2.14]#

[root@localhost nrpe-2.14]# /usr/local/nagios/libexec/check_nrpe -H localhost
NRPE v2.14
[root@localhost nrpe-2.14]#

在监控主机使用命令检测被监控主机当前登录用户数量

[root@monitor libexec]# ./check_nrpe -H 192.168.1.90 -c check_users
USERS OK – 1 users currently logged in |users=1;5;10;0
[root@monitor libexec]#

使用NRPE需要定义被监控主机所使用的命令
[root@localhost nrpe-2.14]# vi /usr/local/nagios/etc/nrpe.cfg
command[check_users]=/usr/local/nagios/libexec/check_users -w 5 -c 10
command[check_load]=/usr/local/nagios/libexec/check_load -w 15,10,5 -c 30,25,20
command[check_hda1]=/usr/local/nagios/libexec/check_disk -w 20% -c 10% -p /dev/hda1
command[check_zombie_procs]=/usr/local/nagios/libexec/check_procs -w 5 -c 10 -s Z
command[check_total_procs]=/usr/local/nagios/libexec/check_procs -w 150 -c 200

在监控主机创建check_nrpe命令定义

# ‘check_nrpe’ command definition
define command{
command_name    check_nrpe
command_line    $USER1$/check_nrpe -H $HOSTADDRESS$ -c $ARG1$
}

增加被监控主机的监控服务定义

[root@monitor etc]# vi servers/szvs-v01.cfg
define service{
use                             generic-service
host_name                       szvs-v01
service_description             Current Users
check_command                   check_nrpe!check_users
}

define service{
use                             generic-service
host_name                       szvs-v01
service_description             CPU Load
check_command                   check_nrpe!check_load
}

nagios-nrpe-install-01 nagios-nrpe-install-02

相关下载:
(1) NRPE 2.14