<?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>SupportSages &#187; VPS iptable modules</title>
	<atom:link href="http://www.supportsages.com/blog/tag/vps-iptable-modules/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.supportsages.com/blog</link>
	<description>Technical Support and Server Management : Musings in the fox hole.</description>
	<lastBuildDate>Thu, 02 Sep 2010 18:51:19 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>How to enable IPtable modules on a VPS</title>
		<link>http://www.supportsages.com/blog/2009/08/how-to-enable-iptable-modules-on-a-vps/</link>
		<comments>http://www.supportsages.com/blog/2009/08/how-to-enable-iptable-modules-on-a-vps/#comments</comments>
		<pubDate>Wed, 12 Aug 2009 05:19:26 +0000</pubDate>
		<dc:creator>Fabian</dc:creator>
				<category><![CDATA[Security]]></category>
		<category><![CDATA[VPS]]></category>
		<category><![CDATA[enable iptable modules for VPS]]></category>
		<category><![CDATA[VPS iptable modules]]></category>

		<guid isPermaLink="false">http://www.supportsages.com/blog/?p=520</guid>
		<description><![CDATA[Before trying to enable iptable modules on the VPS, make sure that those modules are enabled on the root node server. To check whether the particular iptable modules are enabled or not on the root node, execute the following command.
<blockquote>lsmod</blockquote>
A Sample out put for the lsmod is :
<blockquote>Module                  Size  Used by
xt_helper              35584  0
ip_conntrack_ftp       42320  2
ipt_LOG                39808  0
ipt_owner              34944  0
ipt_REDIRECT           34944  0
ipt_recent             43404  2
xt_state               35200  5
sch_sfq                38912  1
cls_u32                41352  1
sch_cbq                50688  1
ppp_deflate            39168  0
zlib_deflate           52760  1 ppp_deflate
ppp_async              45184  0
ppp_generic            62624  2 ppp_deflate,ppp_async
slhc                   39552  1 ppp_generic
crc_ccitt              35200  1 ppp_async
tun                    47872  0
vzethdev               47264  0
simfs                  38296  36
vzrst                 173096  0
vzcpt                 148792  0
vzdquota               78832  36 [permanent]
xt_tcpudp              ...]]></description>
			<content:encoded><![CDATA[<p>Before trying to enable iptable modules on the VPS, make sure that those modules are enabled on the root node server. To check whether the particular iptable modules are enabled or not on the root node, execute the following command.</p>
<blockquote><p>lsmod</p></blockquote>
<p>A Sample out put for the lsmod is :</p>
<blockquote><p>Module                  Size  Used by<br />
xt_helper              35584  0<br />
ip_conntrack_ftp       42320  2<br />
ipt_LOG                39808  0<br />
ipt_owner              34944  0<br />
ipt_REDIRECT           34944  0<br />
ipt_recent             43404  2<br />
xt_state               35200  5<br />
sch_sfq                38912  1<br />
cls_u32                41352  1<br />
sch_cbq                50688  1<br />
ppp_deflate            39168  0<br />
zlib_deflate           52760  1 ppp_deflate<br />
ppp_async              45184  0<br />
ppp_generic            62624  2 ppp_deflate,ppp_async<br />
slhc                   39552  1 ppp_generic<br />
crc_ccitt              35200  1 ppp_async<br />
tun                    47872  0<br />
vzethdev               47264  0<br />
simfs                  38296  36<br />
vzrst                 173096  0<br />
vzcpt                 148792  0<br />
vzdquota               78832  36 [permanent]<br />
xt_tcpudp              36224  21<br />
xt_length              34944  0<br />
ipt_ttl                34816  0<br />
xt_tcpmss              35328  0<br />
ipt_TCPMSS             37248  0<br />
iptable_mangle         37888  36<br />
xt_multiport           36224  0<br />
xt_limit               36352  4<br />
ipt_tos                34560  0<br />
ipt_REJECT             39556  1<br />
iptable_nat            43532  46<br />
ip_nat                 53392  3 ipt_REDIRECT,vzrst,iptable_nat<br />
iptable_filter         37760  42<br />
ip_conntrack          100884  29 xt_helper,ip_conntrack_ftp,xt_state,vzrst,vzcpt,iptable_nat,ip_nat<br />
nfnetlink              40392  2 ip_nat,ip_conntrack<br />
ip_tables              57440  3 iptable_mangle,iptable_nat,iptable_filter<br />
x_tables               52744  17 xt_helper,ipt_LOG,ipt_owner,ipt_REDIRECT,ipt_recent,xt_state,xt_tcpudp,xt_length,ipt_ttl,xt_tcpmss,ipt_TCPMSS,xt_multiport,xt_limit,ipt_tos,ipt_REJECT,iptable_nat,ip_tables<br />
autofs4                57480  2<br />
hidp                   83584  2<br />
rfcomm                105000  0</p></blockquote>
<p>Here we can see most of the modules are already enabled on the node server. If not enabled, execute the following commands one by one to enable those.</p>
<blockquote><p>modprobe ipt_helper<br />
modprobe ipt_REDIRECT<br />
modprobe ipt_state<br />
modprobe ipt_TCPMSS<br />
modprobe ipt_LOG<br />
modprobe ipt_TOS<br />
modprobe iptable_nat<br />
modprobe ipt_length<br />
modprobe ipt_tcpmss<br />
modprobe iptable_mangle<br />
modprobe ipt_limit<br />
modprobe ipt_tos<br />
modprobe iptable_filter<br />
modprobe ipt_helper<br />
modprobe ipt_tos<br />
modprobe ipt_ttl<br />
modprobe ipt_REJECT<br />
modprobe ipt_helper<br />
modprobe ipt_owner</p></blockquote>
<p>Next step is to enable these modules on the VPS.</p>
<p>Stop the container first :  vzctl stop 960 ( replace 960 with the concerned VPS ID )</p>
<p>Execute the following command :</p>
<blockquote><p>vzctl set 960 &#8211;iptables ipt_REJECT &#8211;iptables ipt_tos &#8211;iptables ipt_TOS &#8211;iptables ipt_LOG &#8211;iptables ip_conntrack &#8211;iptables ipt_limit &#8211;iptables ipt_multiport &#8211;iptables iptable_filter &#8211;iptables iptable_mangle &#8211;iptables ipt_TCPMSS &#8211;iptables ipt_tcpmss &#8211;iptables ipt_ttl &#8211;iptables ipt_length &#8211;iptables ipt_state &#8211;iptables iptable_nat &#8211;iptables ip_nat_ftp &#8211;iptables ip_conntrack_ftp &#8211;iptables ip_conntrack_irc &#8211;iptables ip_nat_irc &#8211;iptables ipt_owner &#8211;iptables ipt_helper &#8211;save</p></blockquote>
<p>Start the container : vzctl start 960</p>
<p>check whether the modules are enabled from the configuration file cat /etc/vz/conf/960.conf. You are DONE.</p>
<p>Please note that if the command &#8220;vzctl set 960 &#8211;iptables ipt_ &#8230;.&#8221; is executed for the second time for the same VPS, it will over write the previous configuration.</p>
<p><strong>For enabling it on all VPSes, please add to /etc/sysconfig/vz all those modules like IPTABLES=&#8221;module1 module2 &#8230;.etc&#8221;</strong></p>
<p align="left"><a  class="tt" href="http://twitter.com/home/?status=How+to+enable+IPtable+modules+on+a+VPS++http%3A%2F%2Fwww.supportsages.com%2Fblog%2F520" title="Post to Twitter"><img class="nothumb" src="http://www.supportsages.com/blog/wp-content/plugins/tweet-this/icons/tt-twitter.png" alt="Post to Twitter" /></a> <a  class="tt" href="http://twitter.com/home/?status=How+to+enable+IPtable+modules+on+a+VPS++http%3A%2F%2Fwww.supportsages.com%2Fblog%2F520" title="Post to Twitter">Tweet This Post</a></p>]]></content:encoded>
			<wfw:commentRss>http://www.supportsages.com/blog/2009/08/how-to-enable-iptable-modules-on-a-vps/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
