<?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>Jean - 记录成长历程 &#187; LVS</title>
	<atom:link href="http://www.zhangyiqun.net/tag/lvs/feed" rel="self" type="application/rss+xml" />
	<link>http://www.zhangyiqun.net</link>
	<description>让世界更美好一点儿</description>
	<lastBuildDate>Wed, 07 Dec 2011 14:04:37 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
		<item>
		<title>[集群]LVS的10个调度算法</title>
		<link>http://www.zhangyiqun.net/56.html</link>
		<comments>http://www.zhangyiqun.net/56.html#comments</comments>
		<pubDate>Fri, 06 Mar 2009 16:43:43 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Linux集群]]></category>
		<category><![CDATA[LVS]]></category>
		<category><![CDATA[调度算法]]></category>

		<guid isPermaLink="false">http://www.zhangyiqun.cn/?p=56</guid>
		<description><![CDATA[1、除特别说明外，本博客内容皆为原创，可以自由转载传播，但请署名及注明出处，不尊重别人劳动成果的不欢迎； 2、本博客内容遵守“署名-非商业性使用-禁止演绎 2.5 中国大陆”协议； 作者：张逸群 Mail:jeantoe@gmail.com 参考资料：man ipvsadm 网上的中文资料写的太专业了，看了几句就受不了了情况如下： 1.一句话能解释清楚意思的非要整些术语出来，整好几段。 2.好几段话才能解释清楚的，就一句话通常还答非所问。 如果有朋友看到一些通俗易懂的一定要发我一份啊。 以下是我自己的理解，难免会有错误，欢迎讨论。 1. 大锅饭调度(Round-Robin Scheduling RR) rr &#8211; 纯轮询方式，比较垃圾。把每项请求按顺序在真正服务器中分派。 2. 带权重的大锅饭调度(Weighted Round-Robin Scheduling WRR) wrr -带权重轮询方式。把每项请求按顺序在真正服务器中循环分派，但是给能力较大的服务器分派较多的作业。 3. 谁不干活就给谁分配(Least-Connection LC) lc &#8211; 根据最小连接数分派 4. 带权重的谁不干活就给谁分配（Weighted Least-Connections WLC 默认） wlc &#8211; 带权重的。机器配置好的权重高。 5. 基于地区的最少连接调度(Locality-Based Least-Connection Scheduling LBLC) lblc &#8211; 缓存服务器集群。基于本地的最小连接。把请求传递到负载小的服务器上。 6. 带有复制调度的基于地区的最少连接调度(Locality-Based Least-Connection Scheduling with Replication [...]<table class="wumii-related-items" cellspacing="0" cellpadding="3" border="0"  style="clear: both;">
    
    <tr>
        <td colspan="4"><b><font size="-1"  style="display: block !important; padding: 20px 0 5px !important;">您可能也喜欢：</font></b></td>
    </tr>
    
        <tr>
                <td width="102" valign="top" style="padding: 5px !important; margin: 0 !important;">
                    <a target="_blank" title="[集群]详解LVS的工作模式之DR的实现" style="text-decoration: none !important; cursor: pointer !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F49.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F56.html">
                        <img style="margin: 0 !important; padding: 2px !important; border: 1px solid #DDDDDD !important; width: 96px !important; height: 96px !important;" src="http://static.wumii.com/site_images/2011/10/31/10075736.gif" width="96px" height="96px" /><br />
                        <font size="-1" color="#333333" style="display: block !important; line-height: 15px !important; width: 102px !important; font: 12px/15px arial !important; height: 60px !important; margin: 3px 0 0 0 !important; padding: 0 !important; overflow: hidden !important;">[集群]详解LVS的工作模式之DR的实现</font>
                    </a>
                </td>
                <td width="102" valign="top" style="padding: 5px !important; margin: 0 !important; border-left: 1px solid #DDDDDD !important;">
                    <a target="_blank" title="[集群]详解LVS的工作模式之NAT的实现" style="text-decoration: none !important; cursor: pointer !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F37.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F56.html">
                        <img style="margin: 0 !important; padding: 2px !important; border: 1px solid #DDDDDD !important; width: 96px !important; height: 96px !important;" src="http://static.wumii.com/site_images/2010/10/03/366188.gif" width="96px" height="96px" /><br />
                        <font size="-1" color="#333333" style="display: block !important; line-height: 15px !important; width: 102px !important; font: 12px/15px arial !important; height: 60px !important; margin: 3px 0 0 0 !important; padding: 0 !important; overflow: hidden !important;">[集群]详解LVS的工作模式之NAT的实现</font>
                    </a>
                </td>
                <td width="102" valign="top" style="padding: 5px !important; margin: 0 !important; border-left: 1px solid #DDDDDD !important;">
                    <a target="_blank" title="[集群]基础" style="text-decoration: none !important; cursor: pointer !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F54.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F56.html">
                        <img style="margin: 0 !important; padding: 2px !important; border: 1px solid #DDDDDD !important; width: 96px !important; height: 96px !important;" src="http://static.wumii.com/images/blogWidget/wordpress_default.gif" width="96px" height="96px" /><br />
                        <font size="-1" color="#333333" style="display: block !important; line-height: 15px !important; width: 102px !important; font: 12px/15px arial !important; height: 60px !important; margin: 3px 0 0 0 !important; padding: 0 !important; overflow: hidden !important;">[集群]基础</font>
                    </a>
                </td>
                <td width="102" valign="top" style="padding: 5px !important; margin: 0 !important; border-left: 1px solid #DDDDDD !important;">
                    <a target="_blank" title="探索LV卷丢失的恢复方法" style="text-decoration: none !important; cursor: pointer !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F223.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F56.html">
                        <img style="margin: 0 !important; padding: 2px !important; border: 1px solid #DDDDDD !important; width: 96px !important; height: 96px !important;" src="http://static.wumii.com/images/blogWidget/wordpress_default.gif" width="96px" height="96px" /><br />
                        <font size="-1" color="#333333" style="display: block !important; line-height: 15px !important; width: 102px !important; font: 12px/15px arial !important; height: 60px !important; margin: 3px 0 0 0 !important; padding: 0 !important; overflow: hidden !important;">探索LV卷丢失的恢复方法</font>
                    </a>
                </td>
        </tr>
    
    <tr>
        <td colspan="4" align="right">
            <a style="text-decoration: none !important;" href="http://www.wumii.com/widget/relatedItems.htm" target="_blank" title="无觅相关文章插件">
                <font size="-1" color="#bbbbbb" style="display: block !important; font-family: arial !important; padding: 5px 0 !important; font-size: 12px !important; color: #bbb !important;">无觅</font>
            </a>
        </td>
    </tr>
</table>]]></description>
			<content:encoded><![CDATA[<p class="MsoNormal"><span>1、除特别说明外，本博客内容皆为原创，可以自由转载传播，但请署名及注明出处，不尊重别人劳动成果的不欢迎；</span></p>
<p><span>2、本博客内容遵守“</span><a href="http://creativecommons.org/licenses/by-nc-nd/2.5/cn/" target="_blank"><span>署名-非商业性使用-禁止演绎 2.5 中国大陆</span></a><span>”协议；</span></p>
<p>作者：张逸群<br />
Mail:jeantoe@gmail.com</p>
<p>参考资料：man ipvsadm</p>
<p>网上的中文资料写的太专业了，看了几句就受不了了情况如下：<br />
1.一句话能解释清楚意思的非要整些术语出来，整好几段。<br />
2.好几段话才能解释清楚的，就一句话通常还答非所问。</p>
<p>如果有朋友看到一些通俗易懂的一定要发我一份啊。</p>
<p>以下是我自己的理解，难免会有错误，欢迎讨论。</p>
<p><strong>1. 大锅饭调度(Round-Robin Scheduling RR)</strong><br />
rr &#8211; 纯轮询方式，比较垃圾。把每项请求按顺序在真正服务器中分派。<br />
<span id="more-56"></span><br />
<strong>2. 带权重的大锅饭调度(Weighted Round-Robin Scheduling WRR)</strong><br />
wrr -带权重轮询方式。把每项请求按顺序在真正服务器中循环分派，但是给能力较大的服务器分派较多的作业。</p>
<p><strong>3. 谁不干活就给谁分配(Least-Connection LC)</strong><br />
lc  &#8211; 根据最小连接数分派</p>
<p><strong>4. 带权重的谁不干活就给谁分配（Weighted Least-Connections WLC 默认）</strong><br />
wlc &#8211; 带权重的。机器配置好的权重高。</p>
<p><strong>5. 基于地区的最少连接调度(Locality-Based Least-Connection<br />
Scheduling LBLC)</strong><br />
lblc &#8211;  缓存服务器集群。基于本地的最小连接。把请求传递到负载小的服务器上。</p>
<p><strong>6. 带有复制调度的基于地区的最少连接调度(Locality-Based Least-Connection Scheduling with Replication Scheduling LBLCR)</strong><br />
lblcr   &#8211;  带复制调度的缓存服务器集群。某页面缓存在服务器A上，被访问次数极高，而其他缓存服务器负载较低，监视是否访问同一页面，如果是访问同一页面则把请求分到其他服务器。</p>
<p><strong>7. 目标散列调度(Destination Hash Scheduling DH)</strong><br />
realserver中绑定两个ip。ld判断来者的ISP商，将其转到相应的IP。</p>
<p><strong>8. 源散列调度(Source Hash Scheduling SH)</strong><br />
源地址散列。基于client地址的来源区分。（用的很少）</p>
<p><strong>9. 最短的期望的延迟（Shortest Expected Delay Scheduling SED）</strong><br />
基于wlc算法。这个必须举例来说了<br />
ABC三台机器分别权重123 ，连接数也分别是123。那么如果使用WLC算法的话一个新请求进入时它可能会分给ABC中的任意一个。使用sed算法后会进行这样一个运算<br />
A:(1+1)/1<br />
B:(1+2)/2<br />
C:(1+3)/3<br />
根据运算结果，把连接交给C 。</p>
<p><strong>10.最少队列调度（Never Queue Scheduling NQ）</strong><br />
无需队列。如果有台realserver的连接数＝0就直接分配过去，不需要在进行sed运算。</p>
<table class="wumii-related-items" cellspacing="0" cellpadding="3" border="0"  style="clear: both;">
    
    <tr>
        <td colspan="4"><b><font size="-1"  style="display: block !important; padding: 20px 0 5px !important;">您可能也喜欢：</font></b></td>
    </tr>
    
        <tr>
                <td width="102" valign="top" style="padding: 5px !important; margin: 0 !important;">
                    <a target="_blank" title="[集群]详解LVS的工作模式之DR的实现" style="text-decoration: none !important; cursor: pointer !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F49.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F56.html">
                        <img style="margin: 0 !important; padding: 2px !important; border: 1px solid #DDDDDD !important; width: 96px !important; height: 96px !important;" src="http://static.wumii.com/site_images/2011/10/31/10075736.gif" width="96px" height="96px" /><br />
                        <font size="-1" color="#333333" style="display: block !important; line-height: 15px !important; width: 102px !important; font: 12px/15px arial !important; height: 60px !important; margin: 3px 0 0 0 !important; padding: 0 !important; overflow: hidden !important;">[集群]详解LVS的工作模式之DR的实现</font>
                    </a>
                </td>
                <td width="102" valign="top" style="padding: 5px !important; margin: 0 !important; border-left: 1px solid #DDDDDD !important;">
                    <a target="_blank" title="[集群]详解LVS的工作模式之NAT的实现" style="text-decoration: none !important; cursor: pointer !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F37.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F56.html">
                        <img style="margin: 0 !important; padding: 2px !important; border: 1px solid #DDDDDD !important; width: 96px !important; height: 96px !important;" src="http://static.wumii.com/site_images/2010/10/03/366188.gif" width="96px" height="96px" /><br />
                        <font size="-1" color="#333333" style="display: block !important; line-height: 15px !important; width: 102px !important; font: 12px/15px arial !important; height: 60px !important; margin: 3px 0 0 0 !important; padding: 0 !important; overflow: hidden !important;">[集群]详解LVS的工作模式之NAT的实现</font>
                    </a>
                </td>
                <td width="102" valign="top" style="padding: 5px !important; margin: 0 !important; border-left: 1px solid #DDDDDD !important;">
                    <a target="_blank" title="[集群]基础" style="text-decoration: none !important; cursor: pointer !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F54.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F56.html">
                        <img style="margin: 0 !important; padding: 2px !important; border: 1px solid #DDDDDD !important; width: 96px !important; height: 96px !important;" src="http://static.wumii.com/images/blogWidget/wordpress_default.gif" width="96px" height="96px" /><br />
                        <font size="-1" color="#333333" style="display: block !important; line-height: 15px !important; width: 102px !important; font: 12px/15px arial !important; height: 60px !important; margin: 3px 0 0 0 !important; padding: 0 !important; overflow: hidden !important;">[集群]基础</font>
                    </a>
                </td>
                <td width="102" valign="top" style="padding: 5px !important; margin: 0 !important; border-left: 1px solid #DDDDDD !important;">
                    <a target="_blank" title="探索LV卷丢失的恢复方法" style="text-decoration: none !important; cursor: pointer !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F223.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F56.html">
                        <img style="margin: 0 !important; padding: 2px !important; border: 1px solid #DDDDDD !important; width: 96px !important; height: 96px !important;" src="http://static.wumii.com/images/blogWidget/wordpress_default.gif" width="96px" height="96px" /><br />
                        <font size="-1" color="#333333" style="display: block !important; line-height: 15px !important; width: 102px !important; font: 12px/15px arial !important; height: 60px !important; margin: 3px 0 0 0 !important; padding: 0 !important; overflow: hidden !important;">探索LV卷丢失的恢复方法</font>
                    </a>
                </td>
        </tr>
    
    <tr>
        <td colspan="4" align="right">
            <a style="text-decoration: none !important;" href="http://www.wumii.com/widget/relatedItems.htm" target="_blank" title="无觅相关文章插件">
                <font size="-1" color="#bbbbbb" style="display: block !important; font-family: arial !important; padding: 5px 0 !important; font-size: 12px !important; color: #bbb !important;">无觅</font>
            </a>
        </td>
    </tr>
</table>]]></content:encoded>
			<wfw:commentRss>http://www.zhangyiqun.net/56.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>[集群]详解LVS的工作模式之DR的实现</title>
		<link>http://www.zhangyiqun.net/49.html</link>
		<comments>http://www.zhangyiqun.net/49.html#comments</comments>
		<pubDate>Fri, 06 Mar 2009 04:21:44 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Linux集群]]></category>
		<category><![CDATA[DR]]></category>
		<category><![CDATA[LVS]]></category>
		<category><![CDATA[集群]]></category>

		<guid isPermaLink="false">http://www.zhangyiqun.cn/?p=49</guid>
		<description><![CDATA[1、除特别说明外，本博客内容皆为原创，可以自由转载传播，但请署名及注明出处，不尊重别人劳动成果的不欢迎； 2、本博客内容遵守“署名-非商业性使用-禁止演绎 2.5 中国大陆”协议； 作者：张逸群 Mail:jeantoe@gmail.com 前言 Linux 服务器集群系统(以下简称 LVS), 是一个由章文嵩博士发起的自由软件项目，现在已经是 Linux 标准内核的一部分。LVS 从 Linux 内核还在 2.0 版本的时代开始，就得到广泛的应用，目前 Linux 的内核已经是 2.6 版，完全内置了 LVS 的各个模块，已经不需要在给内核打任何补丁。 如何配置 DR方式的集群是本文关注的焦点，读者可以将本文当作一篇 Howto 文档， 以一种相对简单的架构让集群“跑起来”，在生产中的应用随着我经验的增加也会陆续添加。 DR方式拓扑图 在dr模式中由realserver直接回复client的请求，流量不经过director所以速度快开销少。需要注意的是无论NAT或者DR方式都要求所有realserver必须和director位于同一个局域网内。 以DR方式部署 实验环境 OS:RHEL5U1 调度算法：rr director 192.168.92.130(DIP) , 192.168.92.132 realserver1 192.168.92.100 realserver2 192.168.92.200 注意：DR方式中的IP全部都是公网IP 配置 director方面 ipvsadm -A -t 192.168.92.132:80 -s rr ipvsadm -a -t [...]<table class="wumii-related-items" cellspacing="0" cellpadding="2" border="0" width="100%" style="clear: both;">
    
    <tr>
        <td ><b><font size="-1"  style="display: block !important; padding: 20px 0 5px !important;">您可能也喜欢：</font></b></td>
    </tr>
    
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F37.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F49.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">[集群]详解LVS的工作模式之NAT的实现</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F54.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F49.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">[集群]基础</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F56.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F49.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">[集群]LVS的10个调度算法</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F870.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F49.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">如何做Tomcat集群和session复制？</font>
                    </a>
                </td>
            </tr>
    
    <tr>
        <td  align="right">
            <a style="text-decoration: none !important;" href="http://www.wumii.com/widget/relatedItems.htm" target="_blank" title="无觅相关文章插件">
                <font size="-1" color="#bbbbbb" style="display: block !important; font-family: arial !important; padding: 5px 0 !important; font-size: 12px !important; color: #bbb !important;">无觅</font>
            </a>
        </td>
    </tr>
</table>]]></description>
			<content:encoded><![CDATA[<p class="MsoNormal"><span>1、除特别说明外，本博客内容皆为原创，可以自由转载传播，但请署名及注明出处，不尊重别人劳动成果的不欢迎；</span></p>
<p><span>2、本博客内容遵守“</span><a href="http://creativecommons.org/licenses/by-nc-nd/2.5/cn/" target="_blank"><span>署名-非商业性使用-禁止演绎 2.5 中国大陆</span></a><span>”协议；</span></p>
<p>作者：张逸群<br />
Mail:jeantoe@gmail.com</p>
<p>前言<br />
Linux 服务器集群系统(以下简称 LVS), 是一个由章文嵩博士发起的自由软件项目，现在已经是 Linux 标准内核的一部分。LVS 从 Linux 内核还在 2.0 版本的时代开始，就得到广泛的应用，目前<br />
Linux 的内核已经是 2.6 版，完全内置了 LVS 的各个模块，已经不需要在给内核打任何补丁。</p>
<p>如何配置 DR方式的集群是本文关注的焦点，读者可以将本文当作一篇 Howto 文档， 以一种相对简单的架构让集群“跑起来”，在生产中的应用随着我经验的增加也会陆续添加。</p>
<p><span id="more-49"></span></p>
<p><strong>DR方式拓扑图</strong></p>
<p><img class="alignnone" title="DR" src="http://www.linuxvirtualserver.org/VS-DRouting.gif" alt="" width="691" height="661" /></p>
<p>在dr模式中由realserver直接回复client的请求，流量不经过director所以速度快开销少。需要注意的是无论NAT或者DR方式都要求所有realserver必须和director位于同一个局域网内。</p>
<h3>以DR方式部署</h3>
<p><img class="alignnone" title="lvs-dr" src="http://www.zhangyiqun.cn/wp-content/uploads/2009/08/lvs/lvs-dr.jpg" alt="" width="590" height="692" /></p>
<p><strong>实验环境</strong><br />
OS:RHEL5U1<br />
调度算法：rr<br />
director 192.168.92.130(DIP) , 192.168.92.132<br />
realserver1 192.168.92.100<br />
realserver2 192.168.92.200<br />
注意：DR方式中的IP全部都是公网IP</p>
<p><strong>配置</strong></p>
<p>director方面</p>
<blockquote><p>ipvsadm -A -t 192.168.92.132:80 -s rr<br />
ipvsadm -a -t 192.168.92.132:80 -r 192.168.92.100 -g<br />
ipvsadm -a -t 192.168.92.132:80 -r 192.168.92.200 -g<br />
echo 1 &gt; /proc/sys/net/ipv4/ip_forward</p></blockquote>
<p>realserver1和2中的配置</p>
<blockquote><p><strong><span style="font-weight: normal;">i</span><span style="font-weight: normal;">fconfig lo:1 192.168.92.132 netmask 255.255.255.255</span></strong></p>
<p>用lo而不用eth的原因。</p>
<p>eth是外部网络接口，如果配置成192.168.0.vip将导致ip地址冲突。</p>
<p>在realserver中关闭arp</p>
<p>echo 1 &gt; /proc/sys/net/ipv4/conf/eth0/arp_ignore</p>
<p>echo 2 &gt; /proc/sys/net/ipv4/conf/eth0/arp_announce</p>
<p>echo 1 &gt; /proc/sys/net/ipv4/conf/lo/arp_ignore</p>
<p>echo 2 &gt; /proc/sys/net/ipv4/conf/lo/arp_announce</p>
<p>永久修改以上位置 vim /etc/sysctl.conf</p>
<p>格式net.ipv4.conf.eth0.arp_ignore</p></blockquote>
<table class="wumii-related-items" cellspacing="0" cellpadding="2" border="0" width="100%" style="clear: both;">
    
    <tr>
        <td ><b><font size="-1"  style="display: block !important; padding: 20px 0 5px !important;">您可能也喜欢：</font></b></td>
    </tr>
    
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F37.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F49.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">[集群]详解LVS的工作模式之NAT的实现</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F54.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F49.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">[集群]基础</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F56.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F49.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">[集群]LVS的10个调度算法</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F870.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F49.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">如何做Tomcat集群和session复制？</font>
                    </a>
                </td>
            </tr>
    
    <tr>
        <td  align="right">
            <a style="text-decoration: none !important;" href="http://www.wumii.com/widget/relatedItems.htm" target="_blank" title="无觅相关文章插件">
                <font size="-1" color="#bbbbbb" style="display: block !important; font-family: arial !important; padding: 5px 0 !important; font-size: 12px !important; color: #bbb !important;">无觅</font>
            </a>
        </td>
    </tr>
</table>]]></content:encoded>
			<wfw:commentRss>http://www.zhangyiqun.net/49.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>[集群]详解LVS的工作模式之NAT的实现</title>
		<link>http://www.zhangyiqun.net/37.html</link>
		<comments>http://www.zhangyiqun.net/37.html#comments</comments>
		<pubDate>Thu, 05 Mar 2009 09:57:51 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Linux集群]]></category>
		<category><![CDATA[LVS]]></category>
		<category><![CDATA[NAT]]></category>
		<category><![CDATA[笔记]]></category>
		<category><![CDATA[集群]]></category>

		<guid isPermaLink="false">http://www.zhangyiqun.cn/?p=37</guid>
		<description><![CDATA[1、除特别说明外，本博客内容皆为原创，可以自由转载传播，但请署名及注明出处，不尊重别人劳动成果的不欢迎； 2、本博客内容遵守“署名-非商业性使用-禁止演绎 2.5 中国大陆”协议； 作者：张逸群 Mail:jeantoe@gmail.com 前言 Linux 服务器集群系统(以下简称 LVS), 是一个由章文嵩博士发起的自由软件项目，现在已经是 Linux 标准内核的一部分。LVS 从 Linux 内核还在 2.0 版本的时代开始，就得到广泛的应用，目前 Linux 的内核已经是 2.6 版，完全内置了 LVS 的各个模块，已经不需要在给内核打任何补丁。 如何配置 NAT方式的集群是本文关注的焦点，读者可以将本文当作一篇 Howto 文档， 以一种相对简单的架构让集群“跑起来”，在生产中的应用随着我经验的增加也会陆续添加。 NAT方式拓扑图 使用NAT方式时，director同时是一台NAT网关，它必须有一个公网IP，当收到请求时按照调度算法把请求转发给局域网中的某台realserver，realserver处理完请求后把结果返回给director，此时director将结果返回给client。 因为NAT方式完全依赖于director，需要d机有较强的数据吞吐，同时这也导致了d成为一个瓶颈。根据官方的文档当realserver少于20台时用NAT比较合适。 以NAT方式搭建 实验环境 OS:RHEL5U1 调度算法：rr director 192.168.1.254 , 192.168.92.132 (公网) realserver1 192.168.1.100 realserver2 192.168.1.200 安装 yum install ipvsadm 配置 director方面 添加realserver ipvsadm -A -t [...]<table class="wumii-related-items" cellspacing="0" cellpadding="2" border="0" width="100%" style="clear: both;">
    
    <tr>
        <td ><b><font size="-1"  style="display: block !important; padding: 20px 0 5px !important;">您可能也喜欢：</font></b></td>
    </tr>
    
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F49.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F37.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">[集群]详解LVS的工作模式之DR的实现</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F54.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F37.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">[集群]基础</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F56.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F37.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">[集群]LVS的10个调度算法</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F870.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F37.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">如何做Tomcat集群和session复制？</font>
                    </a>
                </td>
            </tr>
    
    <tr>
        <td  align="right">
            <a style="text-decoration: none !important;" href="http://www.wumii.com/widget/relatedItems.htm" target="_blank" title="无觅相关文章插件">
                <font size="-1" color="#bbbbbb" style="display: block !important; font-family: arial !important; padding: 5px 0 !important; font-size: 12px !important; color: #bbb !important;">无觅</font>
            </a>
        </td>
    </tr>
</table>]]></description>
			<content:encoded><![CDATA[<p class="MsoNormal"><span>1、除特别说明外，本博客内容皆为原创，可以自由转载传播，但请署名及注明出处，不尊重别人劳动成果的不欢迎；</span></p>
<p><span>2、本博客内容遵守“</span><a href="http://creativecommons.org/licenses/by-nc-nd/2.5/cn/" target="_blank"><span>署名-非商业性使用-禁止演绎 2.5 中国大陆</span></a><span>”协议；</span></p>
<p>作者：张逸群<br />
Mail:jeantoe@gmail.com</p>
<p>前言<br />
Linux 服务器集群系统(以下简称 LVS), 是一个由章文嵩博士发起的自由软件项目，现在已经是 Linux 标准内核的一部分。LVS 从 Linux 内核还在 2.0 版本的时代开始，就得到广泛的应用，目前<br />
Linux 的内核已经是 2.6 版，完全内置了 LVS 的各个模块，已经不需要在给内核打任何补丁。</p>
<p>如何配置 NAT方式的集群是本文关注的焦点，读者可以将本文当作一篇 Howto 文档， 以一种相对简单的架构让集群“跑起来”，在生产中的应用随着我经验的增加也会陆续添加。</p>
<p>NAT方式拓扑图</p>
<p><span id="more-37"></span></p>
<p><img class="alignnone" title="NAT" src="http://www.linuxvirtualserver.org/VS-NAT.gif" alt="" width="649" height="605" /></p>
<p>使用NAT方式时，director同时是一台NAT网关，它必须有一个公网IP，当收到请求时按照<strong>调度算法</strong>把请求转发给局域网中的某台realserver，realserver处理完请求后把结果返回给director，此时director将结果返回给client。<br />
<span lang="EN-US">因为NAT</span><span>方式完全依赖于</span><span lang="EN-US">director</span><span>，需要d机有较强的数据吞吐，同时这也导致了</span><span lang="EN-US">d</span><span>成为一个瓶颈。根据官方的文档当realserver少于20台时用NAT比较合适。</span></p>
<h3>以NAT方式搭建</h3>
<p><img class="alignnone" title="lvs-nat" src="http://www.zhangyiqun.cn/wp-content/uploads/2009/08/lvs/lvs-nat.jpg" alt="" width="439" height="335" /></p>
<p><strong>实验环境</strong></p>
<blockquote><p>OS:RHEL5U1<br />
调度算法：rr<br />
director 192.168.1.254 , 192.168.92.132 (公网)<br />
realserver1 192.168.1.100<br />
realserver2 192.168.1.200</p></blockquote>
<p><strong>安装</strong></p>
<blockquote><p>yum install ipvsadm</p></blockquote>
<p><strong>配置</strong></p>
<p>director方面</p>
<p>添加realserver</p>
<blockquote><p>ipvsadm -A -t 192.168.92.132:80 -s rr 192.168.1.254<br />
ipvsadm -a -t 192.168.92.132:80 -r 192.168.1.100 -m<br />
ipvsadm -a -t 192.168.92.132:80 -r 192.168.1.200 -m<br />
ipvsadm -Ln #显示列表，看是否添加成功</p></blockquote>
<p>开启ip转发</p>
<blockquote><p>cat /proc/sys/net/ipv4/ip_forward<br />
echo &#8220;1&#8243; &gt;/proc/sys/net/ipv4/ip_forward</p></blockquote>
<p>到此director配置完毕。</p>
<p>realserver1的配置</p>
<blockquote><p>route add default dev eth0 gw 192.168.1.254<br />
echo &#8220;0&#8243; &gt;/proc/sys/net/ipv4/ip_forward</p></blockquote>
<p>realserver2的配置</p>
<blockquote><p>route add default dev eth0 gw 192.168.1.254<br />
echo &#8220;0&#8243; &gt;/proc/sys/net/ipv4/ip_forward</p></blockquote>
<p>到此LVS集群配置完毕，可以跑服务测试！我这里用web服务做测试，因为效果比较明显。<br />
<img class="alignnone" title="ipvsadm" src="http://www.zhangyiqun.cn/wp-content/uploads/2009/image/cluser/ipvsadm.gif" alt="" width="671" height="159" /></p>
<p>注意：不要使用firefox或者google的抽魔浏览器，缓存会让你看不到效果的。</p>
<table class="wumii-related-items" cellspacing="0" cellpadding="2" border="0" width="100%" style="clear: both;">
    
    <tr>
        <td ><b><font size="-1"  style="display: block !important; padding: 20px 0 5px !important;">您可能也喜欢：</font></b></td>
    </tr>
    
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F49.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F37.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">[集群]详解LVS的工作模式之DR的实现</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F54.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F37.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">[集群]基础</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F56.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F37.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">[集群]LVS的10个调度算法</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F870.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F37.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">如何做Tomcat集群和session复制？</font>
                    </a>
                </td>
            </tr>
    
    <tr>
        <td  align="right">
            <a style="text-decoration: none !important;" href="http://www.wumii.com/widget/relatedItems.htm" target="_blank" title="无觅相关文章插件">
                <font size="-1" color="#bbbbbb" style="display: block !important; font-family: arial !important; padding: 5px 0 !important; font-size: 12px !important; color: #bbb !important;">无觅</font>
            </a>
        </td>
    </tr>
</table>]]></content:encoded>
			<wfw:commentRss>http://www.zhangyiqun.net/37.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>[集群]基础</title>
		<link>http://www.zhangyiqun.net/54.html</link>
		<comments>http://www.zhangyiqun.net/54.html#comments</comments>
		<pubDate>Wed, 04 Mar 2009 16:26:42 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Linux集群]]></category>
		<category><![CDATA[LVS]]></category>
		<category><![CDATA[基础]]></category>
		<category><![CDATA[集群]]></category>

		<guid isPermaLink="false">http://www.zhangyiqun.cn/?p=54</guid>
		<description><![CDATA[1.请简要什么是集群技术？为什么要使用集群技术？ 集群是一组协同工作的服务实体，用以提供比单一服务实体更具扩展性和可用性的服务平台。 2.请说出你所知道的集群种类，和实现方案？ 目前Linux下的集群主要有三种类型  1. HA (High Availability)  2. LB (Load Balancing)  3. HPC (High performance Computing)  ○ DC (Distributed Computing)  ○ PC (Parallel Computing) 高性能计算集群（High Performance Compute clustering）（如 Beowulf）使用多个机器来为需要大量计算能力的任务提供更强大的计算能力。RHEL没有内嵌这类集群的解决方案。  高可用性集群（High-availability clustering）使用多个机器来为某个服务或某组服务提供额外的可靠性。  负载均衡集群（Load-balance clustering）使用特殊的路由技术来给一组服务器分配任务。  RedHat提供了后两种集群技术的解决方案。使用一组程序来监视该系统和集群中的服务的健康状况。 虽然集群系统并不能解决所有的系统问题，但是它能够帮助系统管理员最大限度地利用现有的资源。并不是所有的程序都适用于集群系统，但是常见的系统应用如HTTP服务，FTP服务，数据库服务都可以利用集群系统来增强它们的功能。 3.什么时候需要用LB集群？ 公共WEB服务、FTP服务、数据库服务等高负载服务中。 4.什么时候需要使用HA集群？ Ha集群主要用于文件服务，WEB服务，数据库服务等关键应用中 5.Linux下实现LB集群的项目是？ 目前在LINUX系统下使用最为广泛的LB集群系统为LVS<table class="wumii-related-items" cellspacing="0" cellpadding="3" border="0"  style="clear: both;">
    
    <tr>
        <td colspan="4"><b><font size="-1"  style="display: block !important; padding: 20px 0 5px !important;">您可能也喜欢：</font></b></td>
    </tr>
    
        <tr>
                <td width="102" valign="top" style="padding: 5px !important; margin: 0 !important;">
                    <a target="_blank" title="[集群]详解LVS的工作模式之DR的实现" style="text-decoration: none !important; cursor: pointer !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F49.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F54.html">
                        <img style="margin: 0 !important; padding: 2px !important; border: 1px solid #DDDDDD !important; width: 96px !important; height: 96px !important;" src="http://static.wumii.com/site_images/2011/10/31/10075736.gif" width="96px" height="96px" /><br />
                        <font size="-1" color="#333333" style="display: block !important; line-height: 15px !important; width: 102px !important; font: 12px/15px arial !important; height: 60px !important; margin: 3px 0 0 0 !important; padding: 0 !important; overflow: hidden !important;">[集群]详解LVS的工作模式之DR的实现</font>
                    </a>
                </td>
                <td width="102" valign="top" style="padding: 5px !important; margin: 0 !important; border-left: 1px solid #DDDDDD !important;">
                    <a target="_blank" title="[集群]详解LVS的工作模式之NAT的实现" style="text-decoration: none !important; cursor: pointer !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F37.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F54.html">
                        <img style="margin: 0 !important; padding: 2px !important; border: 1px solid #DDDDDD !important; width: 96px !important; height: 96px !important;" src="http://static.wumii.com/site_images/2010/10/03/366188.gif" width="96px" height="96px" /><br />
                        <font size="-1" color="#333333" style="display: block !important; line-height: 15px !important; width: 102px !important; font: 12px/15px arial !important; height: 60px !important; margin: 3px 0 0 0 !important; padding: 0 !important; overflow: hidden !important;">[集群]详解LVS的工作模式之NAT的实现</font>
                    </a>
                </td>
                <td width="102" valign="top" style="padding: 5px !important; margin: 0 !important; border-left: 1px solid #DDDDDD !important;">
                    <a target="_blank" title="Linux时间戳转换" style="text-decoration: none !important; cursor: pointer !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F1622.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F54.html">
                        <img style="margin: 0 !important; padding: 2px !important; border: 1px solid #DDDDDD !important; width: 96px !important; height: 96px !important;" src="http://static.wumii.com/images/blogWidget/wordpress_default.gif" width="96px" height="96px" /><br />
                        <font size="-1" color="#333333" style="display: block !important; line-height: 15px !important; width: 102px !important; font: 12px/15px arial !important; height: 60px !important; margin: 3px 0 0 0 !important; padding: 0 !important; overflow: hidden !important;">Linux时间戳转换</font>
                    </a>
                </td>
                <td width="102" valign="top" style="padding: 5px !important; margin: 0 !important; border-left: 1px solid #DDDDDD !important;">
                    <a target="_blank" title="linux位数和cpu" style="text-decoration: none !important; cursor: pointer !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F461.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F54.html">
                        <img style="margin: 0 !important; padding: 2px !important; border: 1px solid #DDDDDD !important; width: 96px !important; height: 96px !important;" src="http://static.wumii.com/images/blogWidget/wordpress_default.gif" width="96px" height="96px" /><br />
                        <font size="-1" color="#333333" style="display: block !important; line-height: 15px !important; width: 102px !important; font: 12px/15px arial !important; height: 60px !important; margin: 3px 0 0 0 !important; padding: 0 !important; overflow: hidden !important;">linux位数和cpu</font>
                    </a>
                </td>
        </tr>
    
    <tr>
        <td colspan="4" align="right">
            <a style="text-decoration: none !important;" href="http://www.wumii.com/widget/relatedItems.htm" target="_blank" title="无觅相关文章插件">
                <font size="-1" color="#bbbbbb" style="display: block !important; font-family: arial !important; padding: 5px 0 !important; font-size: 12px !important; color: #bbb !important;">无觅</font>
            </a>
        </td>
    </tr>
</table>]]></description>
			<content:encoded><![CDATA[<p>1.请简要什么是集群技术？为什么要使用集群技术？</p>
<blockquote><p>集群是一组协同工作的服务实体，用以提供比单一服务实体<strong>更具扩展性和可用性</strong>的服务平台。</p></blockquote>
<p>2.请说出你所知道的集群种类，和实现方案？</p>
<blockquote><p>目前Linux下的集群主要有三种类型 </p>
<p>1. HA (High Availability) </p>
<p>2. LB (Load Balancing) </p>
<p>3. HPC (High performance Computing) </p>
<p>○ DC (Distributed Computing) </p></blockquote>
<blockquote><p>○ PC (Parallel Computing)</p></blockquote>
<p><span id="more-54"></span></p>
<p>高性能计算集群（High Performance Compute clustering）（如 Beowulf）使用多个机器来为需要大量计算能力的任务提供更强大的计算能力。RHEL没有内嵌这类集群的解决方案。 </p>
<p>高可用性集群（High-availability clustering）使用多个机器来为某个服务或某组服务提供额外的可靠性。 </p>
<p>负载均衡集群（Load-balance clustering）使用特殊的路由技术来给一组服务器分配任务。 </p>
<p>RedHat提供了后两种集群技术的解决方案。使用一组程序来监视该系统和集群中的服务的健康状况。</p>
<p>虽然集群系统并不能解决所有的系统问题，但是它能够帮助系统管理员最大限度地利用现有的资源。并不是所有的程序都适用于集群系统，但是常见的系统应用如HTTP服务，FTP服务，数据库服务都可以利用集群系统来增强它们的功能。</p>
<p>3.什么时候需要用LB集群？</p>
<blockquote><p>公共WEB服务、FTP服务、数据库服务等高负载服务中。</p></blockquote>
<p>4.什么时候需要使用HA集群？</p>
<blockquote><p>Ha集群主要用于文件服务，WEB服务，数据库服务等关键应用中</p></blockquote>
<p>5.Linux下实现LB集群的项目是？</p>
<blockquote><p>目前在LINUX系统下使用最为广泛的LB集群系统为LVS</p></blockquote>
<p style="margin:0;padding:0;height:1px;overflow:hidden;">
    <script type="text/javascript"><!--
        var wumiiSitePrefix = "http://www.zhangyiqun.net";
        var wumiiEnableCustomPos = false;
        var wumiiParams = "&#038;num=4&#038;mode=3&#038;displayInFeed=1&#038;version=1.0.5.5&#038;pf=WordPress3.2.1";
    //--></script><script type="text/javascript" src="http://widget.wumii.com/ext/relatedItemsWidget.htm"></script><a href="http://www.wumii.com/widget/relatedItems.htm" style="border:0;"><img src="http://static.wumii.com/images/pixel.png" alt="无觅相关文章插件，快速提升流量" style="border:0;padding:0;margin:0;" /></a></p>
<table class="wumii-related-items" cellspacing="0" cellpadding="3" border="0"  style="clear: both;">
    
    <tr>
        <td colspan="4"><b><font size="-1"  style="display: block !important; padding: 20px 0 5px !important;">您可能也喜欢：</font></b></td>
    </tr>
    
        <tr>
                <td width="102" valign="top" style="padding: 5px !important; margin: 0 !important;">
                    <a target="_blank" title="[集群]详解LVS的工作模式之DR的实现" style="text-decoration: none !important; cursor: pointer !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F49.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F54.html">
                        <img style="margin: 0 !important; padding: 2px !important; border: 1px solid #DDDDDD !important; width: 96px !important; height: 96px !important;" src="http://static.wumii.com/site_images/2011/10/31/10075736.gif" width="96px" height="96px" /><br />
                        <font size="-1" color="#333333" style="display: block !important; line-height: 15px !important; width: 102px !important; font: 12px/15px arial !important; height: 60px !important; margin: 3px 0 0 0 !important; padding: 0 !important; overflow: hidden !important;">[集群]详解LVS的工作模式之DR的实现</font>
                    </a>
                </td>
                <td width="102" valign="top" style="padding: 5px !important; margin: 0 !important; border-left: 1px solid #DDDDDD !important;">
                    <a target="_blank" title="[集群]详解LVS的工作模式之NAT的实现" style="text-decoration: none !important; cursor: pointer !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F37.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F54.html">
                        <img style="margin: 0 !important; padding: 2px !important; border: 1px solid #DDDDDD !important; width: 96px !important; height: 96px !important;" src="http://static.wumii.com/site_images/2010/10/03/366188.gif" width="96px" height="96px" /><br />
                        <font size="-1" color="#333333" style="display: block !important; line-height: 15px !important; width: 102px !important; font: 12px/15px arial !important; height: 60px !important; margin: 3px 0 0 0 !important; padding: 0 !important; overflow: hidden !important;">[集群]详解LVS的工作模式之NAT的实现</font>
                    </a>
                </td>
                <td width="102" valign="top" style="padding: 5px !important; margin: 0 !important; border-left: 1px solid #DDDDDD !important;">
                    <a target="_blank" title="Linux时间戳转换" style="text-decoration: none !important; cursor: pointer !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F1622.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F54.html">
                        <img style="margin: 0 !important; padding: 2px !important; border: 1px solid #DDDDDD !important; width: 96px !important; height: 96px !important;" src="http://static.wumii.com/images/blogWidget/wordpress_default.gif" width="96px" height="96px" /><br />
                        <font size="-1" color="#333333" style="display: block !important; line-height: 15px !important; width: 102px !important; font: 12px/15px arial !important; height: 60px !important; margin: 3px 0 0 0 !important; padding: 0 !important; overflow: hidden !important;">Linux时间戳转换</font>
                    </a>
                </td>
                <td width="102" valign="top" style="padding: 5px !important; margin: 0 !important; border-left: 1px solid #DDDDDD !important;">
                    <a target="_blank" title="linux位数和cpu" style="text-decoration: none !important; cursor: pointer !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.zhangyiqun.net%2F461.html&from=http%3A%2F%2Fwww.zhangyiqun.net%2F54.html">
                        <img style="margin: 0 !important; padding: 2px !important; border: 1px solid #DDDDDD !important; width: 96px !important; height: 96px !important;" src="http://static.wumii.com/images/blogWidget/wordpress_default.gif" width="96px" height="96px" /><br />
                        <font size="-1" color="#333333" style="display: block !important; line-height: 15px !important; width: 102px !important; font: 12px/15px arial !important; height: 60px !important; margin: 3px 0 0 0 !important; padding: 0 !important; overflow: hidden !important;">linux位数和cpu</font>
                    </a>
                </td>
        </tr>
    
    <tr>
        <td colspan="4" align="right">
            <a style="text-decoration: none !important;" href="http://www.wumii.com/widget/relatedItems.htm" target="_blank" title="无觅相关文章插件">
                <font size="-1" color="#bbbbbb" style="display: block !important; font-family: arial !important; padding: 5px 0 !important; font-size: 12px !important; color: #bbb !important;">无觅</font>
            </a>
        </td>
    </tr>
</table>]]></content:encoded>
			<wfw:commentRss>http://www.zhangyiqun.net/54.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

<!-- Performance optimized by W3 Total Cache. Learn more: http://www.w3-edge.com/wordpress-plugins/

Page Caching using disk: enhanced

Served from: www.zhangyiqun.net @ 2012-02-07 22:24:35 -->
