<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>IT блог - полезные заметки. &#187; virtualization</title>
	<atom:link href="http://itblog.su/category/virtualization/feed" rel="self" type="application/rss+xml" />
	<link>http://itblog.su</link>
	<description>IT blog - авторский блог о Linux, windows, php, mysql.</description>
	<lastBuildDate>Thu, 26 Aug 2010 10:00:04 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
		<item>
		<title>vzrst module is not loaded on the destination node</title>
		<link>http://itblog.su/vzrst-module-is-not-loaded-on-the-destination-node.html</link>
		<comments>http://itblog.su/vzrst-module-is-not-loaded-on-the-destination-node.html#comments</comments>
		<pubDate>Wed, 05 Aug 2009 02:07:51 +0000</pubDate>
		<dc:creator>Артур Шакиров</dc:creator>
				<category><![CDATA[CentOS Linux]]></category>
		<category><![CDATA[OpenVZ]]></category>
		<category><![CDATA[virtualization]]></category>

		<guid isPermaLink="false">http://itblog.su/?p=326</guid>
		<description><![CDATA[понадобилось мигрировать OpenVZ контейнер с одной физической машины на другую. Номер контейнера 140 используем vzmigrate &#91;root@s24 ~&#93;# vzmigrate --online 91.195.xxx.xxx 140 OPT:--online OPT:91.195.xxx.xxx Starting online migration of CT 140 to 91.195.xxx.xxx Error:&#160; vzrst module is not loaded on the destination node Error:&#160; Can't continue online migration идем на destanation машину и смотрим, есть у нас [...]]]></description>
			<content:encoded><![CDATA[<p>понадобилось мигрировать OpenVZ контейнер с одной физической машины на другую. Номер контейнера 140 используем vzmigrate</p>
<div class="codecolorer-container bash"><div class="codecolorer" style="font-family: monospace;"><span class="br0">&#91;</span>root@s24 ~<span class="br0">&#93;</span><span class="re3"># vzmigrate --online <span class="nu0">91.195</span>.xxx.xxx <span class="nu0">140</span></span><br />
OPT:--online<br />
OPT:<span class="nu0">91.195</span>.xxx.xxx<br />
Starting online migration of CT <span class="nu0">140</span> to <span class="nu0">91.195</span>.xxx.xxx<br />
Error:&nbsp; vzrst module is not loaded on the destination node<br />
Error:&nbsp; Can<span class="st0">'t continue online migration</span></div></div>
<p>идем на destanation машину и смотрим, есть у нас там vzrst или нет</p>
<div class="codecolorer-container bash"><div class="codecolorer" style="font-family: monospace;"><span class="br0">&#91;</span>root@root ~<span class="br0">&#93;</span><span class="re3"># lsmod | grep vz</span><br />
vzethdev&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span class="nu0">16524</span>&nbsp; <span class="nu0">0</span><br />
vzdquota&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span class="nu0">43800</span>&nbsp; <span class="nu0">1</span> <span class="br0">&#91;</span>permanent<span class="br0">&#93;</span><br />
vznetdev&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span class="nu0">21512</span>&nbsp; <span class="nu0">2</span><br />
vzmon&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="nu0">49548</span>&nbsp; <span class="nu0">3</span> vzethdev,vznetdev<br />
vzdev&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span class="nu0">7556</span>&nbsp; <span class="nu0">4</span> vzethdev,vzdquota,vznetdev,vzmon<br />
ipv6&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="nu0">288668</span>&nbsp; <span class="nu0">32</span> vzmon,ip6t_REJECT</div></div>
<p>нету, ну так мы поставим, не проблема :)</p>
<div class="codecolorer-container bash"><div class="codecolorer" style="font-family: monospace;"><span class="br0">&#91;</span>root@root ~<span class="br0">&#93;</span><span class="re3"># modprobe&nbsp; vzrst</span><br />
<span class="br0">&#91;</span>root@root ~<span class="br0">&#93;</span><span class="re3"># modprobe&nbsp; vzcpt</span><br />
<span class="br0">&#91;</span>root@root ~<span class="br0">&#93;</span><span class="re3"># lsmod | grep vz</span><br />
vzcpt&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span class="nu0">115492</span>&nbsp; <span class="nu0">0</span><br />
vzrst&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span class="nu0">142740</span>&nbsp; <span class="nu0">0</span><br />
ip_nat&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span class="nu0">22032</span>&nbsp; <span class="nu0">1</span> vzrst<br />
ip_conntrack&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span class="nu0">60228</span>&nbsp; <span class="nu0">3</span> vzcpt,vzrst,ip_nat<br />
vzethdev&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span class="nu0">16524</span>&nbsp; <span class="nu0">0</span><br />
vzdquota&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span class="nu0">43800</span>&nbsp; <span class="nu0">1</span> <span class="br0">&#91;</span>permanent<span class="br0">&#93;</span><br />
vznetdev&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span class="nu0">21512</span>&nbsp; <span class="nu0">2</span><br />
vzmon&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="nu0">49548</span>&nbsp; <span class="nu0">5</span> vzcpt,vzrst,vzethdev,vznetdev<br />
vzdev&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span class="nu0">7556</span>&nbsp; <span class="nu0">4</span> vzethdev,vzdquota,vznetdev,vzmon<br />
ipv6&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span class="nu0">288668</span>&nbsp; <span class="nu0">36</span> vzcpt,vzrst,vzmon,ip6t_REJECT</div></div>
<p>ну вот собственна и всё, снова запускаем миграцию на соурс:</p>
<div class="codecolorer-container bash"><div class="codecolorer" style="font-family: monospace;"><span class="br0">&#91;</span>root@s24 ~<span class="br0">&#93;</span><span class="re3"># vzmigrate --online <span class="nu0">91.195</span>.xxx.xxx <span class="nu0">140</span></span><br />
OPT:--online<br />
OPT:<span class="nu0">91.195</span>.xxx.xxx<br />
Starting online migration of CT <span class="nu0">140</span> to <span class="nu0">91.195</span>.xxx.xx<br />
Preparing remote node<br />
Initializing remote quota<br />
Syncing private<br />
Live migrating container...<br />
Syncing 2nd level quota<br />
Cleanup</div></div>
<p>теперь идем на таргет сервер и проверяем</p>
<div class="codecolorer-container bash"><div class="codecolorer" style="font-family: monospace;"><span class="br0">&#91;</span>root@root ~<span class="br0">&#93;</span><span class="re3"># vzlist -a</span><br />
&nbsp; &nbsp; &nbsp; CTID&nbsp; &nbsp; &nbsp; NPROC STATUS&nbsp; IP_ADDR&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;HOSTNAME<br />
&nbsp; &nbsp; &nbsp; &nbsp;<span class="nu0">140</span>&nbsp; &nbsp; &nbsp; &nbsp; <span class="nu0">104</span> running <span class="nu0">91.195</span>.xxx.xxx&nbsp; hostname.ru</div></div>
<p>всё, наш контейнер без даунтаймов мигрировал на другой сервер.</p>
]]></content:encoded>
			<wfw:commentRss>http://itblog.su/vzrst-module-is-not-loaded-on-the-destination-node.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>HyperVM Installation</title>
		<link>http://itblog.su/hypervm-installation.html</link>
		<comments>http://itblog.su/hypervm-installation.html#comments</comments>
		<pubDate>Sat, 11 Jul 2009 14:58:51 +0000</pubDate>
		<dc:creator>Артур Шакиров</dc:creator>
				<category><![CDATA[CentOS Linux]]></category>
		<category><![CDATA[OpenVZ]]></category>
		<category><![CDATA[virtualization]]></category>
		<category><![CDATA[Несортированное]]></category>

		<guid isPermaLink="false">http://itblog.su/?p=309</guid>
		<description><![CDATA[Компания LxLabs разработала удобную панель управления виртуальными машинами, и назвала её HyperVM. HyperVM ставится на свежеустановленный сервер и позволяет создавать и управлять виртуальными машинами VPS/VDS на базе популярных систем виртуализации OpenVZ (Open Virtuozzo) или Xen. OpenVZ наиболее прост (для него впринципе и панель то не нужна вовсе), XEN более сложная технология но более &#171;навороченная&#187; в [...]]]></description>
			<content:encoded><![CDATA[<p>Компания LxLabs разработала удобную панель управления виртуальными машинами, и назвала её HyperVM.<br />
HyperVM ставится на свежеустановленный сервер и позволяет создавать и управлять виртуальными машинами VPS/VDS на базе популярных систем виртуализации OpenVZ (Open Virtuozzo) или Xen.<br />
OpenVZ наиболее прост (для него впринципе и панель то не нужна вовсе), XEN более сложная технология но более &laquo;навороченная&raquo; в технологическом плане.<br />
Для простоты понимания не искушенного человека опишу для чего вам может понадобится виртуализация, в частности HyperVM. Простая ситуация, вы вебстудия, у вас есть сервер на котором вы размещаете сайты клиентов. и в определенный момент нагрузка от отдельных проектов клиентских начинает шкалить мешая остальным. Можно просто выгнать клиента, и потерять деньги которые клиент платит или же выделить ему отдельное пространство с жесткими лимитами по расходу процессорных ресурсов, расхода физической памяти и прочим. Тут на помощь приходит вирутализация, вы просто создаете отдельную виртуальную машину и ставите на нее лимиты так чтобы остальным проектам не создавались помехи.</p>
<p>Или, у вас есть достаточно производительный сервер который покупали с запасом или взяли в аренду по очень выгодной цене. Но нагрузить его вы не можете и на 30% в пиках, т.е. сервер простаивает на 70% все время. Тут опять таки приходит на помощь виртуализация, создаем несколько или одну виртуальную машину и сдаем её в аренду например. таким образом Вы можете отбить часть расходов на содержание сервера.</p>
<p>Или, один из частых случаев с которым я сталкиваюсь. Два друга которым нужен выделенный сервер, вместо двух слабеньких, берут один достаточно мощный сервер (тем самым экономя в деньгах и получая больше) и делят его ровно пополам. </p>
<p>Или же компания разработчиков делит сервер на несколько виртуалок &laquo;продакшн&raquo;, &laquo;препродакшн&raquo;, &laquo;девелопмент&raquo;, &laquo;репозитарии и SVN&raquo;.</p>
<p>Вариантов очень много, широкий простор для фантазии.</p>
<p>Прямо сейчас я поднимаю виртуализацию по двум заказам на разных серверах, по тому и решил описать этот процесс ввиде лога.</p>
<div class="codecolorer-container bash"><div class="codecolorer" style="font-family: monospace;"><span class="br0">&#91;</span>root@CentOS<span class="nu0">-53</span><span class="nu0">-32</span>-minimal ~<span class="br0">&#93;</span><span class="re3"># screen</span><br />
<span class="br0">&#91;</span>root@CentOS<span class="nu0">-53</span><span class="nu0">-32</span>-minimal ~<span class="br0">&#93;</span><span class="re3"># setenforce <span class="nu0">0</span></span><br />
setenforce: SELinux is disabled<br />
<span class="br0">&#91;</span>root@CentOS<span class="nu0">-53</span><span class="nu0">-32</span>-minimal ~<span class="br0">&#93;</span><span class="re3"># cat /etc/sysconfig/selinux</span><br />
<span class="re3"># This file controls the state of SELinux on the system.</span><br />
<span class="re3"># <span class="re2">SELINUX=</span> can take one of these three values:</span><br />
<span class="re3">#&nbsp; &nbsp; &nbsp; &nbsp;enforcing - SELinux security policy is enforced.</span><br />
<span class="re3">#&nbsp; &nbsp; &nbsp; &nbsp;permissive - SELinux prints warnings instead of enforcing.</span><br />
<span class="re3">#&nbsp; &nbsp; &nbsp; &nbsp;disabled - SELinux is fully disabled.</span><br />
<span class="re2">SELINUX=</span>disabled<br />
<span class="re3"># <span class="re2">SELINUXTYPE=</span> <span class="kw3">type</span> of policy <span class="kw1">in</span> use. Possible values are:</span><br />
<span class="re3">#&nbsp; &nbsp; &nbsp; &nbsp;targeted - Only targeted network daemons are protected.</span><br />
<span class="re3">#&nbsp; &nbsp; &nbsp; &nbsp;strict - Full SELinux protection.</span><br />
<span class="re2">SELINUXTYPE=</span>targeted<br />
<span class="br0">&#91;</span>root@CentOS<span class="nu0">-53</span><span class="nu0">-32</span>-minimal ~<span class="br0">&#93;</span><span class="re3">#&nbsp; wget http://download.lxlabs.com/download/hypervm/production/hypervm-install-master.sh</span><br />
<span class="br0">&#91;</span>root@CentOS<span class="nu0">-53</span><span class="nu0">-32</span>-minimal ~<span class="br0">&#93;</span><span class="re3"># sh ./hypervm-install-master.sh --virtualization-<span class="re2">type=</span>openvz</span></div></div>
<p>После чего начинается процесс установки, который может занять до нескольких часов. В основном время установки зависит от ширины канала, по тому как выкачиваются крупные пресеты операционных систем.</p>
<p>теперь необходимо поправить /etc/grub.conf, заменив &#8216;default=1&#8242; на &#8216;default=0&#8242; и перезагрузить сервер.</p>
<p>после перезагрузки сервера заходите в панель управления http://machine-name:8888 (machine-name замените на ip адрес сервера) и всё что Вам нужно для начала работы это добавить ip пул, планы ограничений ресурсов и создать виртуальные машины.</p>
<p>если что-то не получается или вы хотите заказать установку HyperVM, обращайтесь &#8211; всегда помогу.</p>
]]></content:encoded>
			<wfw:commentRss>http://itblog.su/hypervm-installation.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>HyperVM &#8211; Alert: not_in_list_of_allowed_ip</title>
		<link>http://itblog.su/hypervm-alert-not_in_list_of_allowed_ip.html</link>
		<comments>http://itblog.su/hypervm-alert-not_in_list_of_allowed_ip.html#comments</comments>
		<pubDate>Wed, 15 Apr 2009 21:02:41 +0000</pubDate>
		<dc:creator>Артур Шакиров</dc:creator>
				<category><![CDATA[virtualization]]></category>
		<category><![CDATA[bash]]></category>
		<category><![CDATA[bash script]]></category>
		<category><![CDATA[hypervm]]></category>
		<category><![CDATA[root]]></category>

		<guid isPermaLink="false">http://itblog.su/?p=298</guid>
		<description><![CDATA[Панель управления виртуальными серверами HyperVM лимитирует доступ по IP адресу, если адреса нет в базе, то вход будет заблокирован с сообщением: Alert: not_in_list_of_allowed_ip Лечится просто, если есть root доступ к корневой системе. Зайдите на корневую машину root-ом и выполните команду: /script/clearallowedblockedip --class=client --name=admin после чего снова выполните вход в панель.]]></description>
			<content:encoded><![CDATA[<p>Панель управления виртуальными серверами HyperVM лимитирует доступ по IP адресу, если адреса нет в базе, то вход будет заблокирован с сообщением:<br />
Alert: not_in_list_of_allowed_ip</p>
<p>Лечится просто, если есть root доступ к корневой системе. Зайдите на корневую машину root-ом и выполните команду:</p>
<div class="codecolorer-container bash" style="height:35px;"><div class="codecolorer" style="font-family: monospace;">/script/clearallowedblockedip --<span class="re2">class=</span>client --<span class="re2">name=</span>admin</div></div>
<p>после чего снова выполните вход в панель.</p>
]]></content:encoded>
			<wfw:commentRss>http://itblog.su/hypervm-alert-not_in_list_of_allowed_ip.html/feed</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>XEN bug on RTL8111/8168B</title>
		<link>http://itblog.su/xen-bug-on-rtl81118168b.html</link>
		<comments>http://itblog.su/xen-bug-on-rtl81118168b.html#comments</comments>
		<pubDate>Sat, 11 Apr 2009 13:23:12 +0000</pubDate>
		<dc:creator>Артур Шакиров</dc:creator>
				<category><![CDATA[CentOS Linux]]></category>
		<category><![CDATA[networking]]></category>
		<category><![CDATA[virtualization]]></category>
		<category><![CDATA[CentOS]]></category>
		<category><![CDATA[dmesg]]></category>
		<category><![CDATA[HWaddr]]></category>
		<category><![CDATA[Xen]]></category>

		<guid isPermaLink="false">http://itblog.su/?p=296</guid>
		<description><![CDATA[На свежеустановленный CentOS 5.3 был поставлен Xen, после ребута отмерла сеть. В dmesg сыпятся ошибки: vif0.0: received packet with own address as source address причиной тому совпадение HWaddr для eth0 и xenbr0 (каким-то боком eth0 перекосило). фиксится крайне просто, может быть не так элегантно как хотелось бы, но просто. В /etc/rc.local добавляем: /sbin/ip link set [...]]]></description>
			<content:encoded><![CDATA[<p>На свежеустановленный CentOS 5.3 был поставлен Xen, после ребута отмерла сеть. В dmesg сыпятся ошибки:<br />
vif0.0: received packet with  own address as source address</p>
<p>причиной тому совпадение HWaddr для eth0 и xenbr0 (каким-то боком eth0 перекосило).</p>
<p>фиксится крайне просто, может быть не так элегантно как хотелось бы, но просто. В /etc/rc.local добавляем:</p>
<div class="codecolorer-container bash"><div class="codecolorer" style="font-family: monospace;">/sbin/ip link <span class="kw3">set</span> eth0 down<br />
/sbin/ip link <span class="kw3">set</span> eth0 addr <span class="nu0">00</span>:1C:C0:7F:<span class="nu0">76</span>:<span class="nu0">33</span><br />
/sbin/ip link <span class="kw3">set</span> eth0 up<br />
/etc/init.d/network restart</div></div>
<p>и делаем рестарт системы. </p>
]]></content:encoded>
			<wfw:commentRss>http://itblog.su/xen-bug-on-rtl81118168b.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
