<?xml version="1.0" encoding="utf-8"?>
<rss version="0.92">
	<channel>
		<title>水月日记</title>
		<link>http://iii80.com//</link>
		<copyright>Copyright (C) 2004 Security Angel Team [S4T] All Rights Reserved.</copyright>
		<language>zh</language>
		<item>
			<title>LNMP 一键安装包平滑升级 Nginx 到最新版本</title>
			<author>水中月</author>
			<description><![CDATA[<p>LNMP 一键安装包平滑升级 Nginx 到最新版本</p>
<p><font color="#3b5998">nginx</font>现在的最新开发版本是0.8.40 ,一些网友就是喜欢最新版本,都问我的<font color="#3b5998">LNMP</font>一键安装包怎么升级 Nginx 到最新版本 ,现在,只要你简单的执行几句命令,就可以将 Nginx 升级到最新版本 ,只适合我的<font color="#3b5998">LNMP</font>一键安装包,如果你知道你的LNMP安装启动的路径,也可以用这个方法的.</p>
<p>首先下最新版本,解压缩编译</p>
<div class="codecolorer-container text default" style="OVERFLOW: auto; WIDTH: 600px; WHITE-SPACE: nowrap">
<div class="text codecolorer">wget http://nginx.org/download/nginx-0.8.40.tar.gz<br />tar zxvf nginx-0.8.40.tar.gz<br />cd nginx-0.8.40<br />./configure --user=www --group=www --prefix=/usr/local/nginx --with-http_stub_status_module --with-http_ssl_module --with-http_gzip_static_module --with-ld-opt='-ltcmalloc_minimal'<br />make</div>
</div>
<p>一定不要make install !!!!!<br /><span id="more-1295"></span></p>
<p>接着备份原来的 nginx 文件</p>
<div class="codecolorer-container text default" style="OVERFLOW: auto; WIDTH: 600px; WHITE-SPACE: nowrap">
<div class="text codecolorer">mv /usr/local/nginx/sbin/nginx /usr/local/nginx/sbin/nginx.old</div>
</div>
<p>然后复制编译好的 nginx 文件到/usr/local/nginx/sbin/nginx</p>
<div class="codecolorer-container text default" style="OVERFLOW: auto; WIDTH: 600px; WHITE-SPACE: nowrap">
<div class="text codecolorer">cp objs/nginx /usr/local/nginx/sbin/nginx</div>
</div>
<p>检测nginx文件配置</p>
<div class="codecolorer-container text default" style="OVERFLOW: auto; WIDTH: 600px; WHITE-SPACE: nowrap">
<div class="text codecolorer">/usr/local/nginx/sbin/nginx -t</div>
</div>
<p>直接重启Nginx</p>
<div class="codecolorer-container text default" style="OVERFLOW: auto; WIDTH: 600px; WHITE-SPACE: nowrap">
<div class="text codecolorer">/etc/init.d/nginx restart</div>
</div>
<p>或者</p>
<div class="codecolorer-container text default" style="OVERFLOW: auto; WIDTH: 600px; WHITE-SPACE: nowrap">
<div class="text codecolorer">kill -HUP `cat /usr/local/nginx/nginx.pid`</div>
</div>
<p>效果:<a href="http://vps.imcat.in/" target="_blank"><font color="#3b5998">http://vps.imcat.in/</font></a><br /><strong>BTW</strong></p>
<p>如果需要更改header信息的话,可以修改nginx.h文件</p>
<div class="codecolorer-container text default" style="OVERFLOW: auto; WIDTH: 600px; WHITE-SPACE: nowrap">
<div class="text codecolorer">vi src/core/nginx.h</div>
</div>
<p>找到</p>
<div class="codecolorer-container text default" style="OVERFLOW: auto; WIDTH: 600px; WHITE-SPACE: nowrap">
<div class="text codecolorer">#define NGINX_VERSION      "0.7.62"<br />#define NGINX_VER          "nginx/" NGINX_VERSION</div>
</div>
<p>上面的版本号和nginx可以自己修改,例如:</p>
<div class="codecolorer-container text default" style="OVERFLOW: auto; WIDTH: 600px; WHITE-SPACE: nowrap">
<div class="text codecolorer">#define NGINX_VERSION      "2010"<br />#define NGINX_VER          "Imcat/" NGINX_VERSION</div>
</div>
<p><strong>BTW</strong><br />关闭debug模式可以减少nginx文件的大小</p>
<div class="codecolorer-container text default" style="OVERFLOW: auto; WIDTH: 600px; WHITE-SPACE: nowrap">
<div class="text codecolorer">vi auto/cc/gcc</div>
</div>
<p>找到这行,注释掉</p>
<div class="codecolorer-container text default" style="OVERFLOW: auto; WIDTH: 600px; WHITE-SPACE: nowrap">
<div class="text codecolorer">#CFLAGS=&rdquo;$CFLAGS -g&rdquo;</div>
</div>]]></description>
			<link>http://iii80.com//?action=show&amp;id=532</link>
			<pubDate>2010-08-30 11:39</pubDate>
		</item>
		<item>
			<title>jDownloader使用教程(网盘专用下载工具)</title>
			<author>水中月</author>
			<description><![CDATA[<p>jDownloader使用教程(网盘专用下载工具)</p>
<div class="tit"> </div>
<p>
<table style="TABLE-LAYOUT: fixed; WIDTH: 100%">
    <tbody>
        <tr>
            <td>
            <div class="cnt" id="blog_text"><span class="Apple-style-span" style="WORD-SPACING: 0px; FONT: 12px Simsun; TEXT-TRANSFORM: none; COLOR: rgb(0,0,0); TEXT-INDENT: 0px; WHITE-SPACE: normal; LETTER-SPACING: normal; BORDER-COLLAPSE: separate; widows: 2; orphans: 2; webkit-border-horizontal-spacing: 0px; webkit-border-vertical-spacing: 0px; webkit-text-decorations-in-effect: none; webkit-text-size-adjust: auto; webkit-text-stroke-width: 0px"><span class="Apple-style-span" style="FONT-SIZE: 14px; COLOR: rgb(51,51,51); LINE-HEIGHT: 24px; BORDER-COLLAPSE: collapse"><img style="BORDER-TOP-WIDTH: 0px; BORDER-LEFT-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; BORDER-RIGHT-WIDTH: 0px; outline-style: none" src="http://pic.qnpic.com:83/r.jsp?fn=//yeyige/share/2010/3/31/11270019595891.jpg" width="800" border="0" onxxxx="if(this.offsetWidth>'800')this.width='800';if(this.offsetHeight>'2000')this.height='2000';" onxxxxx="if(this.width>=800) window.open('http://pic.qnpic.com:83/r.jsp?fn=//yeyige/share/2010/3/31/11270019595891.jpg');" alt="" /><span class="Apple-converted-space"> </span><br style="outline-style: none" /><br style="outline-style: none" /><br style="outline-style: none" /><span style="COLOR: rgb(255,0,0); outline-style: none"><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体 ">这是现在最好的下载网盘资源工具了：<span class="Apple-converted-space"> </span><br style="outline-style: none" /><br style="outline-style: none" /><font style="LINE-HEIGHT: 1.5em; outline-style: none" size="6">１、可以自动更改IP，免掉你下载等待的时间；</font></font></span><span class="Apple-converted-space"> </span><br style="outline-style: none" /><br style="outline-style: none" /><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><span style="COLOR: rgb(255,0,0); outline-style: none"><font style="LINE-HEIGHT: 1.5em; outline-style: none" size="6">２、验证码自动识别，免除你需要守候的问题。</font></span></font></font></font></font></font><span class="Apple-converted-space"> </span><br style="outline-style: none" /><br style="outline-style: none" /><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><span style="COLOR: rgb(255,0,0); outline-style: none"><font style="LINE-HEIGHT: 1.5em; outline-style: none" size="6">只需要一次性复制</font></span></font></font></font></font></font><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><span style="COLOR: rgb(0,0,0); outline-style: none"><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><font style="LINE-HEIGHT: 1.5em; outline-style: none" size="4"><span style="COLOR: rgb(255,0,0); outline-style: none">所有连接到剪贴板，剩下的从下载到解压它可以一条龙帮你完全搞定</span>。</font></font></font></font></font></span></font><span class="Apple-converted-space"> </span><br style="outline-style: none" /><br style="outline-style: none" /><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><span style="COLOR: rgb(0,0,0); outline-style: none"><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  ">呵呵唯一的要求是需要安装JAVA支持，需要使用这个工具的朋友可以</font></font></font></font></span></font><span class="Apple-converted-space"> </span><br style="outline-style: none" /><br style="outline-style: none" /><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><span style="COLOR: rgb(0,0,0); outline-style: none"><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  ">到</font><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><a style="COLOR: rgb(0,112,175); TEXT-DECORATION: none; outline-style: none" href="http://www.java.com/zh_CN/download/index.jsp" target="_blank" onxxxxx="return checkUrl(this)"><span style="COLOR: rgb(72,132,207); outline-style: none">http://www.java.com/zh_CN/download/index.jsp</span></a></font><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  ">下载安装，装过后就可以使用这个工具了。</font></font></font></font></span></font><span class="Apple-converted-space"> </span><br style="outline-style: none" /><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><span style="COLOR: rgb(0,0,0); outline-style: none"><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><br style="outline-style: none" /></font></font></font></span></font><br style="outline-style: none" /><br style="outline-style: none" /><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><span style="COLOR: rgb(0,0,0); outline-style: none"><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  ">下面讲一下安装和设置的过程（具体到不同的版本，可能会稍有不同）：</font></font></font></font></font></span></font><span class="Apple-converted-space"> </span><br style="outline-style: none" /><br style="outline-style: none" /><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><span style="COLOR: rgb(0,0,0); outline-style: none"><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  ">1、解压以后，运行目录中</font><strong style="outline-style: none"><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  ">JDownloader</font></strong><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  ">.exe</font><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  ">，</font></font></font></font></font></span></font><span class="Apple-converted-space"> </span><br style="outline-style: none" /><br style="outline-style: none" /><br style="outline-style: none" /><br style="outline-style: none" /><img style="BORDER-TOP-WIDTH: 0px; BORDER-LEFT-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; BORDER-RIGHT-WIDTH: 0px; outline-style: none" src="http://pic.qnpic.com:83/r.jsp?fn=//yeyige/share/2010/3/31/21270019762375.jpg" width="800" border="0" onxxxx="if(this.offsetWidth>'800')this.width='800';if(this.offsetHeight>'2000')this.height='2000';" onxxxxx="if(this.width>=800) window.open('http://pic.qnpic.com:83/r.jsp?fn=//yeyige/share/2010/3/31/21270019762375.jpg');" alt="" /><span class="Apple-converted-space"> </span><br style="outline-style: none" /><br style="outline-style: none" /><br style="outline-style: none" /><br style="outline-style: none" /><br style="outline-style: none" /><br style="outline-style: none" /><img style="BORDER-TOP-WIDTH: 0px; BORDER-LEFT-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; BORDER-RIGHT-WIDTH: 0px; outline-style: none" src="http://pic.qnpic.com:83/r.jsp?fn=//yeyige/share/2010/3/31/31270019787203.jpg" border="0" onxxxx="if(this.offsetWidth>'800')this.width='800';if(this.offsetHeight>'2000')this.height='2000';" onxxxxx="if(this.width>=800) window.open('http://pic.qnpic.com:83/r.jsp?fn=//yeyige/share/2010/3/31/31270019787203.jpg');" alt="" /><span class="Apple-converted-space"> </span><br style="outline-style: none" /><br style="outline-style: none" /><br style="outline-style: none" /><br style="outline-style: none" /><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体 ">2、选择安装的语言</font><span class="Apple-converted-space"> </span><br style="outline-style: none" /><br style="outline-style: none" /><br style="outline-style: none" /><br style="outline-style: none" /><br style="outline-style: none" /><img style="BORDER-TOP-WIDTH: 0px; BORDER-LEFT-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; BORDER-RIGHT-WIDTH: 0px; outline-style: none" src="http://pic.qnpic.com:83/r.jsp?fn=//yeyige/share/2010/3/31/41270019857328.jpg" width="800" border="0" onxxxx="if(this.offsetWidth>'800')this.width='800';if(this.offsetHeight>'2000')this.height='2000';" onxxxxx="if(this.width>=800) window.open('http://pic.qnpic.com:83/r.jsp?fn=//yeyige/share/2010/3/31/41270019857328.jpg');" alt="" /><span class="Apple-converted-space"> </span><br style="outline-style: none" /><br style="outline-style: none" /><br style="outline-style: none" /><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体 ">这里可以选择中文<strong style="outline-style: none">Chinese(Simplified)，</strong>找到它单击</font><span class="Apple-converted-space"> </span><br style="outline-style: none" /><br style="outline-style: none" /><br style="outline-style: none" /><br style="outline-style: none" /><br style="outline-style: none" /><img style="BORDER-TOP-WIDTH: 0px; BORDER-LEFT-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; BORDER-RIGHT-WIDTH: 0px; outline-style: none" src="http://pic.qnpic.com:83/r.jsp?fn=//yeyige/share/2010/3/31/51270019938984.jpg" width="800" border="0" onxxxx="if(this.offsetWidth>'800')this.width='800';if(this.offsetHeight>'2000')this.height='2000';" onxxxxx="if(this.width>=800) window.open('http://pic.qnpic.com:83/r.jsp?fn=//yeyige/share/2010/3/31/51270019938984.jpg');" alt="" /><span class="Apple-converted-space"> </span><br style="outline-style: none" /><br style="outline-style: none" /><br style="outline-style: none" /><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体 ">选择语言后的界面，在此也可设置默认下载目录，单击&ldquo;确定&rdquo;</font><span class="Apple-converted-space"> </span><br style="outline-style: none" /><br style="outline-style: none" /><br style="outline-style: none" /><img style="BORDER-TOP-WIDTH: 0px; BORDER-LEFT-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; BORDER-RIGHT-WIDTH: 0px; outline-style: none" src="http://pic.qnpic.com:83/r.jsp?fn=//yeyige/share/2010/3/31/6.jpg" border="0" onxxxx="if(this.offsetWidth>'800')this.width='800';if(this.offsetHeight>'2000')this.height='2000';" onxxxxx="if(this.width>=800) window.open('http://pic.qnpic.com:83/r.jsp?fn=//yeyige/share/2010/3/31/6.jpg');" alt="" /><span class="Apple-converted-space"> </span><br style="outline-style: none" /><br style="outline-style: none" /><br style="outline-style: none" /><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体 ">3、在这个界面会安装一个插件，点&ldquo;确定&rdquo;<span class="Apple-converted-space"> </span></font><br style="outline-style: none" /><br style="outline-style: none" /><span style="COLOR: rgb(0,0,0); outline-style: none"><img style="BORDER-TOP-WIDTH: 0px; BORDER-LEFT-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; BORDER-RIGHT-WIDTH: 0px; outline-style: none" src="http://pic.qnpic.com:83/r.jsp?fn=//yeyige/share/2010/3/31/7.jpg" border="0" onxxxx="if(this.offsetWidth>'800')this.width='800';if(this.offsetHeight>'2000')this.height='2000';" onxxxxx="if(this.width>=800) window.open('http://pic.qnpic.com:83/r.jsp?fn=//yeyige/share/2010/3/31/7.jpg');" alt="" /></span><span class="Apple-converted-space"> </span><br style="outline-style: none" /><br style="outline-style: none" /><br style="outline-style: none" /><span style="COLOR: rgb(0,0,0); outline-style: none">再&ldquo;确定&rdquo;<span class="Apple-converted-space"> </span><br style="outline-style: none" /></span><br style="outline-style: none" /><span style="COLOR: rgb(0,0,0); outline-style: none"><img style="BORDER-TOP-WIDTH: 0px; BORDER-LEFT-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; BORDER-RIGHT-WIDTH: 0px; outline-style: none" src="http://pic.qnpic.com:83/r.jsp?fn=//yeyige/share/2010/3/31/8.jpg" border="0" onxxxx="if(this.offsetWidth>'800')this.width='800';if(this.offsetHeight>'2000')this.height='2000';" onxxxxx="if(this.width>=800) window.open('http://pic.qnpic.com:83/r.jsp?fn=//yeyige/share/2010/3/31/8.jpg');" alt="" /></span><span class="Apple-converted-space"> </span><br style="outline-style: none" /><br style="outline-style: none" />4、单击&ldquo;确定&rdquo;，添加信息到注册表<span class="Apple-converted-space"> </span><br style="outline-style: none" /><br style="outline-style: none" /><img style="BORDER-TOP-WIDTH: 0px; BORDER-LEFT-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; BORDER-RIGHT-WIDTH: 0px; outline-style: none" src="http://rgfxsa.blu.livefilestore.com/y1pH8oVAF7fB8fd8Bq7HE5CEKF0qIn0TN_BURb_qTrcU7E92zWwvNiBzSpctTD3OAWKcaJlOAKDCiJwsgqtWA4HIoh0mIuvgyq3/1270365926_600999.jpg" border="0" onxxxx="if(this.offsetWidth>'800')this.width='800';if(this.offsetHeight>'2000')this.height='2000';" onxxxxx="if(this.width>=800) window.open('http://rgfxsa.blu.livefilestore.com/y1pH8oVAF7fB8fd8Bq7HE5CEKF0qIn0TN_BURb_qTrcU7E92zWwvNiBzSpctTD3OAWKcaJlOAKDCiJwsgqtWA4HIoh0mIuvgyq3/1270365926_600999.jpg');" alt="" /><span class="Apple-converted-space"> </span><br style="outline-style: none" /><br style="outline-style: none" /><br style="outline-style: none" /><br style="outline-style: none" />再&ldquo;确定&rdquo;<span class="Apple-converted-space"> </span><br style="outline-style: none" /><br style="outline-style: none" /><img style="BORDER-TOP-WIDTH: 0px; BORDER-LEFT-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; BORDER-RIGHT-WIDTH: 0px; outline-style: none" src="http://rgfxsa.blu.livefilestore.com/y1pe7kNPnngSEPbHI6ovtVyW74FibUSsnXPbrXXdejhcJSUzIwx63yI6x6GUO0D267vC__N7WsgxroAMqXogaP0YlaDCWh8wJCn/1270365927_812772.jpg" border="0" onxxxx="if(this.offsetWidth>'800')this.width='800';if(this.offsetHeight>'2000')this.height='2000';" onxxxxx="if(this.width>=800) window.open('http://rgfxsa.blu.livefilestore.com/y1pe7kNPnngSEPbHI6ovtVyW74FibUSsnXPbrXXdejhcJSUzIwx63yI6x6GUO0D267vC__N7WsgxroAMqXogaP0YlaDCWh8wJCn/1270365927_812772.jpg');" alt="" /><span class="Apple-converted-space"> </span><br style="outline-style: none" /><br style="outline-style: none" /><br style="outline-style: none" /><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体 ">5、之后就会自动启动JD了，此时会进行软件更新，每次&rdquo;确定&rdquo;即可。请耐心的等一会，或去喝杯茶&hellip;&hellip;</font><span class="Apple-converted-space"> </span><br style="outline-style: none" /><br style="outline-style: none" /><br style="outline-style: none" /><br style="outline-style: none" /><br style="outline-style: none" /><img style="BORDER-TOP-WIDTH: 0px; BORDER-LEFT-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; BORDER-RIGHT-WIDTH: 0px; outline-style: none" src="http://rgfxsa.blu.livefilestore.com/y1pBoQJY6lq9qswaLd7a8uC1w3dXODILFYiaOEW49jVrNvkFaSLwKZGQcMr6tXymfWsno3gLEKy4HBEPEtHh6rb_JIdq9vOxQSs/1270365928_606935.jpg" border="0" onxxxx="if(this.offsetWidth>'800')this.width='800';if(this.offsetHeight>'2000')this.height='2000';" onxxxxx="if(this.width>=800) window.open('http://rgfxsa.blu.livefilestore.com/y1pBoQJY6lq9qswaLd7a8uC1w3dXODILFYiaOEW49jVrNvkFaSLwKZGQcMr6tXymfWsno3gLEKy4HBEPEtHh6rb_JIdq9vOxQSs/1270365928_606935.jpg');" alt="" /><br style="outline-style: none" /><br style="outline-style: none" /><br style="outline-style: none" /><br style="outline-style: none" /><br style="outline-style: none" />下面是下载更新界面<span class="Apple-converted-space"> </span><br style="outline-style: none" /><br style="outline-style: none" /><img style="BORDER-TOP-WIDTH: 0px; BORDER-LEFT-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; BORDER-RIGHT-WIDTH: 0px; outline-style: none" src="http://rgfxsa.blu.livefilestore.com/y1pnXaeb_NEDRRNeLM7BeQv5iAPeW3KuWZslHqs3EXgsPfj52Dz2atGY4i_v7i8n1wNyugjbqZLtrYP-J-4rVbWj5fUfB--RaM-/1270365930_784323.jpg" border="0" onxxxx="if(this.offsetWidth>'800')this.width='800';if(this.offsetHeight>'2000')this.height='2000';" onxxxxx="if(this.width>=800) window.open('http://rgfxsa.blu.livefilestore.com/y1pnXaeb_NEDRRNeLM7BeQv5iAPeW3KuWZslHqs3EXgsPfj52Dz2atGY4i_v7i8n1wNyugjbqZLtrYP-J-4rVbWj5fUfB--RaM-/1270365930_784323.jpg');" alt="" /><br style="outline-style: none" /><br style="outline-style: none" /><br style="outline-style: none" /><img style="BORDER-TOP-WIDTH: 0px; BORDER-LEFT-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; BORDER-RIGHT-WIDTH: 0px; outline-style: none" src="http://rgfxsa.blu.livefilestore.com/y1p8FGS0bNFrncu9MfH51WApX_umSvPeTm-lXzCIyLvvaP-3C_-CPbu9rKNTCnHLY-Ts5Jcta3L0fQOGTbQ5AX5PKwaJLcxOoYu/1270365927_317101.jpg" border="0" onxxxx="if(this.offsetWidth>'800')this.width='800';if(this.offsetHeight>'2000')this.height='2000';" onxxxxx="if(this.width>=800) window.open('http://rgfxsa.blu.livefilestore.com/y1p8FGS0bNFrncu9MfH51WApX_umSvPeTm-lXzCIyLvvaP-3C_-CPbu9rKNTCnHLY-Ts5Jcta3L0fQOGTbQ5AX5PKwaJLcxOoYu/1270365927_317101.jpg');" alt="" /><br style="outline-style: none" /><br style="outline-style: none" /><br style="outline-style: none" /><br style="outline-style: none" /><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体 ">6、更新完毕以后，需对软件进行一点基本的设置<span style="COLOR: rgb(255,0,0); outline-style: none">（见下图），</span>点击&ldquo;设置&rdquo;选项卡，打开基本设置界面，根据需要进行一些基本的设置。如下图：</font><span class="Apple-converted-space"> </span><br style="outline-style: none" /><br style="outline-style: none" /><img style="BORDER-TOP-WIDTH: 0px; BORDER-LEFT-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; BORDER-RIGHT-WIDTH: 0px; outline-style: none" src="http://rgfxsa.blu.livefilestore.com/y1povkT9Ec8kseT9x7xKaDcLxJDptDxKgu1nBceudjOHI-MjcoR_xwCKmVQrfEiS65PJkx6MNHJ04GCx5Q1kUdaANeCvwOEZCCk/1270365966_162113.jpg" border="0" onxxxx="if(this.offsetWidth>'800')this.width='800';if(this.offsetHeight>'2000')this.height='2000';" onxxxxx="if(this.width>=800) window.open('http://rgfxsa.blu.livefilestore.com/y1povkT9Ec8kseT9x7xKaDcLxJDptDxKgu1nBceudjOHI-MjcoR_xwCKmVQrfEiS65PJkx6MNHJ04GCx5Q1kUdaANeCvwOEZCCk/1270365966_162113.jpg');" alt="" /><br style="outline-style: none" /><br style="outline-style: none" /><br style="outline-style: none" /><br style="outline-style: none" /><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体 ">下面以最常用的网盘rapidshare<span style="COLOR: rgb(0,0,0); outline-style: none">为例子，进行设置，具体见下图：</span></font><span class="Apple-converted-space"> </span><br style="outline-style: none" /><br style="outline-style: none" /><br style="outline-style: none" /><br style="outline-style: none" /><img style="BORDER-TOP-WIDTH: 0px; BORDER-LEFT-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; BORDER-RIGHT-WIDTH: 0px; outline-style: none" src="http://rgfxsa.blu.livefilestore.com/y1p4gSAZ8IyGamLGBn5_uXtTkL_UULzHDQJeaVvGXqhzz6NDnKEFTV48QFaL4D-_HqgIt0Dxu_Y6sr7ksERshvYsP3meVg5bFJJ/1270365942_712491.jpg" border="0" onxxxx="if(this.offsetWidth>'800')this.width='800';if(this.offsetHeight>'2000')this.height='2000';" onxxxxx="if(this.width>=800) window.open('http://rgfxsa.blu.livefilestore.com/y1p4gSAZ8IyGamLGBn5_uXtTkL_UULzHDQJeaVvGXqhzz6NDnKEFTV48QFaL4D-_HqgIt0Dxu_Y6sr7ksERshvYsP3meVg5bFJJ/1270365942_712491.jpg');" alt="" /><br style="outline-style: none" /><br style="outline-style: none" /><br style="outline-style: none" /><br style="outline-style: none" /><br style="outline-style: none" /><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体 "><font style="LINE-HEIGHT: 1.5em; outline-style: none" size="3">设置完毕后，就可以使用了（当然，还有好多功能等待我们去挖掘）<span class="Apple-converted-space"> </span><br style="outline-style: none" />比如：软件可以对压缩包自动解压：</font></font><span class="Apple-converted-space"> </span><br style="outline-style: none" /><br style="outline-style: none" /><img style="BORDER-TOP-WIDTH: 0px; BORDER-LEFT-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; BORDER-RIGHT-WIDTH: 0px; outline-style: none" src="http://rgfxsa.blu.livefilestore.com/y1pf03AF4gmj4JuS9qgeFmhqfmLKwTp-es9-ph6foEQkiXrFjYxflz-bNBUybO8OqAL7O46hmW0AudlnffC0ThreCJRjUuCmBin/1270365967_589873.jpg" width="800" border="0" onxxxx="if(this.offsetWidth>'800')this.width='800';if(this.offsetHeight>'2000')this.height='2000';" onxxxxx="if(this.width>=800) window.open('http://rgfxsa.blu.livefilestore.com/y1pf03AF4gmj4JuS9qgeFmhqfmLKwTp-es9-ph6foEQkiXrFjYxflz-bNBUybO8OqAL7O46hmW0AudlnffC0ThreCJRjUuCmBin/1270365967_589873.jpg');" alt="" /><br style="outline-style: none" /><br style="outline-style: none" /><br style="outline-style: none" /><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体 "><font style="LINE-HEIGHT: 1.5em; outline-style: none" size="3">如果压缩包有密码，在下图所示位置填上解压密码</font></font><span class="Apple-converted-space"> </span><br style="outline-style: none" /><br style="outline-style: none" /><br style="outline-style: none" /><img style="BORDER-TOP-WIDTH: 0px; BORDER-LEFT-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; BORDER-RIGHT-WIDTH: 0px; outline-style: none" src="http://rgfxsa.blu.livefilestore.com/y1pBGrEmpCyeFSOUPNuYkqeQAsnQ5gXIr31h8jz4Jf4fbqT-9h73ZILPxPPLW6CR_76N44FnyicXZzM6OEdwlRrtnzm4NKLgBb7/1270365971_367090.jpg" width="800" border="0" onxxxx="if(this.offsetWidth>'800')this.width='800';if(this.offsetHeight>'2000')this.height='2000';" onxxxxx="if(this.width>=800) window.open('http://rgfxsa.blu.livefilestore.com/y1pBGrEmpCyeFSOUPNuYkqeQAsnQ5gXIr31h8jz4Jf4fbqT-9h73ZILPxPPLW6CR_76N44FnyicXZzM6OEdwlRrtnzm4NKLgBb7/1270365971_367090.jpg');" alt="" /><br style="outline-style: none" /><br style="outline-style: none" /><br style="outline-style: none" /><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体 "><font style="LINE-HEIGHT: 1.5em; outline-style: none" size="3"><span style="COLOR: rgb(255,0,0); outline-style: none"><font style="LINE-HEIGHT: 1.5em; outline-style: none" size="6">下面讲解一下工具的基本使用：<span class="Apple-converted-space"> </span><br style="outline-style: none" /></font></span><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="楷体_gb2312  "><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><br style="outline-style: none" /></font></font></font></font></font></font></font></font></font></font><br style="outline-style: none" /><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="楷体_gb2312  "><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  "><span style="COLOR: rgb(0,0,0); outline-style: none">1、启动JDownloader后，找到需要下载的国外网盘资源链接地址，右键复制，<font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体  ">就会自动弹出&ldquo;添加&rdquo;下载界面，如果未弹出，也可按下图进行操作。</font></span></font></font></font></font></font></font></font></font></font></font></font></font><span class="Apple-converted-space"> </span><br style="outline-style: none" /></font></font><br style="outline-style: none" /><img style="BORDER-TOP-WIDTH: 0px; BORDER-LEFT-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; BORDER-RIGHT-WIDTH: 0px; outline-style: none" src="http://rgfxsa.blu.livefilestore.com/y1pGkVtX_yzZCL8daXsjW8n3w4fQ0Wnh3cH_9OPaKAmsc9_-tfVYFQHxNLwl92WSngaMJGquqzuMCGxXUb8Ti3w54jBFwbkr5ok/1270365974_788657.jpg" border="0" onxxxx="if(this.offsetWidth>'800')this.width='800';if(this.offsetHeight>'2000')this.height='2000';" onxxxxx="if(this.width>=800) window.open('http://rgfxsa.blu.livefilestore.com/y1pGkVtX_yzZCL8daXsjW8n3w4fQ0Wnh3cH_9OPaKAmsc9_-tfVYFQHxNLwl92WSngaMJGquqzuMCGxXUb8Ti3w54jBFwbkr5ok/1270365974_788657.jpg');" alt="" /><br style="outline-style: none" /><br style="outline-style: none" /><br style="outline-style: none" /><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体 "><font style="LINE-HEIGHT: 1.5em; outline-style: none" size="3">下面是弹出的添加下载链接界面：<span class="Apple-converted-space"> </span><br style="outline-style: none" /></font></font><br style="outline-style: none" /><img style="BORDER-TOP-WIDTH: 0px; BORDER-LEFT-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; BORDER-RIGHT-WIDTH: 0px; outline-style: none" src="http://rgfxsa.blu.livefilestore.com/y1pSFuT3zM1t8zTXtlR4AmjnFGFGUIyJ4kxmertgBY5aB0EHdIA3UygyTYNzCMjMtV0V-JIWrw4Or5u70X8bAEUOiljbHIEHvyA/1270365979_767636.jpg" border="0" onxxxx="if(this.offsetWidth>'800')this.width='800';if(this.offsetHeight>'2000')this.height='2000';" onxxxxx="if(this.width>=800) window.open('http://rgfxsa.blu.livefilestore.com/y1pSFuT3zM1t8zTXtlR4AmjnFGFGUIyJ4kxmertgBY5aB0EHdIA3UygyTYNzCMjMtV0V-JIWrw4Or5u70X8bAEUOiljbHIEHvyA/1270365979_767636.jpg');" alt="" /><br style="outline-style: none" /><br style="outline-style: none" /><br style="outline-style: none" />2、添加完成下载链接后的界面<span class="Apple-converted-space"> </span><br style="outline-style: none" /><br style="outline-style: none" /><img style="BORDER-TOP-WIDTH: 0px; BORDER-LEFT-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; BORDER-RIGHT-WIDTH: 0px; outline-style: none" src="http://rgfxsa.blu.livefilestore.com/y1p_mVAiZAJtI7j821yyoZYVbGAe3w0-1pHjvNvX2HjTjT23mIwHVpoL2p6iFfIs3623ptHTItU0IV08SAOluMKGL_ONwzvbIg4/1270365992_583973.jpg" border="0" onxxxx="if(this.offsetWidth>'800')this.width='800';if(this.offsetHeight>'2000')this.height='2000';" onxxxxx="if(this.width>=800) window.open('http://rgfxsa.blu.livefilestore.com/y1p_mVAiZAJtI7j821yyoZYVbGAe3w0-1pHjvNvX2HjTjT23mIwHVpoL2p6iFfIs3623ptHTItU0IV08SAOluMKGL_ONwzvbIg4/1270365992_583973.jpg');" alt="" /><br style="outline-style: none" /><br style="outline-style: none" /><br style="outline-style: none" /><font style="LINE-HEIGHT: 1.5em; outline-style: none" face="宋体 ">3、选择需要下载的资源后，单击&ldquo;开始&rdquo;按钮即可</font><span class="Apple-converted-space"> </span><br style="outline-style: none" /><br style="outline-style: none" /><br style="outline-style: none" /><img style="BORDER-TOP-WIDTH: 0px; BORDER-LEFT-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; BORDER-RIGHT-WIDTH: 0px; outline-style: none" src="http://rgfxsa.blu.livefilestore.com/y1pjRJk-PJlVNh5t5TDEc_VTFOQhHAMcsSz9i-6duGdIQoElPTv6dTn0nMxnllwdTdBiYchpzV7YQHjxG1p6UMmgcwGEAnBdifS/1270365926_140994.jpg" border="0" onxxxx="if(this.offsetWidth>'800')this.width='800';if(this.offsetHeight>'2000')this.height='2000';" onxxxxx="if(this.width>=800) window.open('http://rgfxsa.blu.livefilestore.com/y1pjRJk-PJlVNh5t5TDEc_VTFOQhHAMcsSz9i-6duGdIQoElPTv6dTn0nMxnllwdTdBiYchpzV7YQHjxG1p6UMmgcwGEAnBdifS/1270365926_140994.jpg');" alt="" /></span></span></div>
            </td>
        </tr>
    </tbody>
</table>
</p>]]></description>
			<link>http://iii80.com//?action=show&amp;id=531</link>
			<pubDate>2010-08-30 11:36</pubDate>
		</item>
		<item>
			<title>CentOS5 1CD 最新光盘下载</title>
			<author>水中月</author>
			<description><![CDATA[<p>CentOS5 1CD 最新光盘下载</p>
<p><strong>CentOS 5.5 1CD x86_64 (20100516)版<br /></strong><a href="http://www.srchack.org/pub/centos5/onecd/CentOS-5.5-x86_64-1CD_20100516.iso" target="_blank">CentOS-5.5-x86_64-1CD_20100516.iso</a> </p>
<p> </p>
<p><strong>CentOS 5.5 1CD i386 (20100515)版<br /></strong><a href="http://www.srchack.org/pub/centos5/onecd/CentOS-5.5-i386-1CD_20100515.iso" target="_blank">CentOS-5.5-i386-1CD_20100515.iso</a> </p>
<p> </p>
<p><strong>CentOS 5.4 1CD i386 (20100110)版<br /></strong><a href="http://www.srchack.org/pub/centos5/onecd/CentOS-5.4-i386-1CD_20100110.iso" target="_blank">CentOS-5.4-i386-1CD_20100110.iso</a> </p>
<p> </p>
<p><strong>CentOS 5.4 1CD x86_64 (20091102)版<br /></strong><a href="http://www.srchack.org/pub/centos5/onecd/CentOS-5.4-x86_64-1CD_20091102.iso" target="_blank">CentOS-5.4-x86_64-1CD_20091102.iso</a> </p>
<p> </p>
<p><strong>CentOS 5.4 1CD i386 (20091024)版<br /></strong><a href="http://www.srchack.org/pub/centos5/onecd/CentOS-5.4-i386-1CD_20091024.iso" target="_blank">CentOS-5.4-i386-1CD_20091024.iso</a></p>
<p> </p>
<p><strong>CentOS5.3 1CD 20090524版<br /></strong><a href="http://www.srchack.org/pub/centos5/onecd/CentOS5.3_1CD_20090524.iso" target="_blank">CentOS5.3_1CD_20090524.iso</a> </p>
<p> </p>
<p><strong>CentOS5.3 1CD 20090418版<br /></strong><a href="http://www.srchack.org/pub/centos5/onecd/CentOS_5.3_1CD_20090418.iso" target="_blank">CentOS_5.3_1CD_20090418.iso</a> </p>
<p> </p>
<p><strong>CentOS5.2 1CD<br /></strong><a href="http://www.srchack.org/pub/centos5/onecd/CentCore52_20081209.iso">CentCore52_20081209.iso</a><br /></p>
<p> </p>
<p><strong>CentOS5 1CD導入ディスク<br /></strong><a href="http://www.srchack.org/pub/centos5/onecd/CentOS5_one.iso">CentOS5_one.iso</a></p>
<p> </p>
<p> </p>
<p><a href="http://www.srchack.org/index.php?topic=CentOS1CD">http://www.srchack.org/index.php?topic=CentOS1CD</a></p>]]></description>
			<link>http://iii80.com//?action=show&amp;id=530</link>
			<pubDate>2010-08-11 16:40</pubDate>
		</item>
		<item>
			<title>在VPS上安装Cherokee+PHP+MySQL</title>
			<author>水中月</author>
			<description><![CDATA[<p>在VPS上安装Cherokee+PHP+MySQL</p>
<p>系统是Ubuntu 9.04,用root登录,然后操作如下;</p>
<div class="wp_syntax">
<table>
    <tbody>
        <tr>
            <td class="line_numbers">
            <pre>1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
</pre>
            </td>
            <td class="code">
            <pre class="bash" style="FONT-FAMILY: monospace"><span style="FONT-WEIGHT: bold; COLOR: #c20cb9">apt-get</span> remove apahce2 <span style="FONT-WEIGHT: bold; COLOR: #000000">//</span>因为VPS预安装了Apache,所以我先把Apache删了;
<span style="FONT-WEIGHT: bold; COLOR: #c20cb9">apt-get</span> update <span style="FONT-WEIGHT: bold; COLOR: #000000">//</span>然后更新下系统;
<span style="FONT-WEIGHT: bold; COLOR: #c20cb9">apt-get</span> <span style="FONT-WEIGHT: bold; COLOR: #c20cb9">install</span> mysql-server-<span style="COLOR: #000000">5.1</span> <span style="FONT-WEIGHT: bold; COLOR: #000000">//</span>安装MySQL,会提示设置root用户密码;
<span style="FONT-WEIGHT: bold; COLOR: #c20cb9">apt-get</span> <span style="FONT-WEIGHT: bold; COLOR: #c20cb9">install</span> php5-cgi php5-mysql php5-gd <span style="FONT-WEIGHT: bold; COLOR: #000000">//</span>安装PHP
<span style="FONT-WEIGHT: bold; COLOR: #c20cb9">apt-get</span> <span style="FONT-WEIGHT: bold; COLOR: #c20cb9">install</span> <span style="FONT-WEIGHT: bold; COLOR: #c20cb9">cpp</span> <span style="FONT-WEIGHT: bold; COLOR: #c20cb9">gcc</span> <span style="FONT-WEIGHT: bold; COLOR: #c20cb9">g++</span> <span style="FONT-WEIGHT: bold; COLOR: #c20cb9">make</span> <span style="FONT-WEIGHT: bold; COLOR: #000000">//</span>编译Cherokee所必要的软件;
<span style="FONT-WEIGHT: bold; COLOR: #7a0874">cd</span> <span style="FONT-WEIGHT: bold; COLOR: #000000">/</span>tmp
<span style="FONT-WEIGHT: bold; COLOR: #c20cb9">wget</span> http:<span style="FONT-WEIGHT: bold; COLOR: #000000">//</span>www.cherokee-project.com<span style="FONT-WEIGHT: bold; COLOR: #000000">/</span>cherokee-latest-tarball <span style="COLOR: #660033">-O</span> -<span style="FONT-WEIGHT: bold; COLOR: #000000">|</span> <span style="FONT-WEIGHT: bold; COLOR: #c20cb9">tar</span> zxvf - <span style="FONT-WEIGHT: bold; COLOR: #000000">//</span>下载Cherokee到tmp目录
<span style="FONT-WEIGHT: bold; COLOR: #c20cb9">mv</span> cherokee-0.99.31 cherokee  <span style="FONT-WEIGHT: bold; COLOR: #000000">//</span>懒的总是打版本号,所以重命名下;
<span style="FONT-WEIGHT: bold; COLOR: #7a0874">cd</span> cherokee
.<span style="FONT-WEIGHT: bold; COLOR: #000000">/</span>configure &ndash;<span style="COLOR: #007800">localstatedir</span>=<span style="FONT-WEIGHT: bold; COLOR: #000000">/</span>var &ndash;<span style="COLOR: #007800">prefix</span>=<span style="FONT-WEIGHT: bold; COLOR: #000000">/</span>usr &ndash;<span style="COLOR: #007800">sysconfdir</span>=<span style="FONT-WEIGHT: bold; COLOR: #000000">/</span>etc &ndash;with-wwwroot=<span style="FONT-WEIGHT: bold; COLOR: #000000">/</span>var<span style="FONT-WEIGHT: bold; COLOR: #000000">/</span>www <span style="FONT-WEIGHT: bold; COLOR: #000000">//</span>基本配置
<span style="FONT-WEIGHT: bold; COLOR: #c20cb9">make</span> <span style="FONT-WEIGHT: bold; COLOR: #000000">//</span>编译;
<span style="FONT-WEIGHT: bold; COLOR: #c20cb9">make</span> <span style="FONT-WEIGHT: bold; COLOR: #c20cb9">install</span> <span style="FONT-WEIGHT: bold; COLOR: #000000">//</span>安装;
<span style="FONT-WEIGHT: bold; COLOR: #c20cb9">cp</span> contrib<span style="FONT-WEIGHT: bold; COLOR: #000000">/</span>cherokee <span style="FONT-WEIGHT: bold; COLOR: #000000">/</span>etc<span style="FONT-WEIGHT: bold; COLOR: #000000">/</span>init.d<span style="FONT-WEIGHT: bold; COLOR: #000000">/</span>cherokee <span style="FONT-WEIGHT: bold; COLOR: #000000">//</span>复制启动脚本;
<span style="FONT-WEIGHT: bold; COLOR: #c20cb9">chmod</span> <span style="COLOR: #000000">755</span> <span style="FONT-WEIGHT: bold; COLOR: #000000">/</span>etc<span style="FONT-WEIGHT: bold; COLOR: #000000">/</span>init.d<span style="FONT-WEIGHT: bold; COLOR: #000000">/</span>cherokee <span style="FONT-WEIGHT: bold; COLOR: #000000">//</span>更改权限;
<span style="FONT-WEIGHT: bold; COLOR: #000000">/</span>etc<span style="FONT-WEIGHT: bold; COLOR: #000000">/</span>init.d<span style="FONT-WEIGHT: bold; COLOR: #000000">/</span>cherokee start <span style="FONT-WEIGHT: bold; COLOR: #000000">//</span>然后启动Cherokee;
update-rc.d cherokee defaults</pre>
            </td>
        </tr>
    </tbody>
</table>
</div>
<p>启动,停止,重启命令;</p>
<div class="wp_syntax">
<table>
    <tbody>
        <tr>
            <td class="line_numbers">
            <pre>1
2
3
</pre>
            </td>
            <td class="code">
            <pre class="bash" style="FONT-FAMILY: monospace"><span style="FONT-WEIGHT: bold; COLOR: #000000">/</span>etc<span style="FONT-WEIGHT: bold; COLOR: #000000">/</span>init.d<span style="FONT-WEIGHT: bold; COLOR: #000000">/</span>cherokee start
<span style="FONT-WEIGHT: bold; COLOR: #000000">/</span>etc<span style="FONT-WEIGHT: bold; COLOR: #000000">/</span>init.d<span style="FONT-WEIGHT: bold; COLOR: #000000">/</span>cherokee stop
<span style="FONT-WEIGHT: bold; COLOR: #000000">/</span>etc<span style="FONT-WEIGHT: bold; COLOR: #000000">/</span>init.d<span style="FONT-WEIGHT: bold; COLOR: #000000">/</span>cherokee restart</pre>
            </td>
        </tr>
    </tbody>
</table>
</div>
<p>启动Cherokee的管理面板;</p>
<div class="wp_syntax">
<table>
    <tbody>
        <tr>
            <td class="line_numbers">
            <pre>1
</pre>
            </td>
            <td class="code">
            <pre class="bash" style="FONT-FAMILY: monospace">cherokee-admin <span style="COLOR: #660033">-b</span></pre>
            </td>
        </tr>
    </tbody>
</table>
</div>
<p>然后用显示的密码登录<a href="http://IP:9090">http://IP:9090</a></p>
<p> </p>
<p>快速安装<font face="Courier New">cherokee</font></p>
<p><font face="Courier New">apt-get install cherokee</font></p>]]></description>
			<link>http://iii80.com//?action=show&amp;id=529</link>
			<pubDate>2010-08-10 17:40</pubDate>
		</item>
		<item>
			<title>ubuntu server版安装过程问题</title>
			<author>水中月</author>
			<description><![CDATA[<p>ubuntu server版安装过程问题</p>
<p>安裝了ubuntu server版可是apt-get install XXXX 出现E: Couldn't find package XXX<br />首先执行sudo apt-get update<br />以更新软件列表<br /><br />重新启动网络<br />sudo /etc/init.d/networking restart<br /><br />安装图形界面：<br />1.sudo apt-get install xinit<br />执行这个，会安装一个图形的命令行窗口<br />(在我的机器上这个步骤完成以后UI就没有任何响应了.我不太了解图形界面在linux上是个什么机制)<br />2.安装环境管理器<br />sudo apt-get install gdm<br />KDE和Xface则分别改为KDM和XDM<br />3.安装桌面环境<br />sudo apt-get install ubuntu-desktop<br /><br /><br />svn在将Ubuntu的语言修改为英文之后，出现错误警告：<br />svn: warning: cannot set LC_CTYPE locale<br />svn: warning: environment variable LANG is en_US.UTF-8<br />svn: warning: please check that your locale name is correct<br />Type 'svn help' for usage.   <br /><br />解决方法:修改/etc/profile:sudo vi /etc/profile<br />加入一行：<br />export LC_ALL=C<br /><br />执行source /etc/profile<br />svn就可以正常工作了<br /><br />安装ftp:<br />sudo apt-get install vsftpd<br /><br />转自http://linux2904.blog.163.com/blog/static/109134192201001192534867/<br />一. samba的安装:<br /><br />一. samba的安装:<br />sudo apt-get insall samba<br />sudo apt-get install smbfs<br /><br />二. 创建共享目录:<br />mkdir /home/phinecos/share<br />sodu chmod 777 /home/phinecos/share<br /><br />三. 创建Samba配置文件:<br /><br />1. 保存现有的配置文件<br />sudo cp /etc/samba/smb.conf /etc/samba/smb.conf.bak<br /><br />2. 修改现配置文件<br />sudo gedit /etc/samba/smb.conf<br /><br />在smb.conf最后添加<br />[share]<br />      path = /home/phinecos/share<br />      available = yes<br />      browsealbe = yes<br />      public = yes<br />      writable = yes<br /><br />四. 创建samba帐户<br />  sudo touch /etc/samba/smbpasswd<br />  sudo smbpasswd -a phinecos<br /><br />然后会要求你输入samba帐户的密码<br /><br /> ［如果没有第四步，当你登录时会提示 session setup failed: NT_STATUS_LOGON_FAILURE］<br /><br /> 五. 重启samba服务器<br />sudo /etc/init.d/samba restart<br /><br />六. 测试<br />smbclient -L //localhost/share<br /><br />七，使用<br />可以到windows下输入ip使用了，在文件夹处输入 "\\" + "Ubuntu机器的ip或主机名" + "\\" + "share"</p>]]></description>
			<link>http://iii80.com//?action=show&amp;id=528</link>
			<pubDate>2010-08-08 15:47</pubDate>
		</item>
		<item>
			<title>设置Ubuntu的默认语言为英文</title>
			<author>水中月</author>
			<description><![CDATA[<p><span class="tcnt"><font face="黑体" size="5">设置Ubuntu的默认语言为英文</font></span></p>
<p><span class="tcnt">修改Ubuntu Server的区域语言设置<br />1.修改/var/lib/locales/supported.d/local的内容为en_US.UTF-8 UTF-8<br />2.执行sudo locale-gen &ndash;purge重生成locale文件<br />3.修改/etc/default/locale内容为<br />    LANG="en_US.UTF-8"<br />    LANGUAGE="en_US:en"<br />4.sudo reboot</span></p>]]></description>
			<link>http://iii80.com//?action=show&amp;id=527</link>
			<pubDate>2010-08-08 15:46</pubDate>
		</item>
		<item>
			<title>网易Ubuntu 10.04更新源</title>
			<author>水中月</author>
			<description><![CDATA[<p>网易Ubuntu 10.04更新源</p>
<p><span class="Apple-style-span" style="FONT-WEIGHT: normal; FONT-SIZE: medium; WORD-SPACING: 0px; TEXT-TRANSFORM: none; COLOR: rgb(0,0,0); TEXT-INDENT: 0px; LINE-HEIGHT: normal; FONT-STYLE: normal; WHITE-SPACE: normal; LETTER-SPACING: normal; BORDER-COLLAPSE: separate; FONT-VARIANT: normal; orphans: 2; widows: 2"><span class="Apple-style-span" style="FONT-SIZE: 12px; COLOR: rgb(51,51,51); LINE-HEIGHT: 18px"><span class="Apple-style-span" style="FONT-WEIGHT: normal; FONT-SIZE: medium; WORD-SPACING: 0px; TEXT-TRANSFORM: none; COLOR: rgb(0,0,0); TEXT-INDENT: 0px; LINE-HEIGHT: normal; FONT-STYLE: normal; WHITE-SPACE: normal; LETTER-SPACING: normal; BORDER-COLLAPSE: separate; FONT-VARIANT: normal; orphans: 2; widows: 2"><span class="Apple-style-span" style="FONT-SIZE: 12px; COLOR: rgb(51,51,51); LINE-HEIGHT: 18px">deb http://mirrors.163.com/ubuntu/ lucid main universe restricted multiverse<br />deb-src http://mirrors.163.com/ubuntu/ lucid main universe restricted multiverse<br />deb http://mirrors.163.com/ubuntu/ lucid-security universe main multiverse restricted<br />deb-src http://mirrors.163.com/ubuntu/ lucid-security universe main multiverse restricted<br />deb http://mirrors.163.com/ubuntu/ lucid-updates universe main multiverse restricted<br />deb http://mirrors.163.com/ubuntu/ lucid-proposed universe main multiverse restricted<br />deb-src http://mirrors.163.com/ubuntu/ lucid-proposed universe main multiverse restricted<br />deb http://mirrors.163.com/ubuntu/ lucid-backports universe main multiverse restricted<br />deb-src http://mirrors.163.com/ubuntu/ lucid-backports universe main multiverse restricted<br />deb-src http://mirrors.163.com/ubuntu/ lucid-updates universe main multiverse restricted</span></span></span></span></p>]]></description>
			<link>http://iii80.com//?action=show&amp;id=526</link>
			<pubDate>2010-08-08 13:48</pubDate>
		</item>
		<item>
			<title>微软的免费大餐 – 官方的精简版Win7（老树WES7 V1）</title>
			<author>水中月</author>
			<description><![CDATA[<p>微软的免费大餐 &ndash; 官方的精简版Win7（老树WES7 V1）</p>
<div class="articalContent" id="sina_keyword_ad_area2">
<p><font style="FONT-SIZE: 16px"><font style="FONT-SIZE: 16px" size="5">特别声明：Windows版权归美国微软公司，波特尔软件版权归深圳波特尔公司。</font>　</font></p>
<p> <wbr></wbr></p>
<p>硬盘版：WES7HV1.iso,1.25G MD5: B2D24BE924ECC5F56763F22C<wbr></wbr>83F92DE8<br /><a href="http://u.115.com/file/f140a6ce88"><font color="#599100">http://u.115.com/file/f140a6ce88</font></a><br /><a href="http://u.115.com/file/f13a9cdea9"><font color="#599100">http://u.115.com/file/f13a9cdea9</font></a></p>
<p> <wbr></wbr></p>
<p>USB版：WES7UV1.iso,1.38G MD5: 39C1A1BB3FA7831D86197D4B<wbr></wbr>F734A0F0<br /><a href="http://u.115.com/file/f1bdb75e19"><font color="#599100">http://u.115.com/file/f1bdb75e19</font></a><a href="http://u.115.com/file/f140a6ce88"></a><br /><a href="http://u.115.com/file/f1911a2352"><font color="#599100">http://u.115.com/file/f1911a2352</font></a><a href="http://u.115.com/file/f13a9cdea9"></a></p>
<p> <wbr></wbr></p>
<p><font style="FONT-SIZE: 16px"> <wbr></wbr><font style="FONT-SIZE: 18px"><font style="FONT-SIZE: 22px">一、系统安装</font></font></font><font style="FONT-SIZE: 16px"><br />　<font style="FONT-SIZE: 20px">　1、制作PE启动盘安装<br /></font>　　<font style="FONT-SIZE: 14px">分两步走：<br />　　第一步，制作启动盘。使用UltraISO，单文件绿色版下载：</font><a href="http://u.115.com/file/f1b1140c2a"><font style="FONT-SIZE: 14px" color="#599100">http://u.115.com/file/f1b1140c2a</font></a><font style="FONT-SIZE: 14px">；运行UltraISO将下载到的老树系统镜像文件比例WESBeta.ISO打开，将USB盘插在电脑中，点击UltraISO的菜单：启动->写入硬盘，按&ldquo;写入&rdquo;，稍等几分种，这张&ldquo;PE系统工具盘&rdquo;就制作完成了。当然有刻录机也可以制作为启动光盘。<br />　　（图1）<br /><a href="http://photo.blog.sina.com.cn/showpic.html#blogid=638b649a0100km65&url=http://static8.photo.sina.com.cn/orignal/638b649a48cc28f3d0207" target="_blank"><img title="微软的免费大餐 <wbr>– <wbr>官方的精简版Win7（老树WES7 <wbr>V1）" alt="微软的免费大餐 <wbr>– <wbr>官方的精简版Win7（老树WES7 <wbr>V1）" src="http://static8.photo.sina.com.cn/bmiddle/638b649a48cc28f3d0207&690" name="image_operate_89521280667897079" real_src="http://static8.photo.sina.com.cn/bmiddle/638b649a48cc28f3d0207&690" /></a><br />　　<br />　　第二步，将这个PE系统工具盘启动电脑。目标盘可以选择硬盘，也可以选择USB盘。<br />　　如果要安装到硬盘，只要按&ldquo;安装系统&rdquo;就可以一键安装了。从硬盘启动后，直接进入系统，自动更改计算机名称，查找设备，无需进入部署阶段，和传统的安装部署速度不可同日而语。<br />　　（图2）<br />　<a href="http://photo.blog.sina.com.cn/showpic.html#blogid=638b649a0100km65&url=http://static1.photo.sina.com.cn/orignal/638b649a48cc2902199c0" target="_blank"><img title="微软的免费大餐 <wbr>– <wbr>官方的精简版Win7（老树WES7 <wbr>V1）" alt="微软的免费大餐 <wbr>– <wbr>官方的精简版Win7（老树WES7 <wbr>V1）" src="http://static1.photo.sina.com.cn/bmiddle/638b649a48cc2902199c0&690" name="image_operate_2251280667224613" real_src="http://static1.photo.sina.com.cn/bmiddle/638b649a48cc2902199c0&690" /></a>　　　<br />　　如果要安装到U盘中，如果有2个U盘，选定好目标盘，这样也可以一键安装了。如只有一个U盘，又不打算刻录光盘，应当将PE USB工具盘根目录下的ghost32.exe、system.gho、install.ini使共3个文件移动到硬盘分区（比如E盘）的根目录下（不是拷贝！必须将U盘上这三个文件删除），这样就可以选择这个启动U盘作为安装的目标盘。将要安装系统的U盘插入电脑，选定要安装系统的USB盘，按&ldquo;安装系统&rdquo;按钮，一般几分钟内，系统镜像文件拷贝完成，将会提示系统&ldquo;安装成功&rdquo;，将这个安装好的U盘，插入到任意电脑中，设置从USB盘启动就可以启动、使用了。无需系统构建，自动查找设备，启动运行飞快；启动时间、运行速度和在硬盘上的系统没有大的区别</font></font></p>
<p><br />　<font style="FONT-SIZE: 20px">　2、Win7下直接制作USB系统。<br /></font>　　<font style="FONT-SIZE: 14px">如果你的电脑是Win7操作系统，只是需要制作USB系统，这无需制作PE工具盘。直接使用WinRAR解压缩到磁盘中，然后执行目录中的UsbWdsk.EXE文件,就会出现系统工具界面：<br />　　图3：<br /><a href="http://photo.blog.sina.com.cn/showpic.html#blogid=638b649a0100km65&url=http://static11.photo.sina.com.cn/orignal/638b649a48cc290bff3ca" target="_blank"><img title="微软的免费大餐 <wbr>– <wbr>官方的精简版Win7（老树WES7 <wbr>V1）" alt="微软的免费大餐 <wbr>– <wbr>官方的精简版Win7（老树WES7 <wbr>V1）" src="http://static11.photo.sina.com.cn/bmiddle/638b649a48cc290bff3ca&690" name="image_operate_49011280667243972" real_src="http://static11.photo.sina.com.cn/bmiddle/638b649a48cc290bff3ca&690" /></a> 　　<br />　　将要安装系统的U盘插入电脑，按&ldquo;安装系统&rdquo;按钮就可以了。<br />　　上述两种安装方式，的确是有史以来最简单的Windows系统安装方式了，比目前流行的硬盘安装部署系统，更加简单、方便、快捷。<br /></font>　　<br />　<font style="FONT-SIZE: 20px">　3、安装注意事项<br /></font>　　<font style="FONT-SIZE: 14px">1、对于移动盘，将全部格式化磁盘。对于固定盘，只是格式化第一个分区，这样虽然数据安全保障较好，但是经常有些主磁盘引导区错误，导致引导失败，这种情况，建议备份好硬盘数据，使用本工具的&ldquo;将磁盘清除并格式化&ldquo;功能试试。<br />　　2、虽然有些动手能力强的人，可能提取system.gho，使用ghost32命令行自己恢复安装，但是必须按照上述说明使用波特尔安装工具！经常有些自做聪明的人，不看说明，将硬盘系统安装到USB盘，然后蓝屏，还有些其低级错误等等，然后就来喷人。波特尔安装工具自动检测环境，避免了很多这样的低级错误，也避免了ghost命令行，按照说明进行安装，就不会有什么密码问题！<br />　　3、安装过程中GHOST32拷贝失败，一般是USB盘硬件故障，如果使用的是SD卡+卡座，尤其要注意卡座故障，一些卡座可以正常读写少量数据，一旦GHOST32因为数据量大，就失败。<br />　　4、USB Win7系统安装时的目标盘接口（USB或者SATAT等），不能安装系统后然后改变接口，比如USB改SATAT接口或者STAT改USB。</font><br /></p>
<p> <wbr></wbr></p>
<p><font style="FONT-SIZE: 16px"><font style="FONT-SIZE: 22px">二、WES 7简介和老树系统制作思路</font><br />　　Windows Embedded Standard 7,就是微软官方出品的Win7的定制版，2进制代码和桌面版完全相同，因此功能也基本一样，主要区别在于，WES7可以精简（桌面版精简并不受微软官方支持）。虽然WES7安装比较复杂，但是现在好了，老树制作了一键安装的WES7，比桌面安装还要简单。<br />　　使用WES7制作的原因主要有2个：<br />　　一是版权问题。WES 7官定免费使用180天，到期后如果需要再用下去，并不需要重新安装，只需要按照微软公布的正规方法：执行一下slmgr.vbs &ndash;rearm重置激活，就可以再使用180天，可以这样重置激活6次，这就等于可以免费使用3年。3年后，按照微软官网公布的方法，将注册表项：HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\SoftwareProtectionPlatfo<wbr></wbr>rm\"SkipRearm"=dword:00000000的值更改为1，又可以重置激活，可以这样重复8次，因此，官方WES7可以免费使用7年。当然，重新安装一下，又可以使用7年。前面的6次3年，本人实测过，的确可以，后面的是看网络资料，本人未做实际验证。</font></p>
<p><font style="FONT-SIZE: 16px"><font style="FONT-SIZE: 16px">　　（图4）<br /><a href="http://photo.blog.sina.com.cn/showpic.html#blogid=638b649a0100km65&url=http://static3.photo.sina.com.cn/orignal/638b649a48c6f9c26cc92" target="_blank"><img title="微软的免费大餐 <wbr>– <wbr>官方的精简版Win7（老树WES7 <wbr>V1）" alt="微软的免费大餐 <wbr>– <wbr>官方的精简版Win7（老树WES7 <wbr>V1）" src="http://static3.photo.sina.com.cn/bmiddle/638b649a48c6f9c26cc92&690" name="image_operate_94271280667951472" real_src="http://static3.photo.sina.com.cn/bmiddle/638b649a48c6f9c26cc92&690" /></a><br /><br />　　<br />　　（图5）<br /><a href="http://photo.blog.sina.com.cn/showpic.html#blogid=638b649a0100km65&url=http://static2.photo.sina.com.cn/orignal/638b649a48c6f9d28fc01" target="_blank"><img title="微软的免费大餐 <wbr>– <wbr>官方的精简版Win7（老树WES7 <wbr>V1）" alt="微软的免费大餐 <wbr>– <wbr>官方的精简版Win7（老树WES7 <wbr>V1）" src="http://static2.photo.sina.com.cn/bmiddle/638b649a48c6f9d28fc01&690" name="image_operate_96021280667956316" real_src="http://static2.photo.sina.com.cn/bmiddle/638b649a48c6f9d28fc01&690" /><font color="#599100">  <wbr></wbr></font></a><br /><br />　　二是兼容性问题。使用非官方精简工具，精简出来的系统，往往问题多多，比如不能升级，不能够2次封装等等，使用WES7精简的系统，就没有这样的问题。<br />　　使用WES7，可以很容易搞一个几百兆的精简版Win7，但本系统目的是要制作一个基本通用的Win7，考虑到务必要保留软件兼容性和用户体验完整性，不敢&ldquo;下此毒手&rdquo;。这次制作的简体中文精简版，除了精简不经常使用的一些打印机驱动，其他驱动全部保留完整。组件主要是一些不太常用的，比如，自然语言，日语，韩语Media Center等，基本维持了Win7的完整兼容性，保留了areo效果，Windows体验指数、完整的字库，繁体中文支持等，测试过可以安装OFFICE2010。USB版系统安装后占用磁盘空间1.5G。硬盘版包含Table PC，USB版不含。<br />　　在硬盘上运行支持10秒快内速开机（HORM）的功能，是一项微软嵌入式系统特有的功能。原理就是&ldquo;冻结&rdquo;住硬盘的休眠文件，达到（断电）快速启动。系统默认并未打开，如果要启用，要在&ldquo;写过滤&rdquo;无效情况下，进入波特尔金盾设置，选中&ldquo;快速速启动:一次休眠多次启动&rdquo;，然后使写过滤有效，重启动后，金盾系统提示要求做休眠，按确定，做休眠，再重启动就是快速启动。快速启动要求电脑的电源模式支持&ldquo;休眠&rdquo;，可以POWERCFG <wbr></wbr> /a查询。<br />　　这次精简系统硬盘系统采用传统2次封装方式，USB采用了直接运行的系统的方式，这都是久经考验比较好的方式。　　系统中安装了&ldquo;波特尔金盾&rdquo;。微软的WES 7号称实现免维护，防病毒，快速启动等嵌入式特性。&ldquo;波特尔金盾&rdquo;改进和增强了WES2009和WES7嵌入式特性。比如可以防止机器狗穿透，HORM支持多个分区，支持虚拟内存，支持非管理员用户设置，用户设置密码等等，对于U盘增强就更多、更必要了:使用WES7官方工具，理论上可以将系统直接安装到在普通U盘，但是要几个小时以上，还经常失败，运行巨卡；并且，官方安装工具安装出来的USB系统和硬件相关，没有移动性。（详情参看：<a href="http://blog.sina.com.cn/s/blog_5f58c6450100ikkc.html"><font color="#599100">http://blog.sina.com.cn/s/blog_5f58c6450100ikkc.html</font></a>）。&ldquo;波特尔金盾&rdquo;，是WES嵌入式特性必要的改进和增强。<br />　　(图6)<br />　<a href="http://photo.blog.sina.com.cn/showpic.html#blogid=638b649a0100km65&url=http://static11.photo.sina.com.cn/orignal/638b649a48c6f9e1cd17a" target="_blank"><img title="微软的免费大餐 <wbr>– <wbr>官方的精简版Win7（老树WES7 <wbr>V1）" alt="微软的免费大餐 <wbr>– <wbr>官方的精简版Win7（老树WES7 <wbr>V1）" src="http://static11.photo.sina.com.cn/bmiddle/638b649a48c6f9e1cd17a&690" name="image_operate_62221280667963035" real_src="http://static11.photo.sina.com.cn/bmiddle/638b649a48c6f9e1cd17a&690" /></a><br /><br />　</font></font></p>
<p><font style="FONT-SIZE: 16px"><font style="FONT-SIZE: 22px">系统特点：</font>　</font></p>
<p><font style="FONT-SIZE: 16px" color="#4d6df3"><strong>　　1、使用微软WES7制作的官方许可免费版，避免版权纠纷。<br />　　2、官方的精简Win7系统，功能基本和桌面版相同，驱动完全，支持在线升级，2次封装，程序兼容等等。<br />　　3、硬盘版支持快速启动，系统启动10秒内完成，启动神速。<br />　　4、USB版，在普通的低速U盘顺畅运行（当然，在普通硬盘就更加顺畅运行），无需安装构建，自动安装驱动，直接使用；实现了PE的移动性，桌面的全部功能；<br />　　5、系统保护，防止穿透，并可在硬件写保护开关的SD卡、U盘运行，系统不怕病毒、免于维护，并由于避免写操作，在U盘运行时确保U盘长寿。<br />　　6、系统盘保护时，动态创建虚拟内存交换文件到其他磁盘或者网络盘，确保系统稳定。<br />　　7、系统盘保护时系统盘动态增容量，新建文件夹重新定向，避免了兼容性不佳，系统稳定可靠。<br />　　8、在移动盘运行时，移动盘作为系统盘时自动识别为固定盘，支持移动盘多个分区。<br />　　9、安装工具可以方便地设定移动磁盘写保护，在其他普通Windows的电脑上，无需另外安装软件和设定，该只读也有效，防止系统破坏。<br />　　10、安装简单、快捷，全图形界面，非专业人员、生手也可立马上手。</strong></font></p>
</div>]]></description>
			<link>http://iii80.com//?action=show&amp;id=525</link>
			<pubDate>2010-08-07 23:14</pubDate>
		</item>
		<item>
			<title>网易 debian 5 和 ubuntu 9.10 apt-get 源 和 centos 的 yum</title>
			<author>水中月</author>
			<description><![CDATA[<p>网易 debian 5 和 ubuntu 9.10 apt-get 源 和 centos 的 yum 源</p>
<p>Debian 系统的<br /></p>
<div class="quote">
<div class="quote-title">引用</div>
<div class="quote-content"><br />deb http://mirrors.163.com/debian/ lenny main non-free contrib<br />deb http://mirrors.163.com/debian/ lenny-proposed-updates main non-free contrib</div>
</div>
<p><br /><br /><br />Ubuntu 系统的<br /></p>
<div class="quote">
<div class="quote-title">引用</div>
<div class="quote-content">deb http://mirrors.163.com/ubuntu/ karmic main restricted universe multiverse<br />deb http://mirrors.163.com/ubuntu/ karmic-security main restricted universe multiverse<br />deb http://mirrors.163.com/ubuntu/ karmic-updates main restricted universe multiverse<br />deb http://mirrors.163.com/ubuntu/ karmic-proposed main restricted universe multiverse<br />deb http://mirrors.163.com/ubuntu/ karmic-backports main restricted universe multiverse</div>
</div>
<p><br /><br />Centos的<br /><a name="entrymore"></a><br /></p>
<div class="quote">
<div class="quote-title">引用</div>
<div class="quote-content"># CentOS-Base.repo<br />#<br /># The mirror system uses the connecting IP address of the client and the<br /># update status of each mirror to pick mirrors that are updated to and<br /># geographically close to the client.  You should use this for CentOS updates<br /># unless you are manually picking other mirrors.<br />#<br /># If the mirrorlist= does not work for you, as a fall back you can try the <br /># remarked out baseurl= line instead.<br />#<br />#<br /><br />[base]<br />name=CentOS-$releasever - Base<br />baseurl=http://mirrors.163.com/centos/$releasever/os/$basearch/<br />gpgcheck=1<br />gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-5<br /><br />#released updates <br />[updates]<br />name=CentOS-$releasever - Updates<br />baseurl=http://mirrors.163.com/centos/$releasever/updates/$basearch/<br />gpgcheck=1<br />gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-5<br /><br />#packages used/produced in the build but not released<br />[addons]<br />name=CentOS-$releasever - Addons<br />baseurl=http://mirrors.163.com/centos/$releasever/addons/$basearch/<br />gpgcheck=1<br />gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-5<br /><br />#additional packages that may be useful<br />[extras]<br />name=CentOS-$releasever - Extras<br />baseurl=http://mirrors.163.com/centos/$releasever/extras/$basearch/<br />gpgcheck=1<br />gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-5<br /><br />#additional packages that extend functionality of existing packages<br />[centosplus]<br />name=CentOS-$releasever - Plus<br />baseurl=http://mirrors.163.com/centos/$releasever/centosplus/$basearch/<br />gpgcheck=1<br />enabled=0<br />gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-5<br /><br />#contrib - packages by Centos Users<br />[contrib]<br />name=CentOS-$releasever - Contrib<br />baseurl=http://mirrors.163.com/centos/$releasever/contrib/$basearch/<br />gpgcheck=1<br />enabled=0<br />gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-5</div>
<div class="quote-content"></div>
<div class="quote-content"></div>
<div class="quote-content"></div>
<div class="quote-content"></div>
<div class="quote-content">
<h1>欢迎访问网易开源镜像站(联通)</h1>
<table id="distro-table" cellspacing="0" cellpadding="0">
    <colgroup><col width="50%"></col><col width="20%"></col><col width="20%"></col><col width="10%"></col></colgroup>
    <thead>
        <tr>
            <th>镜像名</th>
            <th>时间</th>
            <th>上次更新时间</th>
            <th>使用帮助</th>
        </tr>
    </thead>
    <tbody>
        <tr class="odd">
            <td><a href="http://mirrors.163.com/FreeBSD">FreeBSD/</a></td>
            <td>2010-08-04 13:31</td>
            <td>2010-08-05 13:22</td>
            <td><a href="http://mirrors.163.com/.help/freebsd.html">使用帮助</a></td>
        </tr>
        <tr class="even">
            <td><a href="http://mirrors.163.com/FreeBSD-updates">FreeBSD-updates/</a></td>
            <td>2010-07-20 18:28</td>
            <td>2010-08-05 18:15</td>
            <td><a href="http://mirrors.163.com/.help/freebsd-updates.html">使用帮助</a></td>
        </tr>
        <tr class="odd">
            <td><a href="http://mirrors.163.com/archlinux">archlinux/</a></td>
            <td>2010-08-03 03:13</td>
            <td>2010-08-05 03:24</td>
            <td><a href="http://mirrors.163.com/.help/archlinux.html">使用帮助</a></td>
        </tr>
        <tr class="even">
            <td><a href="http://mirrors.163.com/centos">centos/</a></td>
            <td>2010-05-11 00:41</td>
            <td>2010-08-05 15:19</td>
            <td><a href="http://mirrors.163.com/.help/centos.html">使用帮助</a></td>
        </tr>
        <tr class="odd">
            <td><a href="http://mirrors.163.com/cygwin">cygwin/</a></td>
            <td>2010-08-05 09:24</td>
            <td>2010-08-05 09:25</td>
            <td><a href="http://mirrors.163.com/.help/cygwin.html">使用帮助</a></td>
        </tr>
        <tr class="even">
            <td><a href="http://mirrors.163.com/debian">debian/</a></td>
            <td>2010-08-05 16:53</td>
            <td>2010-08-05 18:40</td>
            <td><a href="http://mirrors.163.com/.help/debian.html">使用帮助</a></td>
        </tr>
        <tr class="odd">
            <td><a href="http://mirrors.163.com/debian-backport">debian-backport/</a></td>
            <td>2010-08-05 21:40</td>
            <td>2010-08-05 22:08</td>
            <td><a href="http://mirrors.163.com/.help/debian-backport.html">使用帮助</a></td>
        </tr>
        <tr class="even">
            <td><a href="http://mirrors.163.com/debian-cd">debian-cd/</a></td>
            <td>2010-06-28 09:05</td>
            <td>2010-08-05 05:45</td>
            <td><a href="http://mirrors.163.com/.help/debian-cd.html">使用帮助</a></td>
        </tr>
        <tr class="odd">
            <td><a href="http://mirrors.163.com/debian-security">debian-security/</a></td>
            <td>2008-05-13 16:51</td>
            <td>2010-08-05 22:20</td>
            <td><a href="http://mirrors.163.com/.help/debian-security.html">使用帮助</a></td>
        </tr>
        <tr class="even">
            <td><a href="http://mirrors.163.com/fedora">fedora/</a></td>
            <td>2007-05-22 05:37</td>
            <td>2010-08-05 20:31</td>
            <td><a href="http://mirrors.163.com/.help/fedora.html">使用帮助</a></td>
        </tr>
        <tr class="odd">
            <td><a href="http://mirrors.163.com/gentoo">gentoo/</a></td>
            <td>2009-10-22 09:13</td>
            <td>2010-08-05 20:56</td>
            <td><a href="http://mirrors.163.com/.help/gentoo.html">使用帮助</a></td>
        </tr>
        <tr class="even">
            <td><a href="http://mirrors.163.com/gentoo-portage">gentoo-portage/</a></td>
            <td>2010-08-05 21:18</td>
            <td>2010-08-05 22:02</td>
            <td><a href="http://mirrors.163.com/.help/gentoo-portage.html">使用帮助</a></td>
        </tr>
        <tr class="odd">
            <td><a href="http://mirrors.163.com/kdemod">kdemod/</a></td>
            <td>2010-07-28 05:22</td>
            <td>2010-08-05 08:47</td>
            <td><a href="http://mirrors.163.com/.help/kdemod.html">使用帮助</a></td>
        </tr>
        <tr class="even">
            <td><a href="http://mirrors.163.com/mandriva">mandriva/</a></td>
            <td>2010-08-05 20:31</td>
            <td>2010-08-05 20:43</td>
            <td><a href="http://mirrors.163.com/.help/mandriva.html">使用帮助</a></td>
        </tr>
        <tr class="odd">
            <td><a href="http://mirrors.163.com/openSUSE">openSUSE/</a></td>
            <td>2009-10-30 01:00</td>
            <td>2010-08-05 07:04</td>
            <td><a href="http://mirrors.163.com/.help/opensuse.html">使用帮助</a></td>
        </tr>
        <tr class="even">
            <td><a href="http://mirrors.163.com/rpmfusion">rpmfusion/</a></td>
            <td>2010-06-18 21:18</td>
            <td>2010-08-05 20:29</td>
            <td>-</td>
        </tr>
        <tr class="odd">
            <td><a href="http://mirrors.163.com/slackware">slackware/</a></td>
            <td>2010-05-24 11:23</td>
            <td>2010-08-05 05:49</td>
            <td><a href="http://mirrors.163.com/.help/slackware.html">使用帮助</a></td>
        </tr>
        <tr class="even">
            <td><a href="http://mirrors.163.com/ubuntu">ubuntu/</a></td>
            <td>2010-08-05 20:15</td>
            <td>2010-08-05 21:05</td>
            <td><a href="http://mirrors.163.com/.help/ubuntu.html">使用帮助</a></td>
        </tr>
        <tr class="odd">
            <td><a href="http://mirrors.163.com/ubuntu-cn">ubuntu-cn/</a></td>
            <td>2010-07-31 07:44</td>
            <td>2010-08-05 02:22</td>
            <td><a href="http://mirrors.163.com/.help/ubuntu-cn.html">使用帮助</a></td>
        </tr>
        <tr class="even">
            <td><a href="http://mirrors.163.com/ubuntu-releases">ubuntu-releases/</a></td>
            <td>2010-08-05 01:20</td>
            <td>2010-08-05 05:13</td>
            <td><a href="http://mirrors.163.com/.help/ubuntu-releases.html">使用帮助</a></td>
        </tr>
    </tbody>
</table>
<div id="footer"><a href="http://www.163.com/" target="_blank">网易首页</a> <a href="http://mirrors.163.com/.help/index.html" target="_blank">使用帮助</a> <a href="mailto:mirror@service.netease.com">联系我们</a> <a href="http://corp.163.com/eng/about/overview.html" target="_blank">About NetEase</a> <a href="http://tel.mirrors.163.com/" target="_blank">电信镜像</a> <a href="http://uni.mirrors.163.com/" target="_blank">联通镜像</a></div>
</div>
</div>]]></description>
			<link>http://iii80.com//?action=show&amp;id=524</link>
			<pubDate>2010-08-05 22:40</pubDate>
		</item>
		<item>
			<title>CCcam Monitoring / Firewalling - Protect your ccca</title>
			<author>水中月</author>
			<description><![CDATA[<p><strong>CCcam Monitoring / Firewalling - Protect your cccam server </strong></p>
<p>- UPDATED - <br />Changelog :<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Quote:</div>
<table cellspacing="0" cellpadding="6" width="100%" border="0">
    <tbody>
        <tr>
            <td class="alt2" style="BORDER-RIGHT: 1px inset; BORDER-TOP: 1px inset; BORDER-LEFT: 1px inset; BORDER-BOTTOM: 1px inset">Version 2g :<br />- updated for <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> 2.1.2, now compatible with 2.0.x and 2.1.x<br />- added simple startup script<br />- reverted scripts to default shell executor "/bin/sh"<br />- minor fixes and syntax changes </td>
        </tr>
    </tbody>
</table>
</div>
<p>Hi,<br /><br />this set of scripts will help you protect your <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> <span class="highlight"><strong><font color="#ff0000">server</font></strong></span> against various events (bad command and illegal logins) generated by your peers in order to increase <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> service stability.<br />The basic idea is to use the linux firewall (iptables) in "realtime" to block <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> traffic for specific peers (ip) based on <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> debug output.<br /><br />This work was initialy inspired by discussions on this thread <a href="http://www.eurocardsharing.com/f78/how-solve-disconnecting-client-issue-66845" target="_blank"><font color="#496690">"How to solve the disconnecting client issue"</font></a> and is a partial answer to that specific <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> problem.<br /><br />Although all of it was designed on a debian standlone <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> <span class="highlight"><strong><font color="#ff0000">server</font></strong></span> having a local firewall, it should also work if your firewall is on a remote machine on your local network. <br /><br />The <strong>Dreambox setup is still NOT working at the moment</strong> and will be discussed at the end of the tutorial.<br /><br /><br />I have been using the scripts for many months with <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> 2.0.10 / 2.1.0 / 2.1.2. I didn't notice any <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> crashes or problems with peers. My <span class="highlight"><strong><font color="#ff0000">server</font></strong></span> has 50-70 peers and gets between 30 and 100 bad commands a day but their effect is barely noticeable.<br /><br /><strong>Concerning <span class="highlight"><font color="#ff0000">CCcam</font></span> 2.1.2</strong>, my tests showed increased problems with peers regarding the login process, leading to numerous peer bans and peers disconnections. Something has definitely changed in that <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> version that was not present in <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> < 2.1.2.<br /><br />I personally reverted to <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> 2.1.0 (you can probably use 2.1.1 safely too) and won't be using 2.1.2, i'll wait for 2.1.3 and see what happens then, i suggest you do the same unless you're satisfied with 2.1.2.<br /><br />The only advantage i can see with 2.1.2 is that it lets my script ban login floods, i'll work on that feature for <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> < 2.1.2 when i have time, for it is the last missing protection i can think of regarding <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> problems, i also noticed some ecm requests floods but i probably never will filter thoses.<br /><br /><strong>Features</strong> :<br />- block peers based on a specific number of bad commands or slow "cards" commands, for any number of minutes.<br />- block peers doing "illegal logins" (no account or bad password) for any number of minutes.<br />- protect <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> accounts or ips from being blocked or give them a different error count.<br />- filter main log and keep only relevant information (reduce log size) and split logs (monitoring, ecm, logins).<br />- modify monitoring behaviour, turn on/off firewall blocking or logs without having to restart <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span>.<br />- iptables rules use user defined chains in order to keep your iptables firewall fast, clean and safe.<br /><br /><br /><br /><strong>Prerequires</strong> :<br />- <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> running in debug mode with timestamps (-d -t)<br />- iptables (optional - can be disabled to use only logs)<br />- sudo to access iptables for your <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> user, with or without password (optional - sudo can be omitted or use of ssh to manage an external firewall)<br />- cron to perform iptables flush rules (unban) (optional if iptables is not used)<br />- bash/sh/ash(/busybox) POSIX shell script (read the dreambox section for more info on the scripting problems with ash/busybox shells) and some basic shell commands cat, echo, cut, grep..<br /><br /><br /><br /><strong>Install</strong> :<br />There's not much to do if you know that your system matches the prerequires above.<br /><br />Open a command line window and make sure you are running your <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> user.<br />Put the scripts start.sh config.sh fork.sh monitor.sh iptables.sh, in your <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> directory along with the two "protected_account" "protected_ip" files if you need them.<br /><br />Make sure the scripts can run on your shell, to do that first find out which shell you are running, there's a great change your linux system has links to simulate the precense of sh or bash but you can check your installed shells with the "whereis" command ("#whereis sh", "#whereis ash"...).<br />The scripts should be POSIX compatible to run on most shells and are configured to run on ash which is supposed to be faster than sh/bash, with the exception of "fork.sh" which MUST run on sh/bash or any shell that will release terminated child scripts and won't generate zombie processes (defunct).<br />If you don't want to install or use "ash" you can edit each script and change their top line :<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">#!/bin/ash</pre>
</div>
<p>with something matching your shell, like :<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">#!/bin/bash</pre>
</div>
<p>You need to edit/copy config.example.sh to config.sh, and make config.sh match your setup, each config line has comments.<br />Make sure you get the iptables parameters right if you intend to use it.<br /><br /><strong>Be very careful to properly set CCCMODE to match your <span class="highlight"><font color="#ff0000">cccam</font></span> version !</strong><br /><br />fork.sh will try to create the necessary directories LOGDIR and WORKDIR (see config.sh), but if for some reason it doesn't work and shows errors, create two subdirectories to put logs and work files, default directories are "logs" and "monitor", path are defined in config.sh and can be set to whatever you'd like :<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 82px; TEXT-ALIGN: left">cd /path/to/cccam
mkdir monitor
mkdir logs
chmod 0775 logs monitor</pre>
</div>
<p>Make sure the scripts are executable : <br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">chmod +x  start.sh config.sh fork.sh monitor.sh iptables.sh</pre>
</div>
<p>You can test your iptables setup by running the init command :<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">./iptables.sh init</pre>
</div>
<p>iptables init is always run when the fork.sh script starts so you don't actually need to run the init command manually but if your get some errors you will have to fix them.<br />If you run the init multiple times you will have two errors "iptables: Chain already exists", this is not a problem.<br /><br />Errors are redirected to you main log file (default "logs/monitor.log") so read it to see if errors appear.<br /><br />Make sure <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> output looks like this :<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 66px; TEXT-ALIGN: left">12:15:21.499 <span class="highlight"><strong><font color="#ff0000">CCcam</font></strong></span>: deleting client xx.xx.xxx.xxx(userX), bad command
12:15:21.501 <span class="highlight"><strong><font color="#ff0000">CCcam</font></strong></span>: deleting client yy.yyy.yyy.yy(userY), read result -1
12:15:27.896 <span class="highlight"><strong><font color="#ff0000">CCcam</font></strong></span>: 1498 cards --> client yy.yyy.yyy.yy(userY) (took 0.2730 seconds)</pre>
</div>
<p>you can test that by running <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> in the foreground with :<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">./CCcam.x86 -d -t -C ./CCcam.cfg</pre>
</div>
<p>according to <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> --help, the only thing that could be missing is the timestamp. Although i think that -d activates debug mode, not only foreground, and then outputs everything including timpestamps, also overriding <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> config options like DEBUG..<br /><br /><br />Finally when you're all set you can run <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> with the following command from the <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> directory :<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">./CCcam.x86 -d -t -C ./CCcam.cfg | ./fork.sh >> /path/to/cccam/logs/monitor.log &</pre>
</div>
<p>Or use the start.sh script :<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">./start.sh start</pre>
</div>
<p>start.sh has to be placed in the same directory as the other scripts and has the following commands "start / stop / restart". It uses regular ps/kill commands so it should be compatible with most systems. And can be used to monitor <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> status and restart it if necessary so you can use the "start" command in your cron to check if <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> has crashed and restart it.<br /><br /><br />You can then check out the main log with :<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">tail -n30 -f logs/monitor.log</pre>
</div>
<p>if everything works fine and you are using the firewall, you have to add a cron command to flush rules when they expire.<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">*/1 * * * * /path/to/cccam/iptables.sh flush >> /path/to/cccam/logs/monitor.log 2>&1</pre>
</div>
<p>It will run the iptables flush script every minute and delete rules that have expired (exceeded the ban duration)<br /><br /><br /><br /><br /><strong>Usage</strong> :<br /><br /><span class="highlight"><strong><font color="#ff0000">CCCam</font></strong></span> 2.1.0/2.1.1 specific :<br />Those two versions produce a lot more "bad command" events than other versions because some events were renamed as bad commands and were not before, knowing that i'd suggest being a little more tolerant regard the bad command counts and bans if you notice a large number of bans, so you could use settings like the following :<br /><br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 82px; TEXT-ALIGN: left">BADDELAY=2               # bad command count duration in minutes
BADCOUNT=5              # bad command count
BADCOUNT_IG=10        # bad command count for protected accounts
BAN=60                      # ban duration in minutes</pre>
</div>
<p><br />- CCCMODE : defines your <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> version, important if you want this script to work. Basically there's one mode "0" for all <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> but 2.1.2, and one mode "1" for <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> 2.1.2 and probably upcoming <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> revisions.<br /><br />- BADCOUNT/BADCOUNT_IG : Knowing that any peer can generate a bad command it is probably not a good idea to ban them at the first one. A good peer will most likely succeed to connect on its second attempt.<br /><br />- BADDELAY/BAN : bad commands being mostly caused by networking problems (probably very slow lines) it can be something temporary. That's why a 120min ban is usually enough to let the peer try again at a later time when the network conditions have changed. Using a short ban duration like 30min or less will simply let the bad peer send more commands and cripple your <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> <span class="highlight"><strong><font color="#ff0000">server</font></strong></span>. If you let a peer send more than one bad command then the error count spreads accross the BADDELAY duration.<br /><br />- BANLOGIN : banning illegal logins is optional but after exchanging Clines with many peers you will find out that a bunch of them won't remove your Cline, getting your <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> <span class="highlight"><strong><font color="#ff0000">server</font></strong></span> to handle a large amount of login attempts that are all doomed to failure. I just thought that filtering that traffic wouldn't hurt (read bugs and limitations below). It should also protect your <span class="highlight"><strong><font color="#ff0000">server</font></strong></span> from brute force login attacks although i doubt anyone would try to do such a visible hack.<br /><br />- LOGUNKNOWN/UKNOWNMAINLOG : are used to help <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> identify accounts that produce some events. LOGUNKNOWN will tell <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> to look for missing account names for the event processed by looking at current work/temp files. In addition, the optional UKNOWNMAINLOG will let <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> look into the main log file, this can be very helpful but can also produce some nasty side effects if your main log is big. So you should make sure to manage (rotate/purge on a daily basis) your main log file if you intend to use that option.<br /><br />- CARDSDELAY/CARDSBAD : for <span class="highlight"><strong><font color="#ff0000">CCcam</font></strong></span> 2.0.x-2.1.1 - has no impact on <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> 2.1.2 . That one is a bit more tricky, it tells the monitoring script to interpret "xxxx cards --> client" commands as a bad command based on its duration. I have indeed noticed that peers taking very long time (a few seconds) to receive the cards info will disconnect active peers in the exact same way a bad command does ! Unfortunately i wasn't really able to identify a very precise duration above which diconnections happen so i used a two levels trigger to manage those commands.<br />CARDSDELAY is the max durations in seconds above which the peer will get a "bad command" added to its log, but it will never trigger a ban action, the trigger will only log the event and when a "real" bad command occurs at a later time then it will count as a bad command. The use of this option is quite restrictive, the default is 4 seconds.<br />CARDSBAD is the max number of seconds allowed for a "xxxx cards --> client" command, above which a ban action is triggered, as if a real bad command was seen. CARDSBAD is probably more important than CARDSDELAY because it will actively try to ban peers with a very slow network, it will act in the exact same way as a bad command action does, respecting the same ban trigger options (BADCOUNT/BADDELAY). CARDSBAD should always be greater than CARDSDELAY.<br /><br />- DEBUG : adds some debug data to a $LOGDIR/debug.log file. Probably of no interest to you and should stay disabled (=0).<br /><br />- Understand that when a peer is banned, he will see your <span class="highlight"><strong><font color="#ff0000">server</font></strong></span> as offline but you will still be able to connect to his, you know what that means.<br /><br /><br /><br /><strong>Files</strong> :<br />Version 2g : <a onclick="pageTracker._trackPageview ('/outgoing/http_www_megaupload_com_d_3NZOPSRM');" href="http://www.megaupload.com/?d=3NZOPSRM" target="_blank"><font color="#496690">Download</font></a><br />("protected_account" and "protected_ip" are two empty files in which you can put account names and ips, one by line, that you want to "protect" from basic ban rules, see the documentation above for details)<br /><br /><br /><br /><strong>Advanced</strong> :<br />- you can rotate logs, all redirects use "append" (>>).<br /><br />- no sudo password<br />you can allow access to iptables for your <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> user (if not root) without sudo password by adding the following line to your "/etc/sudoers" file.<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">cccamuser   ALL=NOPASSWD:/sbin/iptables</pre>
</div>
<p>That way you don't have to give a large sudo access to your <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> user and you don't have to put a sudo password in config.sh SUPASS option. The <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> user only requires sudo (root) access to iptables, nothing else.<br /><br />- using a remote firewall<br />To use a remote iptables firewall on your local network you will have to replace the sudo command with a ssh one. ssh will try to connect to a remote linux system and execute the iptables command there, then return the command output to the script making the iptables command run exactly as if it was executed localy.<br />I will guide you quickly through a basic ssh setup but if you don't know what you are doing i'd suggest googling some <a onclick="pageTracker._trackPageview ('/outgoing/http_www_puddingonline_com_dave_publications_SSH_with_Keys_HOWTO_document_html_SSH_with_Keys_HOWTO_4_html');" href="http://www.puddingonline.com/~dave/publications/SSH-with-Keys-HOWTO/document/html/SSH-with-Keys-HOWTO-4.html" target="_blank"><font color="#496690">SSH HOWTOs</font></a>.<br /><br />A proper SSH setup would be as follows :<br />As root, generate a key pair using your "<span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span>" system's (where <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> monitoring script runs) ssh key generator (ssh-keygen on debian), if any, with the following command :<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">ssh-keygen -t dsa</pre>
</div>
<p>When asked for a "passphrase", we won't enter one. Just press enter twice.<br />That should produce two files in your root home directory : "~/.ssh/id_dsa.pub" and "~/.ssh/id_dsa"<br /><br />Copy the one line content of the new "~/.ssh/id_dsa.pub" file to the following file on your remote <span class="highlight"><strong><font color="#ff0000">server</font></strong></span> root user directory : /root/.ssh/authorized_keys2<br />Depending on your remote <span class="highlight"><strong><font color="#ff0000">server</font></strong></span> ssh configuration, the file could also be : /root/.ssh/authorized_keys<br /><br />Now from the <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> system you should be able to ssh your remote <span class="highlight"><strong><font color="#ff0000">server</font></strong></span> with the command :<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">ssh root@remoteip</pre>
</div>
<p>If it asks you to keep a footprint of the new remote system, say yes and it shouldn't bother you with that later, you can "exit" ssh now.<br />If it worked you can also try accessing the remote iptables firewall with that command, from the <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> system :<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">ssh root@remoteip /usr/bin/iptables -L -n</pre>
</div>
<p>It should display your firewall configuration for INPUT OUTPUT FORWARD chains.<br /><br />Then set the SUDO option in config.sh, like this :<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">SUDO="/usr/bin/ssh -x root@remoteip"</pre>
</div>
<p>you can also empty the SUPASS option.<br /><br />in order to make sure you have a working remote iptables setup you can try running the iptables.sh init command from the <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> system, as follows :<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">./iptables.sh init</pre>
</div>
<p>If you run it twice it should display two errors : "iptables: Chain already exists"<br />That means the <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> chains have been created on your firewall and your setup works.<br /><br />You can now run <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> as described in the main install guide above.<br /><br /><br /><br /><br /><strong>Known bugs and limitations</strong><br /><br />- log file output lines may be missplaced, some commands take longer to execute than others and the command output then gets into the log file a bit late, but this is usually something very localized and every line having a timestamp you can always understand what happened.<br /><br />- some iptables rules may be insterted more than once when a event is not processed fast enough, but it doesn't matter because iptables won't mind and the flush script makes sure duplicate rules are removed.<br /><br />- reloading your firewall should delete <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> init. you will have to init <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> iptables manually to fix that, with "./iptables.sh init". The good thing is that it should not get the scripts or <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> to crash, so <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> will not really care but you will get lots of errors in your <span class="highlight"><strong><font color="#ff0000">cccam</font></strong></span> monitoring log..<br /><br />- banning illegal logins will most certainly ban the new peers you have exchanged Clines with if you haven't activated their accounts before sending them the Clines. You will then have to remove the ban manually or wait for the iptables flush to purge it for you if you haven't banned illegal logins permanently, otherwise new peers may never be able to connect !<br /><br /><br /><br /><strong>Dreambox</strong><br /><br />Although the scripts should run (with ssh and remote firewall) on dreambox busybox default shell (ash), as they do on my debian stable busybox (1.1.3) binary, the problem i have with that shell, or with ash (dash on debian), is that a parent script will not "release" child scripts that have ended and will then generate tons of zombie processes also known as defunct processes.<br /><br />If you know a way around that busybox ash shell problem, please contact me, it will most certainly be very helpfull to dreambox users.<br /><br />I must stress out the fact that running the scripts as they are on the dreambox will work for a short period of time and then stop working when the large number of defunct processes will have filled the system's proc table. It will also most certainly make the dreambox system pretty unstable or even make it crash.. <!-- / message --><!-- sig --></p>
<div><br />
<div class="hr" style="WIDTH: 100px"><hr /></div>
<div class="spacer"></div>
<strong>[</strong><a href="http://www.eurocardsharing.com/f163/cccam-monitoring-firewalling-protect-your-cccam-server-86467" target="_blank"><font color="#496690">Protect your cccam server</font></a><strong>] [</strong><a href="http://www.eurocardsharing.com/f199/fast-24-7-server-not-home-74651" target="_blank"><font color="#496690">My free exchange Cccam server</font></a><strong>]</strong> </div>
<!-- / sig --><!-- edit note -->]]></description>
			<link>http://iii80.com//?action=show&amp;id=522</link>
			<pubDate>2010-08-04 13:26</pubDate>
		</item>
		<item>
			<title>Short How To for oscam on Asus WL500gp</title>
			<author>水中月</author>
			<description><![CDATA[<p><strong>Short How To for oscam on Asus WL500gp</strong></p>
<p>ASUS WL500gP<br /><br />good instructions on how to install Linux on the Asus;<br /><a onclick="pageTracker._trackPageview ('/outgoing/http_wl500g_info_showthread_php_t_10307');" href="http://wl500g.info/showthread.php?t=10307" target="_blank"><font color="#496690">http://wl500g.info/showthread.php?t=10307</font></a><br /><br />instructions on how to install oscam on the Asus<br /><a onclick="pageTracker._trackPageview ('/outgoing/http_oscam_ump2002_net_board_thread_php_threadid_236');" href="http://oscam.ump2002.net/board/thread.php?threadid=236" target="_blank"><font color="#496690">http://oscam.ump2002.net/board/thread.php?threadid=236</font></a><br /><br />required (attached to previous link)<br />1. pcsc-lite_155_thE29.ipk<br />ipkg install pcsc-lite_155_thE29.ipk<br /><br />2. ccid_1311_thE29.ipk<br />ipkg install ccid_1311_thE29.ipk<br /><br />3. oscam-0.99.4svn2178-streamnonusb-oleg-thE29.ipk<br /><br />save settings;<br />flashfs save && flashfs commit && flashfs enable && reboot<br /><br />1. Start pcscd<br />2. Start oscam (oscam -d)<br /><br />Open the <span class="highlight"><strong><font color="#ff0000">ports</font></strong></span> in the router !<br /><br />Sample configuration files;<br />/opt/etc/oscam/oscam.user<br />#<br /># user configuration<br />#<br />[account]<br />user = user<br />pwd = password<br />monlevel = 0<br />uniq = 1<br />group = 1<br />au = reader1<br />services = services1<br />ident = 0100:00006a<br />caid = 0100<br /><br />/opt/etc/oscam/oscam.server<br /># <br /># USB serial reader <br />[reader] <br />label = reader1 <br /># pcsc for -a.o. Omnikey 3121 pcsc readers <br />protocol = pcsc <br />detect = CD <br /># /dev/ttyS1 is the second USB port<br />device = /dev/ttyS1 <br />aeskey = 3BF711000140967070370E6CB6D60000<br />cardmhz = 357 <br />mhz = 357 <br />group = 1 <br />emmcache = 1,3,2 <br />services = services1<br />caid = 0100 <br /><br />/opt/etc/oscam/oscam.conf<br /># <br /># main configuration<br /># <br />[global] <br />nice = -1 <br />WaitForCards = 1<br /><br /># logging <br />pidfile = /var/run/oscam.pid<br />logfile = /var/log/oscam/oscam.log<br />usrfile = /var/log/oscam/oscamuser.log<br />cwlogdir = /var/log/oscam/cw<br /><br /># monitor <br />[monitor] <br />port = 988 <br />aulow = 120<br />monlevel = 1 <br /><br />[cccam] <br />port = 12000 <br />version = 2.1.4 <br />build = 1234 <br />reshare = 2 </p>]]></description>
			<link>http://iii80.com//?action=show&amp;id=521</link>
			<pubDate>2010-08-03 23:02</pubDate>
		</item>
		<item>
			<title>How to run 2 cccam servers on one linux server</title>
			<author>水中月</author>
			<description><![CDATA[<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 50px; TEXT-ALIGN: left">CCcam.x86 -C configfile1
CCcam.x86 -C configfile2</pre>
</div>
<p> </p>
<p><strong>hello all,<br />i have written/modify a check script for all the CCcam's there are running,<br />to run every */5 * * * * (ore what time you want)<br />in crontab for when One of the CCcam should stops.<br />*/5 * * * * /var/script/MoreCCcamCheck.sh<br />it checks all CCcam, in this case there are 3 running CCcam's <br />if you have more or less CCcam<br />just modify by add or remove a last part ( it shown i blue) <br />and you may have to change the file/folder/directory (this is my setup)<br /><br />it writes in /var/cccamlog a cccam.check if CCcam is oke ore when it is restarted<br /><br />this script works on Ubuntu (maybe someone can test it on Debian, i think<br />it will work)<br /><br /></strong><strong><font size="3">I have written this script for the ones who want to use it <br />feel free to modefy the script, it is finally or hobby to share.</font><br /></strong>xxxxxx = inlogname from distro<br /><br />if you want date and time in log ad the red lines.<br />then you can see when it has restarted and what CCcam it was.<br />--------------------------------------------------------------------------<br />MoreCCcamCheck.sh<br />--------------------------------------------------------------------------<br />#!/bin/sh <br />process=`ps auxwww | grep CCcam_1.x86 | grep -v grep | awk '{print $1}'`<br />if [ -z "$process" ]; then<br />echo "Couldn't find CCcam_1.x86 running. Show user Nodeid then removing nodeid and Restarting CCcam Server" >> /var/cccamlog/cccam.check<br /><font color="#ff0000">echo && date >> /var/cccamlog/cccam.check</font><br />chown xxxxxxx /tmp/.CCcam.nodeid<br />nohup rm /tmp/.CCcam.nodeid && /usr/local/bin/CCcam_1.x86 -C /var/etc/CCcam_1.cfg <br />else echo "CCcam_1.x86 is still OK!" >> /var/cccamlog/cccam.check<br />fi<br />process=`ps auxwww | grep CCcam_2.x86 | grep -v grep | awk '{print $1}'`<br />if [ -z "$process" ]; then<br />echo "Couldn't find CCcam_2.x86 running. Show user Nodeid then removing nodeid and Restarting CCcam Server" >> /var/cccamlog/cccam.check<br /><font color="#ff0000">echo && date >> /var/cccamlog/cccam.check</font><br />chown xxxxxxx /tmp/.CCcam.nodeid<br />nohup rm /tmp/.CCcam.nodeid && /usr/local/bin/CCcam_2.x86 -C /var/etc/CCcam_2.cfg <br />else echo "CCcam_2.x86 is still OK!" >> /var/cccamlog/cccam.check<br />fi<br /><font color="#0000ff">process=`ps auxwww | grep CCcam_3.x86 | grep -v grep | awk '{print $1}'`<br />if [ -z "$process" ]; then<br />echo "Couldn't find CCcam_3.x86 running. Show user Nodeid then removing nodeid and Restarting CCcam Server" >> /var/cccamlog/cccam.check<br /><font color="#ff0000">echo && date >> /var/cccamlog/cccam.check</font><br />chown xxxxxxx /tmp/.CCcam.nodeid<br />nohup rm /tmp/.CCcam.nodeid && /usr/local/bin/CCcam_3.x86 -C /var/etc/CCcam_3.cfg <br />else echo "CCcam_3.x86 is still OK!" >> /var/cccamlog/cccam.check<br />fi</font><br /><br /><strong><font color="#000080"><u>for all who like the post feel free to hit the thanks button</u>.</font></strong><br /><br />youknowhoo<img class="inlineimg" title="Biggrin" alt="" border="0" src="http://www.eurocardsharing.com/images/smilies/biggrin.gif" /><br /><br /><em><font color="#666686"><font size="1">(10-October-2009 20:09)</font></font></em><br /><strong>and a config update script it is written by CC_Share but i modified it a little.<br />the script works great.<br />you can use it also for 1 config as i do, you only have to cut the blue part.<br />and rename the FILE & CONFIGOLD</strong><br />--------------------------------------------------------------------------<br />MoreConfigUpdate.sh<br />--------------------------------------------------------------------------<br />#!/bin/bash<br />#Script to process new config and backup old one<br />#Script designed and written by CC_Share and modified by Youknowhoo<br />SOURCE=/var/config<br />TARGET=/var/etc<br />FILE=CCcam_1.cfg<br />BACKUPDIR=/var/backup<br />CONFIGOLD=CCcam_1.old<br />if test -f $SOURCE/$FILE ; then<br />echo "New Config Present"<br />if test -d $BACKUPDIR ; then<br />if test -f $BACKUPDIR/$CONFIGOLD ; then<br />echo "Removing OLD config file from backup directory"<br />rm $BACKUPDIR/$CONFIGOLD<br />else<br />echo "No OLD config to remove."<br />fi<br />if test -f $BACKUPDIR/$FILE ; then<br />echo "Renaming Backup to old config"<br />cp $BACKUPDIR/$FILE $BACKUPDIR/$CONFIGOLD<br />rm $BACKUPDIR/$FILE<br />else<br />echo "No Backupfile present yet"<br />fi<br />if test -f $TARGET/$FILE ; then<br />echo "Copying Original config to Backup directory"<br />cp $TARGET/$FILE $BACKUPDIR<br />rm $TARGET/$FILE<br />else<br />echo "No Original Config File Present!?!?"<br />fi<br />else<br />echo "Backup directory does not exist."<br />echo "making new directory"<br />mkdir $BACKUPDIR<br />if test -f $TARGET/$FILE ; then<br />echo "Copying Original config to Backup directory"<br />cp $TARGET/$FILE $BACKUPDIR<br />else<br />echo "No Original Config File Present!?!?"<br />fi<br />fi<br />echo "Moving New config file to "$TARGET<br />cp $SOURCE/$FILE $TARGET<br />rm $SOURCE/$FILE<br />else<br />echo "No New Config present, Nothing to process"<br />fi<br /><font color="#0000ff">SOURCE=/var/config<br />TARGET=/var/etc<br />FILE=CCcam_2.cfg<br />BACKUPDIR=/var/backup<br />CONFIGOLD=CCcam_2.old<br />if test -f $SOURCE/$FILE ; then<br />echo "New Config Present"<br />if test -d $BACKUPDIR ; then<br />if test -f $BACKUPDIR/$CONFIGOLD ; then<br />echo "Removing OLD config file from backup directory"<br />rm $BACKUPDIR/$CONFIGOLD<br />else<br />echo "No OLD config to remove."<br />fi<br />if test -f $BACKUPDIR/$FILE ; then<br />echo "Renaming Backup to old config"<br />cp $BACKUPDIR/$FILE $BACKUPDIR/$CONFIGOLD<br />rm $BACKUPDIR/$FILE<br />else<br />echo "No Backupfile present yet"<br />fi<br />if test -f $TARGET/$FILE ; then<br />echo "Copying Original config to Backup directory"<br />cp $TARGET/$FILE $BACKUPDIR<br />rm $TARGET/$FILE<br />else<br />echo "No Original Config File Present!?!?"<br />fi<br />else<br />echo "Backup directory does not exist."<br />echo "making new directory"<br />mkdir $BACKUPDIR<br />if test -f $TARGET/$FILE ; then<br />echo "Copying Original config to Backup directory"<br />cp $TARGET/$FILE $BACKUPDIR<br />else<br />echo "No Original Config File Present!?!?"<br />fi<br />fi<br />echo "Moving New config file to "$TARGET<br />cp $SOURCE/$FILE $TARGET<br />rm $SOURCE/$FILE<br />else<br />echo "No New Config present, Nothing to process"<br />fi<br />SOURCE=/var/config<br />TARGET=/var/etc<br />FILE=CCcam_3.cfg<br />BACKUPDIR=/var/backup<br />CONFIGOLD=CCcam_3.old<br />if test -f $SOURCE/$FILE ; then<br />echo "New Config Present"<br />if test -d $BACKUPDIR ; then<br />if test -f $BACKUPDIR/$CONFIGOLD ; then<br />echo "Removing OLD config file from backup directory"<br />rm $BACKUPDIR/$CONFIGOLD<br />else<br />echo "No OLD config to remove."<br />fi<br />if test -f $BACKUPDIR/$FILE ; then<br />echo "Renaming Backup to old config"<br />cp $BACKUPDIR/$FILE $BACKUPDIR/$CONFIGOLD<br />rm $BACKUPDIR/$FILE<br />else<br />echo "No Backupfile present yet"<br />fi<br />if test -f $TARGET/$FILE ; then<br />echo "Copying Original config to Backup directory"<br />cp $TARGET/$FILE $BACKUPDIR<br />rm $TARGET/$FILE<br />else<br />echo "No Original Config File Present!?!?"<br />fi<br />else<br />echo "Backup directory does not exist."<br />echo "making new directory"<br />mkdir $BACKUPDIR<br />if test -f $TARGET/$FILE ; then<br />echo "Copying Original config to Backup directory"<br />cp $TARGET/$FILE $BACKUPDIR<br />else<br />echo "No Original Config File Present!?!?"<br />fi<br />fi<br />echo "Moving New config file to "$TARGET<br />cp $SOURCE/$FILE $TARGET<br />rm $SOURCE/$FILE<br />else<br />echo "No New Config present, Nothing to process"<br />fi</font><br />exit</p>
<p> </p>
<p> </p>
<p> </p>
<p>name startscript: MoreCCcamstart.sh<br />--------------------------------------------------------------------------<br /><br />#!/bin/bash<br />#Script to start more then one CCcam's with different nodeid<br />#Script is written by Youknowhoo.<br />echo "Starting first CCcam server"<br />/usr/local/bin/CCcam_1.x86 -C /var/etc/CCcam_1.cfg<br />echo "chown owner nodeid"<br />chown xxxxx /tmp/.CCcam.nodeid<br />echo "Removing nodeid and starting second CCcam server"<br />rm /tmp/.CCcam.nodeid && /usr/local/bin/CCcam_2.x86 -C /var/etc/CCcam_2.cfg<br />echo "chown owner nodeid"<br />chown xxxxx /tmp/.CCcam.nodeid<br />echo "Removing nodeid and starting third CCcam server"<br />rm /tmp/.CCcam.nodeid && /usr/local/bin/CCcam_3.x86 -C /var/etc/CCcam_3.cfg<br /><br /><br />xxxxx = user/inlog name from the linux distro<br />--------------------------------------------------------------------------<br />name stopscript : MoreCCcamstop.sh<br />--------------------------------------------------------------------------<br />#!/bin/bash<br />#Script to stop all CCcam that are running.<br />#Script written by Youknowhoo<br />echo "stop first CCcam server"<br />killall CCcam_1.x86<br />echo "stop second CCcam server"<br />killall CCcam_2.x86<br />echo "stop third CCcam server"<br />killall CCcam_3.x86<br /><br /><br /></p>]]></description>
			<link>http://iii80.com//?action=show&amp;id=520</link>
			<pubDate>2010-08-03 22:52</pubDate>
		</item>
		<item>
			<title>some script for cccam</title>
			<author>水中月</author>
			<description><![CDATA[<p>some script for cccam</p>
<p><strong>CCcam Monitoring / Firewalling - Protect your cccam server </strong></p>
<p>- UPDATED - <br />Changelog :<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Quote:</div>
<table cellspacing="0" cellpadding="6" width="100%" border="0">
    <tbody>
        <tr>
            <td class="alt2" style="BORDER-RIGHT: 1px inset; BORDER-TOP: 1px inset; BORDER-LEFT: 1px inset; BORDER-BOTTOM: 1px inset">Version 2g :<br />- updated for cccam 2.1.2, now compatible with 2.0.x and 2.1.x<br />- added simple startup script<br />- reverted scripts to default shell executor "/bin/sh"<br />- minor fixes and syntax changes </td>
        </tr>
    </tbody>
</table>
</div>
<p>Hi,<br /><br />this set of scripts will help you protect your cccam server against various events (bad command and illegal logins) generated by your peers in order to increase cccam service stability.<br />The basic idea is to use the linux firewall (iptables) in "realtime" to block cccam traffic for specific peers (ip) based on cccam debug output.<br /><br />This work was initialy inspired by discussions on this thread <a href="http://www.eurocardsharing.com/f78/how-solve-disconnecting-client-issue-66845" target="_blank"><font color="#496690">"How to solve the disconnecting client issue"</font></a> and is a partial answer to that specific cccam problem.<br /><br />Although all of it was designed on a debian standlone cccam server having a local firewall, it should also work if your firewall is on a remote machine on your local network. <br /><br />The <strong>Dreambox setup is still NOT working at the moment</strong> and will be discussed at the end of the tutorial.<br /><br /><br />I have been using the scripts for many months with cccam 2.0.10 / 2.1.0 / 2.1.2. I didn't notice any cccam crashes or problems with peers. My server has 50-70 peers and gets between 30 and 100 bad commands a day but their effect is barely noticeable.<br /><br /><strong>Concerning CCcam 2.1.2</strong>, my tests showed increased problems with peers regarding the login process, leading to numerous peer bans and peers disconnections. Something has definitely changed in that cccam version that was not present in cccam < 2.1.2.<br /><br />I personally reverted to cccam 2.1.0 (you can probably use 2.1.1 safely too) and won't be using 2.1.2, i'll wait for 2.1.3 and see what happens then, i suggest you do the same unless you're satisfied with 2.1.2.<br /><br />The only advantage i can see with 2.1.2 is that it lets my script ban login floods, i'll work on that feature for cccam < 2.1.2 when i have time, for it is the last missing protection i can think of regarding cccam problems, i also noticed some ecm requests floods but i probably never will filter thoses.<br /><br /><strong>Features</strong> :<br />- block peers based on a specific number of bad commands or slow "cards" commands, for any number of minutes.<br />- block peers doing "illegal logins" (no account or bad password) for any number of minutes.<br />- protect cccam accounts or ips from being blocked or give them a different error count.<br />- filter main log and keep only relevant information (reduce log size) and split logs (monitoring, ecm, logins).<br />- modify monitoring behaviour, turn on/off firewall blocking or logs without having to restart cccam.<br />- iptables rules use user defined chains in order to keep your iptables firewall fast, clean and safe.<br /><br /><br /><br /><strong>Prerequires</strong> :<br />- cccam running in debug mode with timestamps (-d -t)<br />- iptables (optional - can be disabled to use only logs)<br />- sudo to access iptables for your cccam user, with or without password (optional - sudo can be omitted or use of ssh to manage an external firewall)<br />- cron to perform iptables flush rules (unban) (optional if iptables is not used)<br />- bash/sh/ash(/busybox) POSIX shell script (read the dreambox section for more info on the scripting problems with ash/busybox shells) and some basic shell commands cat, echo, cut, grep..<br /><br /><br /><br /><strong>Install</strong> :<br />There's not much to do if you know that your system matches the prerequires above.<br /><br />Open a command line window and make sure you are running your cccam user.<br />Put the scripts start.sh config.sh fork.sh monitor.sh iptables.sh, in your cccam directory along with the two "protected_account" "protected_ip" files if you need them.<br /><br />Make sure the scripts can run on your shell, to do that first find out which shell you are running, there's a great change your linux system has links to simulate the precense of sh or bash but you can check your installed shells with the "whereis" command ("#whereis sh", "#whereis ash"...).<br />The scripts should be POSIX compatible to run on most shells and are configured to run on ash which is supposed to be faster than sh/bash, with the exception of "fork.sh" which MUST run on sh/bash or any shell that will release terminated child scripts and won't generate zombie processes (defunct).<br />If you don't want to install or use "ash" you can edit each script and change their top line :<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">#!/bin/ash</pre>
</div>
<p>with something matching your shell, like :<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">#!/bin/bash</pre>
</div>
<p>You need to edit/copy config.example.sh to config.sh, and make config.sh match your setup, each config line has comments.<br />Make sure you get the iptables parameters right if you intend to use it.<br /><br /><strong>Be very careful to properly set CCCMODE to match your cccam version !</strong><br /><br />fork.sh will try to create the necessary directories LOGDIR and WORKDIR (see config.sh), but if for some reason it doesn't work and shows errors, create two subdirectories to put logs and work files, default directories are "logs" and "monitor", path are defined in config.sh and can be set to whatever you'd like :<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 82px; TEXT-ALIGN: left">cd /path/to/cccam
mkdir monitor
mkdir logs
chmod 0775 logs monitor</pre>
</div>
<p>Make sure the scripts are executable : <br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">chmod +x  start.sh config.sh fork.sh monitor.sh iptables.sh</pre>
</div>
<p>You can test your iptables setup by running the init command :<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">./iptables.sh init</pre>
</div>
<p>iptables init is always run when the fork.sh script starts so you don't actually need to run the init command manually but if your get some errors you will have to fix them.<br />If you run the init multiple times you will have two errors "iptables: Chain already exists", this is not a problem.<br /><br />Errors are redirected to you main log file (default "logs/monitor.log") so read it to see if errors appear.<br /><br />Make sure cccam output looks like this :<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 66px; TEXT-ALIGN: left">12:15:21.499 CCcam: deleting client xx.xx.xxx.xxx(userX), bad command
12:15:21.501 CCcam: deleting client yy.yyy.yyy.yy(userY), read result -1
12:15:27.896 CCcam: 1498 cards --> client yy.yyy.yyy.yy(userY) (took 0.2730 seconds)</pre>
</div>
<p>you can test that by running cccam in the foreground with :<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">./CCcam.x86 -d -t -C ./CCcam.cfg</pre>
</div>
<p>according to cccam --help, the only thing that could be missing is the timestamp. Although i think that -d activates debug mode, not only foreground, and then outputs everything including timpestamps, also overriding cccam config options like DEBUG..<br /><br /><br />Finally when you're all set you can run cccam with the following command from the cccam directory :<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">./CCcam.x86 -d -t -C ./CCcam.cfg | ./fork.sh >> /path/to/cccam/logs/monitor.log &</pre>
</div>
<p>Or use the start.sh script :<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">./start.sh start</pre>
</div>
<p>start.sh has to be placed in the same directory as the other scripts and has the following commands "start / stop / restart". It uses regular ps/kill commands so it should be compatible with most systems. And can be used to monitor cccam status and restart it if necessary so you can use the "start" command in your cron to check if cccam has crashed and restart it.<br /><br /><br />You can then check out the main log with :<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">tail -n30 -f logs/monitor.log</pre>
</div>
<p>if everything works fine and you are using the firewall, you have to add a cron command to flush rules when they expire.<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">*/1 * * * * /path/to/cccam/iptables.sh flush >> /path/to/cccam/logs/monitor.log 2>&1</pre>
</div>
<p>It will run the iptables flush script every minute and delete rules that have expired (exceeded the ban duration)<br /><br /><br /><br /><br /><strong>Usage</strong> :<br /><br />CCCam 2.1.0/2.1.1 specific :<br />Those two versions produce a lot more "bad command" events than other versions because some events were renamed as bad commands and were not before, knowing that i'd suggest being a little more tolerant regard the bad command counts and bans if you notice a large number of bans, so you could use settings like the following :<br /><br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 82px; TEXT-ALIGN: left">BADDELAY=2               # bad command count duration in minutes
BADCOUNT=5              # bad command count
BADCOUNT_IG=10        # bad command count for protected accounts
BAN=60                      # ban duration in minutes</pre>
</div>
<p><br />- CCCMODE : defines your cccam version, important if you want this script to work. Basically there's one mode "0" for all cccam but 2.1.2, and one mode "1" for cccam 2.1.2 and probably upcoming cccam revisions.<br /><br />- BADCOUNT/BADCOUNT_IG : Knowing that any peer can generate a bad command it is probably not a good idea to ban them at the first one. A good peer will most likely succeed to connect on its second attempt.<br /><br />- BADDELAY/BAN : bad commands being mostly caused by networking problems (probably very slow lines) it can be something temporary. That's why a 120min ban is usually enough to let the peer try again at a later time when the network conditions have changed. Using a short ban duration like 30min or less will simply let the bad peer send more commands and cripple your cccam server. If you let a peer send more than one bad command then the error count spreads accross the BADDELAY duration.<br /><br />- BANLOGIN : banning illegal logins is optional but after exchanging Clines with many peers you will find out that a bunch of them won't remove your Cline, getting your cccam server to handle a large amount of login attempts that are all doomed to failure. I just thought that filtering that traffic wouldn't hurt (read bugs and limitations below). It should also protect your server from brute force login attacks although i doubt anyone would try to do such a visible hack.<br /><br />- LOGUNKNOWN/UKNOWNMAINLOG : are used to help cccam identify accounts that produce some events. LOGUNKNOWN will tell cccam to look for missing account names for the event processed by looking at current work/temp files. In addition, the optional UKNOWNMAINLOG will let cccam look into the main log file, this can be very helpful but can also produce some nasty side effects if your main log is big. So you should make sure to manage (rotate/purge on a daily basis) your main log file if you intend to use that option.<br /><br />- CARDSDELAY/CARDSBAD : for CCcam 2.0.x-2.1.1 - has no impact on cccam 2.1.2 . That one is a bit more tricky, it tells the monitoring script to interpret "xxxx cards --> client" commands as a bad command based on its duration. I have indeed noticed that peers taking very long time (a few seconds) to receive the cards info will disconnect active peers in the exact same way a bad command does ! Unfortunately i wasn't really able to identify a very precise duration above which diconnections happen so i used a two levels trigger to manage those commands.<br />CARDSDELAY is the max durations in seconds above which the peer will get a "bad command" added to its log, but it will never trigger a ban action, the trigger will only log the event and when a "real" bad command occurs at a later time then it will count as a bad command. The use of this option is quite restrictive, the default is 4 seconds.<br />CARDSBAD is the max number of seconds allowed for a "xxxx cards --> client" command, above which a ban action is triggered, as if a real bad command was seen. CARDSBAD is probably more important than CARDSDELAY because it will actively try to ban peers with a very slow network, it will act in the exact same way as a bad command action does, respecting the same ban trigger options (BADCOUNT/BADDELAY). CARDSBAD should always be greater than CARDSDELAY.<br /><br />- DEBUG : adds some debug data to a $LOGDIR/debug.log file. Probably of no interest to you and should stay disabled (=0).<br /><br />- Understand that when a peer is banned, he will see your server as offline but you will still be able to connect to his, you know what that means.<br /><br /><br /><br /><strong>Files</strong> :<br />Version 2g : <a onclick="pageTracker._trackPageview ('/outgoing/http_www_megaupload_com_d_3NZOPSRM');" href="http://www.megaupload.com/?d=3NZOPSRM" target="_blank"><font color="#496690">Download</font></a><br />("protected_account" and "protected_ip" are two empty files in which you can put account names and ips, one by line, that you want to "protect" from basic ban rules, see the documentation above for details)<br /><br /><br /><br /><strong>Advanced</strong> :<br />- you can rotate logs, all redirects use "append" (>>).<br /><br />- no sudo password<br />you can allow access to iptables for your cccam user (if not root) without sudo password by adding the following line to your "/etc/sudoers" file.<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">cccamuser   ALL=NOPASSWD:/sbin/iptables</pre>
</div>
<p>That way you don't have to give a large sudo access to your cccam user and you don't have to put a sudo password in config.sh SUPASS option. The cccam user only requires sudo (root) access to iptables, nothing else.<br /><br />- using a remote firewall<br />To use a remote iptables firewall on your local network you will have to replace the sudo command with a ssh one. ssh will try to connect to a remote linux system and execute the iptables command there, then return the command output to the script making the iptables command run exactly as if it was executed localy.<br />I will guide you quickly through a basic ssh setup but if you don't know what you are doing i'd suggest googling some <a onclick="pageTracker._trackPageview ('/outgoing/http_www_puddingonline_com_dave_publications_SSH_with_Keys_HOWTO_document_html_SSH_with_Keys_HOWTO_4_html');" href="http://www.puddingonline.com/~dave/publications/SSH-with-Keys-HOWTO/document/html/SSH-with-Keys-HOWTO-4.html" target="_blank"><font color="#496690">SSH HOWTOs</font></a>.<br /><br />A proper SSH setup would be as follows :<br />As root, generate a key pair using your "cccam" system's (where cccam monitoring script runs) ssh key generator (ssh-keygen on debian), if any, with the following command :<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">ssh-keygen -t dsa</pre>
</div>
<p>When asked for a "passphrase", we won't enter one. Just press enter twice.<br />That should produce two files in your root home directory : "~/.ssh/id_dsa.pub" and "~/.ssh/id_dsa"<br /><br />Copy the one line content of the new "~/.ssh/id_dsa.pub" file to the following file on your remote server root user directory : /root/.ssh/authorized_keys2<br />Depending on your remote server ssh configuration, the file could also be : /root/.ssh/authorized_keys<br /><br />Now from the cccam system you should be able to ssh your remote server with the command :<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">ssh root@remoteip</pre>
</div>
<p>If it asks you to keep a footprint of the new remote system, say yes and it shouldn't bother you with that later, you can "exit" ssh now.<br />If it worked you can also try accessing the remote iptables firewall with that command, from the cccam system :<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">ssh root@remoteip /usr/bin/iptables -L -n</pre>
</div>
<p>It should display your firewall configuration for INPUT OUTPUT FORWARD chains.<br /><br />Then set the SUDO option in config.sh, like this :<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">SUDO="/usr/bin/ssh -x root@remoteip"</pre>
</div>
<p>you can also empty the SUPASS option.<br /><br />in order to make sure you have a working remote iptables setup you can try running the iptables.sh init command from the cccam system, as follows :<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">./iptables.sh init</pre>
</div>
<p>If you run it twice it should display two errors : "iptables: Chain already exists"<br />That means the cccam chains have been created on your firewall and your setup works.<br /><br />You can now run cccam as described in the main install guide above.<br /><br /><br /><br /><br /><strong>Known bugs and limitations</strong><br /><br />- log file output lines may be missplaced, some commands take longer to execute than others and the command output then gets into the log file a bit late, but this is usually something very localized and every line having a timestamp you can always understand what happened.<br /><br />- some iptables rules may be insterted more than once when a event is not processed fast enough, but it doesn't matter because iptables won't mind and the flush script makes sure duplicate rules are removed.<br /><br />- reloading your firewall should delete cccam init. you will have to init cccam iptables manually to fix that, with "./iptables.sh init". The good thing is that it should not get the scripts or cccam to crash, so cccam will not really care but you will get lots of errors in your cccam monitoring log..<br /><br />- banning illegal logins will most certainly ban the new peers you have exchanged Clines with if you haven't activated their accounts before sending them the Clines. You will then have to remove the ban manually or wait for the iptables flush to purge it for you if you haven't banned illegal logins permanently, otherwise new peers may never be able to connect !<br /><br /><br /><br /><strong>Dreambox</strong><br /><br />Although the scripts should run (with ssh and remote firewall) on dreambox busybox default shell (ash), as they do on my debian stable busybox (1.1.3) binary, the problem i have with that shell, or with ash (dash on debian), is that a parent script will not "release" child scripts that have ended and will then generate tons of zombie processes also known as defunct processes.<br /><br />If you know a way around that busybox ash shell problem, please contact me, it will most certainly be very helpfull to dreambox users.<br /><br />I must stress out the fact that running the scripts as they are on the dreambox will work for a short period of time and then stop working when the large number of defunct processes will have filled the system's proc table. It will also most certainly make the dreambox system pretty unstable or even make it crash.. <!-- / message --><!-- sig --></p>
<div><br />
<div class="hr" style="WIDTH: 100px"><hr /></div>
<div class="spacer"></div>
<strong>[</strong><a href="http://www.eurocardsharing.com/f163/cccam-monitoring-firewalling-protect-your-cccam-server-86467" target="_blank"><font color="#496690">Protect your cccam server</font></a><strong>] [</strong><a href="http://www.eurocardsharing.com/f199/fast-24-7-server-not-home-74651" target="_blank"><font color="#496690">My free exchange Cccam server</font></a><strong>]</strong> </div>
<div></div>
<div></div>
<div></div>
<div><strong>script to check if cccam is running</strong></div>
<div><strong></strong></div>
<div>i was trying to implement a script that checks the cccam if it runs ok<br /><br />here is my attemp<br /><br />#!/bin/sh<br />if ps x |grep -v grep |grep -c CCcam >/dev/null<br />then<br />#user and pass from the webinfo page.<br />if wget <a onclick="pageTracker._trackPageview ('/outgoing/http_user_pass_192_168_1_10_16001');" href="http://user:pass@192.168.1.10:16001/" target="_blank"><font color="#496690">http://user:pass@192.168.1.10:16001</font></a><br />then<br />rm /emu/script/index.html<br />echo "ok"<br />else<br />echo "not ok"<br />/emu/script/cccam stop<br />/emu/script/cccam start<br />fi<br />else<br />echo "not ok"<br />/emu/script/cccam stop<br />/emu/script/cccam start<br />fi<br /><br />you need to replace the user, pass and the ip to be the same as your webinfo information.<br /><br />create a file calles checkcccam.sh<br />using emacs or any other editor.<br />then chmod 755 checkcccam.sh <br />and you are ready to go!<br /><br />also the line for crontabl ppl.<br /><br />*/15 * * * * /emu/script/checkcccam.sh >>/emu/log/checkcccam.log 2>&1<br /><br /><br />this will check the cccam server every 15 minutes.<br /><br />if anyone can suggest anything please do so.<br /><br />thanks. </div>
<div></div>
<div></div>
<div><strong>[Script] Auto ban Illegal CCcam Users in Debian </strong></div>
<div><strong></strong></div>
<div>After some time, You see peers that don't delete you're line once removed or worse, they hand out the line to all kind of people who try to gain access to you're server.<br /><br />For this i took the basic idea of a script from <strong>Unlocker-al</strong> and put together this little ban script.<br /><br />
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 498px; TEXT-ALIGN: left">#!/bin/sh
###########################
## Auto Ban script       ##
## Illegal CCcam Users   ##
## Written By CC_Share   ##
## Thanks to Unlocker-AL ##
## For the Basic idea    ##
###########################
workdir="/"                        #This is there the debug info from CCcam is dumped
firewall="/"          #The saved firewall rules
logdir="/emu/log"                       #The logfile directory
EMAIL=""                 #Email adres to mail result to
SUBJECT="Illegal Userlist CCcam"        #Subject title of the email
EMAILMESSAGE="/emu/log/illegaluser.txt" #List that contains the Illegal users
rm $workdir/debug.old
cp $workdir/debug.txt $workdir/debug.old
cp $logdir/iptables-save.new $logdir/iptables-save.old
cat $workdir/debug.old|grep illegal > $logdir/illegaluser.log
grep 'illegal' $logdir/illegaluser.log | awk -F" " '{print $5,$7}' > $logdir/illegaluser.txt
grep 'illegal' $logdir/illegaluser.log | awk -F" " '{print $7}' | grep -o '^[0-9]\{1,3\}\.[0-9]\{1,3\}\.[0-9]\{1,3\}\.[0-9]\{1,3\}' > $logdir/badIP.out
awk '
{s[$0]++}
END {
for(i in s) {
if(s[i]>1) {
print i
}
 }
 }' $logdir/badIP.out > $logdir/badIP.block
while IFS= read -r EachLine
do
command="iptables -A INPUT -s "$EachLine" -j DROP"
echo $command
$command
done < $logdir/badIP.block
rm $logdir/badIP.block
if [ -s $logdir/illegaluser.txt ] ; then
iptables-save -c > $logdir/iptables-save.new
/usr/bin/nail -s "$SUBJECT" "$EMAIL" < $EMAILMESSAGE
else
echo "No Illegal Users found right now"
fi
sleep 1
> $workdir/debug.txt
exit 0</pre>
</div>
This script will scan you're debug file for illegal users, sort out the username and ip and insert the IP in ip-tables.<br /><br />If you want, the script can also mail you the result so you know what users are put in ip-tables and gives you the advantage to check if it's not a valid user.<br /><br />You can put this script in the crontab to enable automatic checking.<br />The following is an example how to install.<br /><br />
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">./CCcam.x86 -dv > /home/debug.txt</pre>
</div>
then change the following lines in the script to match the debug file and it's location.<br />
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">workdir="/"</pre>
</div>
Should be
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">workdir="/home"</pre>
</div>
and this line
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">firewall="/"</pre>
</div>
Should be changed to where you want the firewall rules to be saved
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">firewall="/emu/log/"</pre>
</div>
To insert it in the crontab, edit it and insert this line:<br />
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">00 */1  * * * root /emu/script/./illegal.sh</pre>
</div>
This will run the script every whole hour.<br /><br /><br /><br />For the mail function to work, you have to do the following:<br />
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 66px; TEXT-ALIGN: left">apt-get install nail
apt-get install exim4
dpkg-reconfigure exim4-config</pre>
</div>
Insert here a valid email adress<br />
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">EMAIL=""</pre>
</div>
and it will mail you every time it runs and finds an illegal user. If no user is found, it will not mail you. </div>
<!-- / sig --><!-- edit note -->]]></description>
			<link>http://iii80.com//?action=show&amp;id=519</link>
			<pubDate>2010-08-03 22:17</pubDate>
		</item>
		<item>
			<title>Building Debian Linux server with CCcam (手动)</title>
			<author>水中月</author>
			<description><![CDATA[<p><strong>Howto: Building Debian Linux server with CCcam (手动)</strong></p>
<p><strong>This how-to will cover the basic installation of Debian linux and getting CCcam up and running on it.<br /><br /></strong>This How-to is still <strong>WIP by <font color="#ff0000">CC_Share</font></strong><br /><br /><strong>--Todo--</strong><br /><br />---------------------------------------<br /><br />First download the netinstall cd of debian linux<br />You can download it from the following URL:<br /><strong>Link </strong><a onclick="pageTracker._trackPageview ('/outgoing/http_cdimage_debian_org_debian_cd_5_0_0_i386_iso_cd_debian_500_i386_netinst_iso');" href="http://cdimage.debian.org/debian-cd/5.0.0/i386/iso-cd/debian-500-i386-netinst.iso" target="_blank"><font color="#496690">http://cdimage.debian.org/debian-cd/...86-netinst.iso</font></a><br /><br />This will install the basic debian linux system on you're harddisk.<br />Boot the computer from the CD you just created.<br /><img alt="" src="http://i152.photobucket.com/albums/s168/ccshare/0000.jpg" onload="NcodeImageResizer.createOn(this);" border="0" originalheight="380" originalwidth="500" /><br /><em>Just press enter here to start the installation</em><br /><br /><img alt="" src="http://i152.photobucket.com/albums/s168/ccshare/0001.jpg" onload="NcodeImageResizer.createOn(this);" border="0" originalheight="376" originalwidth="500" /><br /><em>Select the language you prefer</em><br /><br /><img alt="" src="http://i152.photobucket.com/albums/s168/ccshare/0002.jpg" onload="NcodeImageResizer.createOn(this);" border="0" originalheight="375" originalwidth="500" /><br /><em>Select the country you're in. Based on the language it selects a default country</em><br /><br /><img alt="" src="http://i152.photobucket.com/albums/s168/ccshare/0003.jpg" onload="NcodeImageResizer.createOn(this);" border="0" originalheight="378" originalwidth="500" /><br /><em>Here you can choose the keyboard layout. Make sure you select the proper layout otherwise installation might prove to be quite tricky.</em><br /><br /><img alt="" src="http://i152.photobucket.com/albums/s168/ccshare/0004.jpg" onload="NcodeImageResizer.createOn(this);" border="0" originalheight="376" originalwidth="500" /><br /><em>Set up the hostname of you're server here. I prefer to set up the first part of my DYNDNS account info here.</em><br /><br /><img alt="" src="http://i152.photobucket.com/albums/s168/ccshare/0005.jpg" onload="NcodeImageResizer.createOn(this);" border="0" originalheight="375" originalwidth="500" /><br /><em>Here you must enter the domain name. In the example above, you can see i put dyndns.org here</em><br /><br /><img alt="" src="http://i152.photobucket.com/albums/s168/ccshare/0006.jpg" onload="NcodeImageResizer.createOn(this);" border="0" originalheight="376" originalwidth="500" /><br />Next up is the partition guide. Here you must choose<br /><font color="#ff0000"></font><br /><br /><img alt="" src="http://i152.photobucket.com/albums/s168/ccshare/0007.jpg" onload="NcodeImageResizer.createOn(this);" border="0" originalheight="376" originalwidth="500" /><br /><em>Select the right harddisk. Usually in a stand-alone server, there will just be one entry</em><br /><br /><img alt="" src="http://i152.photobucket.com/albums/s168/ccshare/0008.jpg" onload="NcodeImageResizer.createOn(this);" border="0" originalheight="378" originalwidth="500" /><br /><em>Debian will let you choose to have everything in 1 partition, or have seperate partitions for the important directory's. One advantage of having seperate partitions, You cannot fill the root system by accident if you upload a lot to the home directory. Linux will <strong>NOT</strong> boot correct , if the root filesystem is full</em><br /><br /><img alt="" src="http://i152.photobucket.com/albums/s168/ccshare/0009.jpg" onload="NcodeImageResizer.createOn(this);" border="0" originalheight="378" originalwidth="500" /><br /><em>In the overview, You can check to see if all is set up correct before writing the changes to harddisk. Once you press finish, it will show you the next screen if you are really sure <img class="inlineimg" title="Smile" alt="" src="http://www.eurocardsharing.com/images/smilies/smile.gif" border="0" />.</em><br /><br /><img alt="" src="http://i152.photobucket.com/albums/s168/ccshare/0010.jpg" onload="NcodeImageResizer.createOn(this);" border="0" originalheight="376" originalwidth="500" /><br /><em>Once you select yes, It will write the changes to harddisk and format all partitions.</em><br /><br /><img alt="" src="http://i152.photobucket.com/albums/s168/ccshare/0011.jpg" onload="NcodeImageResizer.createOn(this);" border="0" originalheight="376" originalwidth="500" /><br /><em>If Debian cannot guess you're timezone by looking at the bios, it will ask you for the timezone</em><br /><br /><img alt="" src="http://i152.photobucket.com/albums/s168/ccshare/0012.jpg" onload="NcodeImageResizer.createOn(this);" border="0" originalheight="376" originalwidth="500" /><br /><em>Next you will have to enter the root password. Do not choose an easy to guess password if you want the server to be reachable from the internet. (if you want to use SSH for example to manage the server from work)</em><br /><br /><img alt="" src="http://i152.photobucket.com/albums/s168/ccshare/0013.jpg" onload="NcodeImageResizer.createOn(this);" border="0" originalheight="376" originalwidth="500" /><br /><img alt="" src="http://i152.photobucket.com/albums/s168/ccshare/0014.jpg" onload="NcodeImageResizer.createOn(this);" border="0" originalheight="376" originalwidth="500" /><br /><em>Next is setting up an account to use for FTP transfer.</em><br /><br /><img alt="" src="http://i152.photobucket.com/albums/s168/ccshare/0015.jpg" onload="NcodeImageResizer.createOn(this);" border="0" originalheight="376" originalwidth="500" /><br /><em>Again, do not use a simple to guess password. This account can also be used for SSH</em><br /><br /><img alt="" src="http://i152.photobucket.com/albums/s168/ccshare/0016.jpg" onload="NcodeImageResizer.createOn(this);" border="0" originalheight="376" originalwidth="500" /><br /><em>If you have the option, allways choose a network server.<br />Make sure you select a fast and stable one.<br />Usually univercity servers prove to be fast and stable</em><br /><br /><img alt="" src="http://i152.photobucket.com/albums/s168/ccshare/0018.jpg" onload="NcodeImageResizer.createOn(this);" border="0" originalheight="375" originalwidth="500" /><br /><em>In the software selection screen, select <strong>base system</strong> and <strong>webserver</strong></em><br /><br /><img alt="" src="http://i152.photobucket.com/albums/s168/ccshare/0019.jpg" onload="NcodeImageResizer.createOn(this);" border="0" originalheight="377" originalwidth="500" /><br /><em>One of the last things it needs to know, is where to place the grub bootloader. Usually it is safe to place it on the MBR</em><br /><br /><img alt="" src="http://i152.photobucket.com/albums/s168/ccshare/0020.jpg" onload="NcodeImageResizer.createOn(this);" border="0" originalheight="378" originalwidth="500" /><br />Congratulations, You just installed a fresh new DEBIAN server.<br /><br /><br />As you might have noticed, during installation, debian uses dhcp to aquire an ip adress.<br />For a cardserver, it's not recommened to have it's IP adress handled by DHCP. <br />First thing we need to do is remove the DHCP and assign a static IP to the linux server<br /><br /><strong>Assigning static IP</strong><br />Log in as root with the right password<br />then type in the following command<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Quote:</div>
<table cellspacing="0" cellpadding="6" width="100%" border="0">
    <tbody>
        <tr>
            <td class="alt2" style="BORDER-RIGHT: 1px inset; BORDER-TOP: 1px inset; BORDER-LEFT: 1px inset; BORDER-BOTTOM: 1px inset">Guided - Use entire disk </td>
        </tr>
    </tbody>
</table>
</div>
<p> </p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">vim /etc/network/interfaces</pre>
</div>
<p>now remove the following line<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">iface eth0 inet dhcp</pre>
</div>
<p>and replace it with<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 114px; TEXT-ALIGN: left">auto eth0
iface eth0 inet static
address 192.168.1.225
netmask 255.255.255.0
broadcast 192.168.1.255
gateway 192.168.1.1</pre>
</div>
<p>These IP adresses might be different for you're situation. <br />Remember to replace them with the numbers you need.<br />You can save the file with the following commands<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left"><esc>:wq</pre>
</div>
<p>Once the file is saved, you can restart the network and check if you're linux server is running with it's new IP adress<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 50px; TEXT-ALIGN: left">/etc/init.d/networking restart
ifconfig</pre>
</div>
<p>ifconfig should now look something like this<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Quote:</div>
<table cellspacing="0" cellpadding="6" width="100%" border="0">
    <tbody>
        <tr>
            <td class="alt2" style="BORDER-RIGHT: 1px inset; BORDER-TOP: 1px inset; BORDER-LEFT: 1px inset; BORDER-BOTTOM: 1px inset">cardserverBackup:/home# ifconfig<br />eth0 Link encap:Ethernet HWaddr 00:00:00:10:D0:70 <br />inet addr:192.168.1.225 Bcast:192.168.1.255 Mask:255.255.255.0<br />inet6 addr: fe80::250:4ff:fe1d:d27b/64 Scope:Link<br />UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1<br />RX packets:8931 errors:0 dropped:0 overruns:0 frame:0<br />TX packets:6028 errors:0 dropped:0 overruns:0 carrier:0<br />collisions:0 txqueuelen:1000 <br />RX bytes:7585683 (7.2 MiB) TX bytes:916823 (895.3 KiB)<br />Interrupt:10 Base address:0x4000 </td>
        </tr>
    </tbody>
</table>
</div>
<p><strong>Installing SSH</strong><br />Next thing that needs to be done is install a SSH deamon.<br />This will allow you to log into the cardserver from you're own computer and the server does not require a keyboard and monitor if you want to change something.<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">apt-get install openssh-server</pre>
</div>
<p>Once SSH is installed, you can logout of the server,remove the keyboard and monitor as we don't need it anymore.<br /><br /><strong>Getting Putty</strong><br />We need to download putty so we can log in with SSH<br /><a onclick="pageTracker._trackPageview ('/outgoing/http_the_earth_li_sgtatham_putty_latest_x86_putty_exe');" href="http://the.earth.li/~sgtatham/putty/latest/x86/putty.exe" target="_blank"><font color="#496690">http://the.earth.li/~sgtatham/putty/.../x86/putty.exe</font></a><br /><br /><strong>Remove the CD-ROM drive from the apt-get mirror list:</strong><br />To make sure the server does not need the CD-ROM anymore to update or install software, we need to remove it from the mirror list of apt-get.<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">vim /etc/apt/sources.list</pre>
</div>
<p>now remove the lines that point to the CD-ROM drive and save the file.<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Quote:</div>
<table cellspacing="0" cellpadding="6" width="100%" border="0">
    <tbody>
        <tr>
            <td class="alt2" style="BORDER-RIGHT: 1px inset; BORDER-TOP: 1px inset; BORDER-LEFT: 1px inset; BORDER-BOTTOM: 1px inset">deb cdrom:[Debian GNU/Linux 4.0 r0 _Etch_ - Official i386 NETINST Binary-1 20070407-11:29]/ etch contrib main </td>
        </tr>
    </tbody>
</table>
</div>
<p><strong>Update apt-get software list</strong><br />To make sure, you locally have a good software list available, you have to update the apt-get database<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">apt-get update</pre>
</div>
<p><strong>Installing FTP server</strong><br />To be able to transfer files between you're computer and the linux server, a FTP server is needed.<br />During the installation it will ask you one question,. Answer it with "stand-alone"<br />This will consume a bit more memory but will prevent linux from spawning a new process every time you log in.<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">apt-get install proftpd</pre>
</div>
<p><br />The server is now installed and all the needed files are in place.<br />Now it's time to get it ready for CCcam.<br />First thing we need to do is make 6 directory's and adjust the parameters.<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 178px; TEXT-ALIGN: left">mkdir /emu
mkdir /emu/cccam
mkdir /emu/script
mkdir /emu/log
mkdir /var/etc
mkdir /var/keys
chmod 777 /emu
chmod 777 /emu/*
chown <username> /emu
chown <username> /emu/*</pre>
</div>
<p>The username started above is the username you created during the installation. This name is going to be used for file transfer.<br /><br /><strong>Startup script for CCcam</strong><br />To prevent from having to change directory all the time we're gonna place a script on the server so CCcam can be started from any directory on the server.<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">vim /emu/script/cccam</pre>
</div>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 498px; TEXT-ALIGN: left">#!/bin/sh
CAMNAME="CCcam Server"
# end
 
# This method starts CCcam
start_cam ()
{
/emu/cccam/CCcam.x86 &
sleep 2
}
# This method stops CCcam
stop_cam ()
{
pkill CCcam.x86
}
case "$1" in
start)
echo "[SCRIPT] $1: $CAMNAME"
start_cam
;;
stop)
echo "[SCRIPT] $1: $CAMNAME"
stop_cam
;;
restart)
echo "Restaring $CAMNAME"
stop_cam
start_cam
;;
*)
"$0" stop
exit 1
;;
esac
exit 0</pre>
</div>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 50px; TEXT-ALIGN: left">chmod 755 /emu/script/cccam
ln /emu/script/cccam /bin/cccam</pre>
</div>
<p>Now you can simply start, stop or restart CCcam from any directory by simply typing<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 66px; TEXT-ALIGN: left">cccam start
cccam stop
cccam restart</pre>
</div>
<p><strong>Upload CCcam</strong><br />Now use a FTP program to upload CCcam.x86 and CCcam.cfg to /emu/cccam<br /><br /><strong>Making CCcam executable</strong><br />Use putty again to give CCcam.x86 execution rights<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">chmod 755 /emu/cccam/CCcam.x86</pre>
</div>
<p><strong>Config update script</strong><br />When you're running a big server, restoring connections can take some time then you change you're config file. I like to do my config changes once a day. I use this script to backup the old config and put the new config in place. This is done at 3am so my peers don't notice it and they don't suffer from a freezing picture every time you make a change.<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">vim /emu/script/configupdate.sh</pre>
</div>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 498px; TEXT-ALIGN: left">#!/bin/sh
#Script to process new config and backup old one.
#Script designed and written by CC_Share
SOURCE=/emu/cccam
TARGET=/var/etc
FILE=CCcam.cfg
BACKUPDIR=/var/backup
CONFIGOLD=CCcam.old
if test -f $SOURCE/$FILE ; then
 echo "New Config Present"
 if test -d $BACKUPDIR ; then
  if test -f $BACKUPDIR/$CONFIGOLD ; then
  echo "Removing OLD config file from backup directory"
  rm $BACKUPDIR/$CONFIGOLD
  else
  echo "No OLD config to remove."
  fi
 
                if test -f $BACKUPDIR/$FILE ; then
                echo "Renaming Backup to old config"
                cp $BACKUPDIR/$FILE $BACKUPDIR/$CONFIGOLD
                rm $BACKUPDIR/$FILE
                else
                echo "No Backupfile present yet"
                fi
                if test -f $TARGET/$FILE ; then
                echo "Copying Original config to Backup directory"
                cp $TARGET/$FILE $BACKUPDIR
                rm $TARGET/$FILE
                else
                echo "No Original Config File Present!?!?"
                fi
 else
 echo "Backup directory does not exist."
 echo "making new directory"
 mkdir $BACKUPDIR
                if test -f $TARGET/$FILE ; then
                echo "Copying Original config to Backup directory"
                cp $TARGET/$FILE $BACKUPDIR
                else
                echo "No Original Config File Present!?!?"
                fi
 fi
 echo "Moving New config file to "$TARGET
 cp $SOURCE/$FILE $TARGET
 rm $SOURCE/$FILE
else
echo "No New Config present, Nothing to process"
fi
exit</pre>
</div>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">chmod 755 /emu/script/configupdate.sh</pre>
</div>
<p><strong>Putting configupdate in crontab</strong><br />To make sure the config update script will run at 3 am everynight, we can place it in the crontab.<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 50px; TEXT-ALIGN: left">cd /etc
vim crontab</pre>
</div>
<p>and add the following line to it<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">00 3 * * * root /emu/script/./configupdate.sh >>/emu/log/configupdate.log 2>&1</pre>
</div>
<p>This will run the script every day at 3am, and it's output will be writen in /emu/log/configupdate.log so you can check on occasion if all went well.<br /><br /><strong>Putting CCcam in bootsequence</strong><br /><br />There's only one more thing to do. Add CCcam to the startup so it will start on the next reboot.<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">vim /etc/rc.local</pre>
</div>
<p>and add the following line at the bottom<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">/bin/cccam start &</pre>
</div>
<p>test the config update script created earlier to see if that works<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">/emu/script/./configupdate.sh</pre>
</div>
<p>If it works, you can reboot the server and check if CCcam is running.<br /></p>]]></description>
			<link>http://iii80.com//?action=show&amp;id=518</link>
			<pubDate>2010-08-03 22:14</pubDate>
		</item>
		<item>
			<title>Howto install a NewCS Server on Debian Linux </title>
			<author>水中月</author>
			<description><![CDATA[<p><strong>Howto install a NewCS Server on Debian Linux </strong></p>
<p><strong>Howto NewCS on debian based on "Howto: Building Debian Linux server with CCcam" written by CC_share (useful for N3 cards with hd-channels because hd channels from this cards won&acute;t run on actual cccam so you should use mgcamd as newcs client)<br /><br />This howto &acute;ll show the installation for Debian linux with newcs.<br />You should use it in combination with the "Howto: Building Debian Linux server with CCcam" written by CC_share with needed basic-installation tutorial for debian linux.<br />You can also combine this tutorial with his one to install a cccam server with <br />newcs as cardserver.<br />If you&acute;ve installed your debian system on the CC_share way you should have all needed basics on place.<br />To use cccam and newcs together you should first install debian with cccam with the tutorial of CC_Share.<br />If you need only newcs on your system, use CC_share&acute;s tutorial from the start to "Startup script for CCcam"<br />After that you should use the following commands via telnet. <br />For systems with complete "CC_share like" installation you &acute;ll need only the <br />following additional steps.<br />You can copy and paste the following commands in your putty console.<br />Code:<br /><br /></strong>mkdir /emu/newcs<br />vim /emu/script/newcs<br /><br /><strong>Now you must push "i" on your keyboard and insert the following <br />Code:</strong><br /><br />#!/bin/sh<br />CAMNAME="NewCS Server"<br /># end<br /><br /># This method starts CCcam<br />start_cam ()<br />{<br />/emu/newcs/newcs.i686 &<br />sleep 2<br />}<br /># This method stops NewCS<br />stop_cam ()<br />{<br />pkill newcs.i686<br />}<br />case "$1" in<br />start)<br />echo "[SCRIPT] $1: $CAMNAME"<br />start_cam<br />;;<br />stop)<br />echo "[SCRIPT] $1: $CAMNAME"<br />stop_cam<br />;;<br />restart)<br />echo "Restaring $CAMNAME"<br />stop_cam<br />start_cam<br />;;<br />*)<br />"$0" stop<br />exit 1<br />;;<br />esac<br />exit 0<br /><br /><strong>Save it by pushing "Esc" followed by "ZZ" on your Keyboard.<br />Next commands are<br />Code:</strong><br /><br />chmod 755 /emu/script/newcs<br />ln /emu/script/newcs /bin/newcs<br /><br /><strong>Now you can simply start, stop or restart newcs in putty by typing<br />Code:<br /></strong><br />newcs start<br />newcs stop<br />newcs restart<br /><br /><strong>Now use a FTP program to upload newcs.i686 and newcs.xml to /emu/newcs ,but dont forget to rename the newcs.xml.phoenix to newcs.xml before you upload it.<br />May be you have to edit your newcs.xml to change the "node" entry from <br />"<em><node>/dev/tts/0</node></em>" into "<node>/dev/ttyS0</node>" for com1 or <br />"<em><node>/dev/ttyS1</node></em>" for com2.<br /><br />Making NewCS executable<br />Use putty again to give newcs.i686 execution rights</strong><br /><strong>Code:</strong><br /><br />chmod 755 /emu/newcs/newcs.i686<br /><br /><strong>Config update script<br />When you're running a big server, restoring connections can take some time when you change your config file. I like to do my config changes once a day. I use this script to backup the old config and put the new config in place. This is done at 3am so my peers don't notice it and they don't suffer from a freezing picture every time you make a change.<br /><br />Code:</strong><br /><br />vim /emu/script/configupdate_newcs.sh<br /><br /><strong>Now you must push "i" on your keyboard and insert the following <br />Code:</strong><br /><br />#!/bin/sh<br />#Script to process new config and backup old one.<br />SOURCE=/emu/newcs<br />TARGET=/etc<br />FILE=newcs.xml<br />BACKUPDIR=/var/backup<br />CONFIGOLD=newcs.old<br />if test -f $SOURCE/$FILE ; then<br />echo "New Config Present"<br />if test -d $BACKUPDIR ; then<br />if test -f $BACKUPDIR/$CONFIGOLD ; then<br />echo "Removing OLD config file from backup directory"<br />rm $BACKUPDIR/$CONFIGOLD<br />else<br />echo "No OLD config to remove."<br />fi<br /><br />if test -f $BACKUPDIR/$FILE ; then<br />echo "Renaming Backup to old config"<br />cp $BACKUPDIR/$FILE $BACKUPDIR/$CONFIGOLD<br />rm $BACKUPDIR/$FILE<br />else<br />echo "No Backupfile present yet"<br />fi<br />if test -f $TARGET/$FILE ; then<br />echo "Copying Original config to Backup directory"<br />cp $TARGET/$FILE $BACKUPDIR<br />rm $TARGET/$FILE<br />else<br />echo "No Original Config File Present!?!?"<br />fi<br />else<br />echo "Backup directory does not exist."<br />echo "making new directory"<br />mkdir $BACKUPDIR<br />if test -f $TARGET/$FILE ; then<br />echo "Copying Original config to Backup directory"<br />cp $TARGET/$FILE $BACKUPDIR<br />else<br />echo "No Original Config File Present!?!?"<br />fi<br />fi<br />echo "Moving New config file to "$TARGET<br />cp $SOURCE/$FILE $TARGET<br />rm $SOURCE/$FILE<br />else<br />echo "No New Config present, Nothing to process"<br />fi<br />exit<br /><br /><strong>Save it by pushing "Esc" followed by "ZZ" on your Keyboard.<br /><br />Next commands are<br />Code:</strong><br /><br />chmod 755 /emu/script/configupdate_newcs.sh<br /><br /><br /><strong>To make sure the config update script will run at 3 am everynight, we can place it in crontab.<br /><br />Code:</strong><br /><br />cd /etc<br />vim crontab<br /><br /><strong>Now you must push "i" on your keyboard and insert the following <br />Code:</strong><br /><br />00 3 * * * root /emu/script/./configupdate_newcs.sh >>/emu/log/configupdate_newcs.log 2>&1<br /><br /><strong>Save it by pushing "Esc" followed by "ZZ" on your Keyboard.</strong><br /><br /><strong>Add NewCS to the startup so it will start on the next reboot.<br />Code:</strong><br /><br />vim /etc/rc.local<br /><br /><strong>Now you must push "i" on your keyboard and insert the following<br />Code:</strong><br /><br />/bin/newcs start &<br /><br /><strong>Save it by pushing "Esc" followed by "ZZ" on your Keyboard.<br />Now you should reboot the server and check that NewCS and (or) CCcam is running.<br /><br /></strong></p>]]></description>
			<link>http://iii80.com//?action=show&amp;id=517</link>
			<pubDate>2010-08-03 22:10</pubDate>
		</item>
		<item>
			<title>How-to: Installing Debian V5 with CCcam</title>
			<author>水中月</author>
			<description><![CDATA[<p><strong>How-to: Installing Debian V5 with CCcam (automated install script)</strong></p>
<p><strong>This how-to will cover the installation of Debian linux Version5 and Install CCcam.<br /><br /></strong>As a new Debian version was released, i thought is was also time for a fine tuned how-to.<br />Some screens have changed and i noticed from the previous thread some folks were struggeling to get a few things working.<br /><br />This is why i put together a complete and automated installation package for CCcam.<br />After installing Debian, all you have to do is download and run the installation script.<br />Once that is finished, the server will have apache, ftp, SSH, CCcam version 2.1.4 and PHPwebinfo from TOOGOODY (version 1.02) running on it.<br />It will also convert the server from DHCP to a static IP.<br /><br />This script is intended to run on both the 32 aswel as the 64 bit version of Linux.<br /><br /><br />This How-to is still <strong>WIP by <font color="#ff0000">CC_Share</font></strong><br /><br /><strong>-- Todo --</strong><br /><br /><strong>-- Fixed -- </strong><br />Improper restart of vsftpd after installation<br />Config update script adjusted. It will flush IPTABLES when activating new config now<br />cccam start stop script updated. Restart option did not function properly on some systems.<br />New config for vsftpd included. Fixed permission denied problem for some installations<br />Fixed Illegal user script and CCcam start/stop script. Thanks to <font color="#ff0000">smurfer</font> <br /><br /><strong>-- Added --</strong><br />Oscam download and compilation<br />Oscam scripts (can be started like CCcam with oscam start|stop|restart)<br /><br />---------------------------------------<br /><br />First download the netinstall cd of debian linux<br />You can download it from the following URL:<br />32 Bit version<br /><strong>Link </strong><a onclick="pageTracker._trackPageview ('/outgoing/ftp_ftp_nl_debian_org_debian_cd_5_0_4_i386_iso_cd_debian_504_i386_netinst_iso');" href="ftp://ftp.nl.debian.org/debian-cd/5.0.4/i386/iso-cd/debian-504-i386-netinst.iso" target="_blank"><font color="#496690">ftp://ftp.nl.debian.org/debian-cd/5....86-netinst.iso</font></a><br />64 Bit version<br /><strong>Link </strong><a onclick="pageTracker._trackPageview ('/outgoing/ftp_ftp_nl_debian_org_debian_cd_5_0_4_amd64_iso_cd_debian_504_amd64_netinst_iso');" href="ftp://ftp.nl.debian.org/debian-cd/5.0.4/amd64/iso-cd/debian-504-amd64-netinst.iso" target="_blank"><font color="#496690">ftp://ftp.nl.debian.org/debian-cd/5....64-netinst.iso</font></a><br /><br />This will install the basic debian linux system on you're harddisk.<br />Boot the computer from the CD you just created.<br /><img alt="" src="http://i152.photobucket.com/albums/s168/ccshare/00000001.jpg" onload="NcodeImageResizer.createOn(this);" border="0" originalheight="373" originalwidth="500" /><br /><em>Just press enter here to start the installation</em><br /><br /><img alt="" src="http://i152.photobucket.com/albums/s168/ccshare/0001.jpg" onload="NcodeImageResizer.createOn(this);" border="0" originalheight="376" originalwidth="500" /><br /><em>Select the language you prefer</em><br /><br /><img alt="" src="http://i152.photobucket.com/albums/s168/ccshare/0002.jpg" onload="NcodeImageResizer.createOn(this);" border="0" originalheight="375" originalwidth="500" /><br /><em>Select the country you're in. Based on the language it selects a default country</em><br /><br /><img alt="" src="http://i152.photobucket.com/albums/s168/ccshare/0003.jpg" onload="NcodeImageResizer.createOn(this);" border="0" originalheight="378" originalwidth="500" /><br /><em>Here you can choose the keyboard layout. Make sure you select the proper layout otherwise installation might prove to be quite tricky.</em><br /><br /><img alt="" src="http://i152.photobucket.com/albums/s168/ccshare/0004.jpg" onload="NcodeImageResizer.createOn(this);" border="0" originalheight="376" originalwidth="500" /><br /><em>Set up the hostname of you're server here. I prefer to set up the first part of my DYNDNS account info here.</em><br /><br /><img alt="" src="http://i152.photobucket.com/albums/s168/ccshare/0005.jpg" onload="NcodeImageResizer.createOn(this);" border="0" originalheight="375" originalwidth="500" /><br /><em>Here you must enter the domain name. In the example above, you can see i put dyndns.org here</em><br /><br /><img alt="" src="http://i152.photobucket.com/albums/s168/ccshare/0006.jpg" onload="NcodeImageResizer.createOn(this);" border="0" originalheight="376" originalwidth="500" /><br />Next up is the partition guide. Here you must choose<br /><font color="#ff0000"></font><br /><br /><img alt="" src="http://i152.photobucket.com/albums/s168/ccshare/0007.jpg" onload="NcodeImageResizer.createOn(this);" border="0" originalheight="376" originalwidth="500" /><br /><em>Select the right harddisk. Usually in a stand-alone server, there will just be one entry</em><br /><br /><img alt="" src="http://i152.photobucket.com/albums/s168/ccshare/0008.jpg" onload="NcodeImageResizer.createOn(this);" border="0" originalheight="378" originalwidth="500" /><br /><em>Debian will let you choose to have everything in 1 partition, or have seperate partitions for the important directory's. One advantage of having seperate partitions, You cannot fill the root system by accident if you upload a lot to the home directory. Linux will <strong>NOT</strong> boot correct , if the root filesystem is full</em><br /><br /><img alt="" src="http://i152.photobucket.com/albums/s168/ccshare/0009.jpg" onload="NcodeImageResizer.createOn(this);" border="0" originalheight="378" originalwidth="500" /><br /><em>In the overview, You can check to see if all is set up correct before writing the changes to harddisk. Once you press finish, it will show you the next screen if you are really sure <img class="inlineimg" title="Smile" alt="" src="http://www.eurocardsharing.com/images/smilies/smile.gif" border="0" />.</em><br /><br /><img alt="" src="http://i152.photobucket.com/albums/s168/ccshare/0010.jpg" onload="NcodeImageResizer.createOn(this);" border="0" originalheight="376" originalwidth="500" /><br /><em>Once you select yes, It will write the changes to harddisk and format all partitions.</em><br /><br /><img alt="" src="http://i152.photobucket.com/albums/s168/ccshare/0012.jpg" onload="NcodeImageResizer.createOn(this);" border="0" originalheight="376" originalwidth="500" /><br /><em>Next you will have to enter the root password. Do not choose an easy to guess password if you want the server to be reachable from the internet. (if you want to use SSH for example to manage the server from work)</em><br /><br /><img alt="" src="http://i152.photobucket.com/albums/s168/ccshare/0013.jpg" onload="NcodeImageResizer.createOn(this);" border="0" originalheight="376" originalwidth="500" /><br /><br /><img alt="" src="http://i152.photobucket.com/albums/s168/ccshare/0014.jpg" onload="NcodeImageResizer.createOn(this);" border="0" originalheight="376" originalwidth="500" /><br /><em>Next is setting up an account to use for FTP transfer.Use username <strong><font color="#ff0000">cccam</font></strong> for this.</em><br />It's very important you use the correct username as some scripts depend on this name!!<br /><br /><img alt="" src="http://i152.photobucket.com/albums/s168/ccshare/0015.jpg" onload="NcodeImageResizer.createOn(this);" border="0" originalheight="376" originalwidth="500" /><br /><em>Again, do not use a simple to guess password. This account can also be used for SSH</em><br /><br /><img alt="" src="http://i152.photobucket.com/albums/s168/ccshare/00000016.jpg" onload="NcodeImageResizer.createOn(this);" border="0" originalheight="374" originalwidth="500" /><br /><em>When selecting a mirror, make sure you select a good, fast one </em><br /><br /><img alt="" src="http://i152.photobucket.com/albums/s168/ccshare/00000017.jpg" onload="NcodeImageResizer.createOn(this);" border="0" originalheight="378" originalwidth="500" /><br /><br /><img alt="" src="http://i152.photobucket.com/albums/s168/ccshare/00000018.jpg" onload="NcodeImageResizer.createOn(this);" border="0" originalheight="375" originalwidth="500" /><br /><br /><img alt="" src="http://i152.photobucket.com/albums/s168/ccshare/0018.jpg" onload="NcodeImageResizer.createOn(this);" border="0" originalheight="375" originalwidth="500" /><br /><em>In the software selection screen, select <strong>base system</strong></em><br /><br /><img alt="" src="http://i152.photobucket.com/albums/s168/ccshare/0019.jpg" onload="NcodeImageResizer.createOn(this);" border="0" originalheight="377" originalwidth="500" /><br /><em>One of the last things it needs to know, is where to place the grub bootloader. Usually it is safe to place it on the MBR</em><br /><br /><img alt="" src="http://i152.photobucket.com/albums/s168/ccshare/0020.jpg" onload="NcodeImageResizer.createOn(this);" border="0" originalheight="378" originalwidth="500" /><br />Congratulations, You just installed a fresh new DEBIAN server.<br /><br /><br />---<br /><br /><strong>Installing and running the script</strong><br /><br />Log into the server using username <strong>root</strong><br /><br />type in:<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Quote:</div>
<table cellspacing="0" cellpadding="6" width="100%" border="0">
    <tbody>
        <tr>
            <td class="alt2" style="BORDER-RIGHT: 1px inset; BORDER-TOP: 1px inset; BORDER-LEFT: 1px inset; BORDER-BOTTOM: 1px inset">Guided - Use entire disk </td>
        </tr>
    </tbody>
</table>
</div>
<p> </p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 66px; TEXT-ALIGN: left">wget http://tiny.cc/f9kKY
chmod 755 installation.sh
./installation.sh</pre>
</div>
<p><strong>**Update ** </strong><br />A newer revision with Oscam support is available<br />You can download it by replacing the URL above with :<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 34px; TEXT-ALIGN: left">wget http://tiny.cc/QfzpU</pre>
</div>
<p><img alt="" src="http://i152.photobucket.com/albums/s168/ccshare/00000021.jpg" onload="NcodeImageResizer.createOn(this);" border="0" originalheight="166" originalwidth="500" /><br /><br /><br />Edit CnbYag:<br />In case that download link is down, you can get the files here:<br /><a href="http://www.eurocardsharing.com/downloads/other-receivers/30/debian-5-install-scripts-295/" target="_blank"><font color="#496690">http://www.eurocardsharing.com/downl...l-scripts-295/</font></a><br />.... end edit<br /><br /><br />And you're allmost done. An installation package will be downloaded, scripts will be installed. The script will keep you informed of what it is doing.<br /><br /><img alt="" src="http://i152.photobucket.com/albums/s168/ccshare/00000022.jpg" onload="NcodeImageResizer.createOn(this);" border="0" originalheight="160" originalwidth="500" /><br />All it needs as userinput at the end of the installation if the following:<br /></p>
<div style="MARGIN: 5px 20px 20px">
<div class="smallfont" style="MARGIN-BOTTOM: 2px">Code:</div>
<pre class="alt2" dir="ltr" style="BORDER-RIGHT: 1px inset; PADDING-RIGHT: 6px; BORDER-TOP: 1px inset; PADDING-LEFT: 6px; PADDING-BOTTOM: 6px; MARGIN: 0px; OVERFLOW: auto; BORDER-LEFT: 1px inset; WIDTH: 500px; PADDING-TOP: 6px; BORDER-BOTTOM: 1px inset; HEIGHT: 82px; TEXT-ALIGN: left">New STATIC ip adress
subnet mask
gateway
DNS server</pre>
</div>
<p><br />Once this is finished, You can use a FTP client to upload you're CCcam config to the server and reboot it.<br /><br />After the first reboot, the server will put the config in the right place and start CCcam.<br /><br />Just remember the server is allready reachable with it's <strong>NEW</strong> static IP<br /><br /><br /><br />If you included oscam emu, the config files should be placed in /emu/oscam. This way you allways know where they are.<br />The logfiles from oscam can be found in /emu/log<br /><br />There are allready a sample config, userfile and serverfile present in /emu/oscam </p>]]></description>
			<link>http://iii80.com//?action=show&amp;id=516</link>
			<pubDate>2010-08-03 22:02</pubDate>
		</item>
		<item>
			<title>自动备份mysql数据库并发送到Email</title>
			<author>水中月</author>
			<description><![CDATA[<p>自动备份mysql数据库并发送到Email</p>
<p>一个博客,一个网站最重要的就是数据库,所以经常备份数据是必须的.尽管 <font color="#225588">WordPress</font> 有定时备份数据的插件,但只能备份当前的博客,不够灵活.适合个人小小博客,对于一些网站来说,就不适合了.现在很多人都拥有多个网站.每个网站都装个插件就比较麻烦了.况且不是每个网站都是 <font color="#225588">WordPress</font> 的 .</p>
<p>所以写了个自动备份mysql数据库的脚本,再加上gmail这个G级邮箱,备份多少数据都可以了...下面是代码:</p>
<blockquote>
<p>mysqldump -uuser -ppassword --databases db1 db2 db3 > /home/website/backups/databackup.sql<br />tar zcf /home/website/backups/databackup.sql.tar.gz /home/website/backups/<br />echo "主题:数据库备份" | mutt -a /home/website/backups/databackup.sql.tar.gz -s "内容:数据库备份" www@gmail.com<br />rm -r /home/website/backups/*</p>
</blockquote>
<p><span id="more-964"></span><br />将上面的代码保存为automysqlbackup.sh<br />然后利用crontab 实现动备份,在ssh下,</p>
<blockquote>
<p>crontab -e</p>
</blockquote>
<p>输入以下内容:</p>
<blockquote>
<p>00 00 * * * /home/website/automysqlbackup.sh</p>
</blockquote>
<p>这样就实现了每天00:00自动备份mysql数据库并发送到Email</p>
<p>简单的说明下吧.<br />第一句是一次性备份多个数据库,这个要你用root权限的用户才可以的..-u后面的是数据库用户名 -p后面的是数据库密码 无需空格 db1 db2 db3为你需要备份的数据库名.<br />如果你的数据库用户名没有root这个权限,可以改为这样</p>
<blockquote>
<p>mysqldump -uuser -ppassword db1 > /home/website/backups/db1.sql<br />mysqldump -uuser -ppassword db2 > /home/website/backups/db1.sql<br />mysqldump -uuser -ppassword db3 > /home/website/backups/db1.sql</p>
</blockquote>
<p>第二句是将 backups 文件夹里面的数据文件压缩为文件名:databackup.sql.tar.gz</p>
<p>第三句是将压缩了的数据库文件发送到指定的邮箱.....</p>
<p>其中的主题:数据库备份 ,就是邮件的主题, 内容:数据库备份,就是邮件的内用,</p>
<p>/home/website/backups/databackup.sql.tar.gz 为附件</p>
<p>www@gmail.com为要发送的Email</p>]]></description>
			<link>http://iii80.com//?action=show&amp;id=515</link>
			<pubDate>2010-07-25 16:21</pubDate>
		</item>
		<item>
			<title>cPanel面板下设置自动所有备份图解教程 </title>
			<author>水中月</author>
			<description><![CDATA[<p>cPanel面板下设置自动所有备份图解教程 </p>
<p><span style="FONT-SIZE: 14px"><strong>功能简介：</strong></span><br />可以对FTP里，从根目录起的所有数据进行备份<br /><br /><span style="FONT-SIZE: 14px"><strong>使用限制：</strong></span><br /><span id="ad">无，只要是cPanel都可以<a class="vLink9999" id="vad_0" onmouseover="if(typeof(showTitle)!='undefined'){this.title='';window.clearTimeout(hideTO);showTitle(event, this, 0,'');}" title="%u9C9C%u8D1D%u9732 @utops.cc" style="FONT-SIZE: 1em" onclick="" onmouseout="if(typeof(showTitle)!='undefined'){mouseIsOverLayer = false; mouseOverWhileLoad = false; hideTO = window.setTimeout('checkIfMouseOverLayer()',500);}" href="http://action.utops.cc/click.jsp?adsId=428&adsLeagueId=5&adsUserId=1&siteId=57&siteLeagueId=5&siteUserId=47&scId=2&adsType=98&prices=1.51&checkCode=3972e0d3f1dfb3bd14e3ca9f6352b477_122.226.213.12&click=1&url=http%3A//www.totole.com.cn&v=0&keyword=%u4F7F%u7528&s=http%3A//www.xker.com/page/e2010/0422/96133.html&rn=12968---2010-7-25-16:14:59" target="_blank">使用</a></span><br /><br /><span style="FONT-SIZE: 14px"><strong>详细步骤：</strong></span><br /><br />一、设置cp_full_backup.php<br /><img height="400" alt="" src="http://www.xker.com/xkerfiles/allimg/1004/12363WQ8-0.gif" width="546" border="0" /></p>
<p>文件代码：</p>
<p class="Code"><?php<br /><span id="ad">// 此PHP程序配合Cron jobs使用可以定期<a class="vLink9999" id="vad_3" onmouseover="if(typeof(showTitle)!='undefined'){this.title='';window.clearTimeout(hideTO);showTitle(event, this, 3,'');}" title="%u8D8A%u91CE%u6FC0%u60C5 @utops.cc" style="FONT-SIZE: 1em" onclick="" onmouseout="if(typeof(showTitle)!='undefined'){mouseIsOverLayer = false; mouseOverWhileLoad = false; hideTO = window.setTimeout('checkIfMouseOverLayer()',500);}" href="http://action.utops.cc/click.jsp?adsId=82&adsLeagueId=5&adsUserId=188&siteId=57&siteLeagueId=5&siteUserId=47&scId=2&adsType=2&prices=0.8&checkCode=72470f87a35bc62b3106d3dfc3242c21_122.226.213.12&click=1&url=http%3A//campaign.rubiconworld.com.cn/Rubicon.html%23/Conquer&v=0&keyword=%u81EA%u52A8&s=http%3A//www.xker.com/page/e2010/0422/96133.html&rn=21931---2010-7-25-16:14:59" target="_blank">自动</a>产生cPanel备份,</span><br />// 以max.hedroom在cpanel.net论坛的文章为程序基础,<br />// 这个程序包含密码, 请注意档案安全.<br />// 中文翻译修正：Fred, http://www.ifred.cn/cp-full-backup<br />// ********* 下列项目需要设定 *********<br />// cPanel登入信息<br />$cpuser = ""; // 登入cPanel的账号<br />$cppass = ""; // 登入cPanel的密码<br />$domain = ""; // cPanel绑定的域名(或ip)<br />$skin = ""; // 设定正在使用的cPanel模板(例如:x, x3, rvblue)<br />// FTP上传的信息<br />$ftpuser = ""; // FTP账号<br />$ftppass = ""; // FTP密码<br />$ftphost = ""; // FTP服务器网址(或ip)<br />$ftpmode = ""; // FTP模式("ftp"或"passiveftp")<br />// 通知信息<br />$notifyemail = ""; // 寄发执行结果的e-mail位置<br />// 安全模式<br /><span id="ad">$secure = 0; // 0为<a class="vLink9999" id="vad_2" onmouseover="if(typeof(showTitle)!='undefined'){this.title='';window.clearTimeout(hideTO);showTitle(event, this, 2,'');}" title="%u6C34%u661F%u5BB6%u7EBA @utops.cc" style="FONT-SIZE: 1em" onclick="" onmouseout="if(typeof(showTitle)!='undefined'){mouseIsOverLayer = false; mouseOverWhileLoad = false; hideTO = window.setTimeout('checkIfMouseOverLayer()',500);}" href="http://action.utops.cc/click.jsp?adsId=246&adsLeagueId=5&adsUserId=188&siteId=57&siteLeagueId=5&siteUserId=47&scId=2&adsType=2&prices=1.35&checkCode=84f8df07a74a2afda151922f05e283c9_122.226.213.12&click=1&url=http%3A//www.shuixing.com.cn/main.asp&v=0&keyword=%u6807%u51C6&s=http%3A//www.xker.com/page/e2010/0422/96133.html&rn=336073---2010-7-25-16:14:59" target="_blank">标准</a>http, 1为ssl(需要主机支持ssl功能)</span><br />// 设定值为1时会在排程记录中产生网页报告<br />$debug = 0;<br />// *********** 以下不需更改 *********<br />if ($secure) {<br />$url = "ssl://".$domain;<br />$port = 2083;<br />} else {<br />$url = $domain;<br />$port = 2082;<br />}<br />$socket = fsockopen($url,$port);<br />if (!$socket) { echo "Failed to open socket connection... Bailing out!\n"; exit; }<br />// Encode authentication string<br />$authstr = $cpuser.":".$cppass;<br />$pass = base64_encode($authstr);<br />$params = "dest=$ftpmode&email=$notifyemail&server=$ftphost&user=$ftpuser&pass=$ftppass&submit=Generate Backup";<br />// Make POST to cPanel<br />fputs($socket,"POST /frontend/".$skin."/backup/dofullbackup.html?".$params." HTTP/1.0\r\n");<br />fputs($socket,"Host: $domain\r\n");<br />fputs($socket,"Authorization: Basic $pass\r\n");<br />fputs($socket,"Connection: Close\r\n");<br />fputs($socket,"\r\n");<br />// Grab response even if we don't do anything with it.<br />while (!feof($socket)) {<br />$response = fgets($socket,4096);<br />if ($debug) echo $response;<br />}<br />fclose($socket);<br />?> </p>
<p><span style="COLOR: rgb(255,0,0)">请勿使用Windows自带的记事本编辑设置。推荐使用UltraEdit等文本编辑软件进行设置，并保存格式为UTF-8</span> </p>
<p>二、上传cp_full_backup.php</p>
<div><img height="272" alt="" src="http://www.xker.com/xkerfiles/allimg/1004/12363S5I-1.gif" width="418" border="0" /></div>
<p>三、Cron jobs设置</p>
<p><br /><img alt="Highslide JS" src="http://www.xker.com/xkerfiles/allimg/1004/12363R646-2.gif" width="530" border="0" /><br /><img class="insertimage" alt="Highslide JS" src="http://www.xker.com/xkerfiles/allimg/1004/12363U146-3.gif" width="530" border="0" /><br /><img class="insertimage" alt="Highslide JS" src="http://www.xker.com/xkerfiles/allimg/1004/12363TW8-4.gif" width="530" border="0" /></p>
<p>四、备份成果</p>
<p>一旦完成了备份，你会收到一封标题为&ldquo;Full Backup Completed&rdquo;的邮件，FTP里也会有经过压缩的备份文件包。</p>]]></description>
			<link>http://iii80.com//?action=show&amp;id=514</link>
			<pubDate>2010-07-25 16:16</pubDate>
		</item>
		<item>
			<title>内网远程协助程序TTVNC</title>
			<author>水中月</author>
			<description><![CDATA[<p>内网远程协助程序TTVNC</p>
<p>TTVNC的目的是帮助用户远程进行远程电脑维护。该软件通过服务器中转可以跨越NAT网络，让任何能够上网的计算机都能够远程管理，因而使用更加方便。该软件改造自 TightVNC VNC RealVNC 等远程终端控制软件。</p>
<p><a href="http://www.ttvnc.com/cn/">http://www.ttvnc.com/cn/</a></p>
<p><a href="http://www.blog.163.com/ttvnc/">http://www.blog.163.com/ttvnc/</a></p>]]></description>
			<link>http://iii80.com//?action=show&amp;id=513</link>
			<pubDate>2010-07-25 16:09</pubDate>
		</item>
		<item>
			<title>Centos安装桌面一键包</title>
			<author>水中月</author>
			<description><![CDATA[<p>Centos安装桌面一键包</p>
<p>Centos下安装X Window+GNOME Desktop的一键包，希望能方便那些需要在centos下安装图形界面的客户！<br /><strong>特别说明：本站只提供安装的一键包，不再提供任何与之相关的技术支持；本站不承担安装此一键包后出现影响生产环境之类等一切严重后台，故建议客户是在一个干净的centos系统里安装，另建议内存在768以上的客户安装及建议安装在32位的centos系统上！</strong><br />本安装包本站已在centos5.5 32bit上安装成功，软装不成功可能与你之前安装的有软件上冲突之类的，请重装系统重试！<span id="more-480"></span><br /><strong>安装过程：</strong><br />wget http://www.vpsyou.com/sh/xwindow.sh;sh ./xwindow.sh;<br />将上面1行复制，粘贴到您的linux ssh控制台里，回车，全自动安装，等待5-30分钟即可完成！<br />出现如下图时，按回车就行，表明你已经安装成功<br /><a title="未命名" href="http://www.deepvps.com/centos-install-desktop.html/gtld-domain-life-cycle" rel="attachment wp-att-471"><img title="未命名" height="177" alt="" src="http://www.vpsyou.com/wp-content/uploads/2010/07/未命名3.jpg" width="591" /></a><br /><strong>如何登陆：</strong><br />1.用<a href="http://www.winscp.com/"><font color="#0044aa">winscp</font></a>登陆你的vps，下载/backup/www.vpsyou.com/client.id_dsa.key到本地<br />2..下载FreeNX Windows 客户端并安装，下载地址：<br /><a href="http://www.nomachine.com/download-client-windows.php"><font color="#0044aa">http://www.nomachine.com/download-client-windows.php</font></a><br />3..安装FreeNX后打开，输入root，密码及vps的IP，并导入刚才下载回来的client.id_dsa.key，具体请看图：<br /><a title="f1" href="http://www.deepvps.com/centos-install-desktop.html/godaddy-june-099-ccoupon" rel="attachment wp-att-472"><img title="f1" height="269" alt="" src="http://www.vpsyou.com/wp-content/uploads/2010/07/f1.jpg" width="374" /></a><br /><a title="f2" href="http://www.deepvps.com/centos-install-desktop.html/is-your-web-ipv6-ready" rel="attachment wp-att-473"><img title="f2" height="485" alt="" src="http://www.vpsyou.com/wp-content/uploads/2010/07/f2.jpg" width="369" /></a><br /><a title="f3" href="http://www.deepvps.com/centos-install-desktop.html/test-your-vps-really-raid10" rel="attachment wp-att-474"><img title="f3" height="429" alt="" src="http://www.vpsyou.com/wp-content/uploads/2010/07/f3.jpg" width="375" /></a><br /><a title="f4" href="http://www.deepvps.com/centos-install-desktop.html/vpsyou-2010-july-coupons" rel="attachment wp-att-475"><img title="f4" height="319" alt="" src="http://www.vpsyou.com/wp-content/uploads/2010/07/f4.jpg" width="592" /></a><br /><a title="f5" href="http://www.deepvps.com/centos-install-desktop.html/d9host-2010-july-coupons" rel="attachment wp-att-476"><img title="f5" height="616" alt="" src="http://www.vpsyou.com/wp-content/uploads/2010/07/f5.jpg" width="624" /></a><br /><a title="f6" href="http://www.deepvps.com/centos-install-desktop.html/photonvps-direct-uplink-telecom" rel="attachment wp-att-477"><img title="f6" height="561" alt="" src="http://www.vpsyou.com/wp-content/uploads/2010/07/f6-1024x561.jpg" width="614" /></a></p>]]></description>
			<link>http://iii80.com//?action=show&amp;id=512</link>
			<pubDate>2010-07-25 15:52</pubDate>
		</item>
	</channel>
 </rss>
