搜索""的结果
使用 ionice 限制 Xen 虚拟机磁盘 IO作为 VPS 服务商我们需要保证每个 VPS 公平的使用 host(服务器)的资源,避免某个 VPS 因为程序死循环、挂起、滥用等因素 “拖累” 其他 VPS,如果出现这个情况如何临时限制这个 VPS 的磁盘 IO 呢?有个办法是通过通过修改每个虚拟机 CPU 权重的办法间接、不精确的限制 IO. 在 Linux 上限制资源(CPU、内存、IO 等)的通常办法是用 cgroups,不过今天介绍的 ionice 要更容易一些。首先找到哪个虚拟机(VPS)正在大量 IO(假设是 vps0001),找到这个虚拟机后用 xm list 查出这个虚拟机使用的 ID 号,然后用 ID 配上 blkback(blkback.24)找出这个虚拟机(通过 Xen 的 blkback 驱动)关联哪些硬盘(blkback.24.xvda 和 blkback.24.xvdb),以及所使用的进程号(25089 和 25090):# xm list vps0001
Name ID Mem(MiB) VCPUs State time(s)
vps0001 24 1024 2 -b---- 70030.7
# ps aux | grep blkback.24
root 7434 0.0 0.1 61172 768 pts/16 D+ 02:48 0:00 grep blkback.24
root 25089 0.0 0.0 0 0 ? ...
case share :R710 win2012 installed the Hyper-V role show:Event ID: 60 Issue On a computer with Windows Server 2012 or Windows 8 withHyper-V role installed or after upgrading from a previous version of Windowswith the Hyper-V role already installed, you may receive the following errormessage while starting a virtual machine: Virtual machine'VM_Name' could not be started because the hypervisor is not running (Virtualmachine ID ). The following actions may helpyou resolve the problem: Verify that the processor of the physical computer has a supported version of hardware-assisted virtualization. Verify that hardware-assisted virtualization and hardware-assisted data execution protection are enabled in the BIOS of the physical computer. (If you edit the BIOS to enable either setting, you must turn off the power to the physical computer and then turn it back on. Resetting the physical computer is not sufficient.) If you have made changes to the Boot Configuration ...
CentOS 7.1 安装分布式存储系统 Ceph关于 Ceph 的介绍网上一大堆,这里就不重复了。Sage Weil 读博士的时候开发了这套牛逼的分布式存储系统,最初是奔着高性能分布式文件系统去的,结果云计算风口一来,Ceph 重心转向了分布式块存储(Block Storage)和分布式对象存储(Object Storage),现在分布式文件系统 CephFS 还停在 beta 阶段。Ceph 现在是云计算、虚拟机部署的最火开源存储解决方案,据说有20%的 OpenStack 部署存储用的都是 Ceph 的 block storage.Ceph 提供3种存储方式:对象存储,块存储和文件系统,下图很好的展示了 Ceph 存储集群的架构:我们主要关心的是块存储,将在下半年慢慢把虚拟机后端存储从 SAN 过渡到 Ceph. 虽然还是 0.94 版本,Ceph 现在已经比较成熟了,有个同事已经在生产环境里运行 Ceph 了两年多,他曾遇到很多问题,但最终还是解决了,可见 Ceph 还是非常稳定和可靠的。硬件环境准备准备了6台机器,其中3台物理服务器做监控节点(mon: ceph-mon1, ceph-mon2, ceph-mon3),2台物理服务器做存储节点(osd: ceph-osd1, ceph-osd2),1台虚拟机做管理节点(adm: ceph-adm)。Ceph 要求必须是奇数个监控节点,而且最少3个(自己玩玩的话,1个也是可...
Understand QoS at OpenSwitch danny http://dannykim.me/danny/57771 2014.02.11 14:34:58 (*.193.128.184) 592 >>> Purpose This document helps us understand how QoS works in OpenVSwitch. This document can be used as a warming up before a good tutorial(URL is shown below at References) to create a floodlight module to handle QoS. >>> Reference - How to create QoS Service Module - man ovs-vsctl (Quality of Service (QoS) section) >>> Outline QoS is the service to differentiate delivery service. In some packets, it is delivered at high speed, but others can be delivered at lower speed. Based on my understanding, key essence of QoS at OpenVSwitch is to create queues with different speed, and put packets into different queues depending on QoS policy. This document does not handle all of them, but just taste how to configure OpenVSwitch for QoS. In detail. we just create a queue with low speed, and QoS use the queue. ...
Zabbix 安装及微信短信提醒Zabbix简介Zabbix 近几年得到了各大互联网公司的认可,当然第一点归功与它强大的监控功能,第二点免费开源也得到了广大用户的青睐。Zabbix 能将操作系统中的绝大部分指标进行监控,比如(CPU 负荷,内存使用,网络状况,端口监视,日志监视等等等等指标!)。监控指标的广度是一方面,它强大的功能特点也省去了很多的配置操作。Zabbix 功能特点:自动发现服务器和网络设备分布式监控网络,集中式管理(agent 、server 分开)监控指标模版丰富可灵活地分配用户权限系统各个指标的可视化展示和分析等等如何让 Zabbix 更加完美?虽然 Zabbix 在功能上非常强大,但是它在通知层面也并非十全十美:它现在的告警方式比较单一,默认支持邮件。相信很多运维工作者对短信的告警已经再熟悉不过了,甚至已经存在抵触的心理,但还是期望 Zabbix 可以支持短信。 Zabbix 支持的短信方式需要进行短信网关对接,复杂度较高。而且短信的告警并非是一个好的方式,虽然发送了告警信息,同样会存在疏漏的情况,而且这种情况发生的概率并不是很低。那么有效的告警方式、告警信息的到达率对运维同学具有很大的意义,相信也是小朋友们非常关注的。就算 Zabbix 监控的在全面...
CentOS 6.3部署LVS(NAT)+keepalived实现高性能高可用负载均衡一、简介VS/NAT原理图:二、系统环境实验拓扑:系统平台:CentOS 6.3Kernel:2.6.32-279.el6.i686LVS版本:ipvsadm-1.26keepalived版本:keepalived-1.2.4三、安装0、安装LVS前系统需要安装popt-static,kernel-devel,make,gcc,openssl-devel,lftp,libnl*,popt*1、在两台Director Server上分别配置LVS+KeepalivedLVS install -------------[root@CentOS-LVS_MASTER ~]# wget http://www.linuxvirtualserver.org/software/kernel-2.6/ipvsadm-1.26.tar.gz[root@CentOS-LVS_MASTER ~]# ln -s /usr/src/kernels/2.6.32-279.el6.i686//usr/src/linux/[root@CentOS-LVS_MASTER ~]# tar zxvf ipvsadm-1.26.tar.gz[root@CentOS-LVS_MASTER ~]# cd ipvsadm-1.26[root@CentOS-LVS_MASTER ipvsadm-1.26]# make && make installKeepalived install -------------[root@CentOS-LVS_MASTER ~]# wget http://www.keepalived.org/software/keepalived-1.2.4.tar.gz[root@CentOS-LVS_MASTER ~]# tar zxvf keepalived-1.2.4.tar.gz[root@CentOS-LVS_MASTER ~]# cd keepalived-1.2.4[root@CentOS-LVS_MASTER keepalive...
CentOS6.4 配置LVS(DR模式)DR模式中LVS主机与实际服务器都有一块网卡连在同一物理网段上。IP分配VIP:10.10.3.170RIP1:10.10.3.140RIP2:10.10.3.1411、安装所需的依赖包yum install -y wget make kernel-devel gcc gcc-c++ libnl* libpopt* popt-static2、创建一个软链接,防止后面编译安装ipvsadm时找不到系统内核ln -s /usr/src/kernels/2.6.32-358.18.1.el6.x86_64/ /usr/src/linux3、下载安装ipvsadmwget http://www.linuxvirtualserver.org/software/kernel-2.6/ipvsadm-1.26.tar.gz
tar zxvf ipvsadm-1.26.tar.gz
cd ipvsadm-1.26
make && make install4、编写并运行脚本(LVS服务器的脚本)vi lvs.sh#!/bin/bash
# 2013-09-07 by kgdxpr
VIP=10.10.3.170
RIP1=10.10.3.140
RIP2=10.10.3.141
/etc/rc.d/init.d/functions
logger $0 called with $1
case "$1" in
start)
echo " start LVS of DirectorServer"
/sbin/ifconfig eth0:0 $VIP broadcast $VIP netmask 255.255.255.255 up
/sbin/route add -host $VIP dev eth0:0
echo "1" >/proc/sys/net/ipv4/ip_forward
#Clear IPVS table
/sbin/ip...
CentOS6.5 LVS + KeepAlived搭建步骤 测试环境架构: 废话不说,开始搭建: 1.创建内核文件的软链接,如果不创建此链接编译ipvsadm将报错 ln -s /usr/src/kernels/2.6.18-308.el5-x86_64/ /usr/src/linux (2.6.18-308.el5-x86_64:内核版本) 2.下载ipvsadm wget http://www.linuxvirtualserver.org/software/kernel-2.6/ipvsadm-1.24.tar.gz 3.安装ipvsadm # tar xvf ipvsadm-1.24.tar.gz -C /usr/local/src/ # cd /usr/local/src/ipvsadm-1.24/  ...
SSH/OpenSSH/PortForwarding Parent page: Internet and Networking >> SSH ContentsIntroductionTypes of Port ForwardingLocal Port ForwardingRemote Port ForwardingDynamic Port ForwardingForwarding GUI ProgramsSingle ApplicationsPort Forwarding ExplainedTroubleshootingIntroductionPort forwarding via SSH (SSH tunneling) creates a secure connection between a local computer and a remote machine through which services can be relayed. Because the connection is encrypted, SSH tunneling is useful for transmitting information that uses an unencrypted protocol, such as IMAP, VNC, or IRC. Types of Port ForwardingSSH's port forwarding feature can smuggle various types of Internet traffic into or out of a network. This can be used to avoid network monitoring or sniffers, or bypass badly configured routers on the Internet. Note: You might also need to change the settings in other programs (like your web browser) in order to circumvent the...
通过非XenCenter方式连接到XenServer各个VM的VNC本地界面 下面,就是我们在线上所使用的脚本,只需要你本地安装有一个VNC客户端就可以了。获取本地VM列表# ./getvnc1Usage: ./getvnc vm_name2VMs found:3idc2-server1 4idc2-server2获取指定VM的VNC端口号# ./getvnc idc2-server21run this on laptop and connect via vnc to localhost:5903 2--> ssh -L 5903:localhost:5903 root@10.100.1.30接下来,直接在本地运行"ssh -L 5903:localhost:5903 root@10.100.1.30";再通过VNC客户端连接"localhost:5903"就可以了。脚本代码:
#!/bin/bash
vm=$1
if [ -z ${vm} ]; then
echo "Usage: $0 vm_name"
echo "VMs found:"
xl list-vm | awk '{print $3}' | grep -vw name
exit 1
fi
xe vm-list params=name-label name-label=${vm} | grep ${vm} > /dev/null
if [ $? -gt 0 ]; then
echo "Error: invalid VM name"
exit 1
fi
h...
最新评论