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

<channel>
	<title>生信菜鸟团 &#187; 服务器</title>
	<atom:link href="http://www.bio-info-trainee.com/tag/%e6%9c%8d%e5%8a%a1%e5%99%a8/feed" rel="self" type="application/rss+xml" />
	<link>http://www.bio-info-trainee.com</link>
	<description>欢迎去论坛biotrainee.com留言参与讨论，或者关注同名微信公众号biotrainee</description>
	<lastBuildDate>Sat, 28 Jun 2025 14:30:13 +0000</lastBuildDate>
	<language>zh-CN</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>https://wordpress.org/?v=4.1.33</generator>
	<item>
		<title>linux服务器管理&#8211;防火墙设置命令iptables</title>
		<link>http://www.bio-info-trainee.com/1688.html</link>
		<comments>http://www.bio-info-trainee.com/1688.html#comments</comments>
		<pubDate>Sat, 04 Jun 2016 01:32:07 +0000</pubDate>
		<dc:creator><![CDATA[ulwvfje]]></dc:creator>
				<category><![CDATA[linux]]></category>
		<category><![CDATA[生信基础]]></category>
		<category><![CDATA[iptables]]></category>
		<category><![CDATA[服务器]]></category>
		<category><![CDATA[端口]]></category>
		<category><![CDATA[防火墙]]></category>

		<guid isPermaLink="false">http://www.bio-info-trainee.com/?p=1688</guid>
		<description><![CDATA[如果我们想新开一个端口给别人访问，我们就需要设置防火墙，比如我想开3838端口给 &#8230; <a href="http://www.bio-info-trainee.com/1688.html">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
				<content:encoded><![CDATA[<div>
<div>如果我们想新开一个端口给别人访问，我们就需要设置防火墙，<strong>比如我想开3838端口给shiny程序使用</strong>，下面我重点讲解这个实例，其余开放端口，关闭端口大家继续学习就好。</div>
<div>如果你使用的是ssh远程，而又不能直接操作本机，<span style="color: #ff00ff;"><strong>那么建议你慎重，慎重，再慎重！（一旦你把22端口给搞死了，你就无法登陆你的服务器了！！！）</strong></span></div>
<div><span id="more-1688"></span></div>
<div>通过iptables我们可以为我们的Linux服务器配置有动态的防火墙，能够指定并记住为发送或接收信息包所建立的连接的状态，是一套用来设置、维护和检查Linux内核的IP包过滤规则的命令包。</div>
<div>首先配置好防火墙 <b>sudo vim<span style="color: #ff0000;"> /etc/sysconfig/iptables </span></b>让该端口可以被访问</div>
<div><a href="http://www.bio-info-trainee.com/wp-content/uploads/2016/06/3.png"><img class="alignnone size-full wp-image-1680" src="http://www.bio-info-trainee.com/wp-content/uploads/2016/06/3.png" alt="3" width="593" height="264" /></a></div>
<div>然后进去修改即可，上面红圈出来的那句话就是我添加的，意思是开放3838端口给用户使用。</div>
<div>修改之后并不是防火墙规则马上生效，还需要一个步骤，我搜索了一些资料，里面是这样讲的，我发现它的教程太旧了</div>
<blockquote>
<div>这里很多人会想到/etc/rc.d/init.d/iptables save指令</div>
<div>但是一旦你这么干了你刚才的修改内容就白做了。。。</div>
<div>只修改/etc/sysconfig/iptables 使其生效的办法是修改好后先service iptables restart</div>
<div>然后才调用/etc/rc.d/init.d/iptables save</div>
<div>因为/etc/rc.d/init.d/iptables save会在iptables服务启动时重新加载，要是在重启之前直接先调用了/etc/rc.d/init.d/iptables save那么你的/etc/sysconfig/iptables 配置就回滚到上次启动服务的配置了，这点必须注意！！！</div>
</blockquote>
<p>因为我是新的系统（RedHat 7, Ubuntu 15.04+, SLES 12+) ，结合我对该教程的理解。所以我用的是</p>
</div>
<p>&nbsp;</p>
<div>sudo systemctl restart iptables  命令，果然，马上3838端口就可以被访问了，我的shiny程序也可以完整的使用啦。</div>
<div>再简单解释一下刚才修改的<strong>防火墙配置文件</strong><b><span style="color: #ff0000;"> /etc/sysconfig/iptables</span></b> 的那句话的意义：</div>
<blockquote>
<div>
<ol>
<li>-A：指定链名</li>
<li>-p：指定协议类型</li>
<li>-d：指定目标地址</li>
<li>--dport：指定目标端口（destination port 目的端口）</li>
<li>--sport：指定源端口（source port 源端口）</li>
<li>-j：指定动作类型</li>
</ol>
</div>
</blockquote>
<div>我还查了好多其它资料，开始好像暂时用不着，就先不学习了，但是那些资料大多太陈旧了，请睁大你的慧眼，消化了它人的指导，再来自己运行。</div>
<div></div>
<div></div>
<div></div>
<div>
<div>也可以不去打开那个文件进行修改，而且命令行形式一条条记录的添加</div>
<div>
<blockquote>
<div>
<ol>
<li>例如我给SSH加放行的语句：</li>
<li>添加input记录： iptables -A INPUT -p tcp --dport <span style="color: #c00000;">22</span> -j ACCEPT</li>
<li>添加output记录： iptables -A OUTPUT -p tcp --sport <span style="color: #c00000;">22</span> -j ACCEPT</li>
<li>最后注意需要再执行一下 /etc/init.d/iptables save，这样这两条语句就保存到刚才那个/etc/sysconfig/iptables 文件中了。</li>
</ol>
</div>
</blockquote>
</div>
<div></div>
<div></div>
<div>删除端口就非常简单了：</div>
<div>可能有时候需要删除规则，最简单就是修改一下/etc/sysconfig/iptables然后service iptables restart,最后/etc/rc.d/init.d/iptables save即可。</div>
<div></div>
<div>还可以彻底禁止某IP访问:</div>
<div>
<ol>
<li>#屏蔽单个IP的命令是</li>
<li>iptables -I INPUT -s 123.45.6.7 -j DROP</li>
<li>#封整个段即从123.0.0.1到123.255.255.254的命令</li>
<li>iptables -I INPUT -s 123.0.0.0/8 -j DROP</li>
<li>#封IP段即从123.45.0.1到123.45.255.254的命令</li>
<li>iptables -I INPUT -s 124.45.0.0/16 -j DROP</li>
<li>#封IP段即从123.45.6.1到123.45.6.254的命令是</li>
<li>iptables -I INPUT -s 123.45.6.0/24 -j DROP</li>
<li>指令I是insert指令 但是该指令会insert在正确位置并不像A指令看你自己的排序位置，因此用屏蔽因为必须在一开始就要加 载屏蔽IP，所以必须使用I命令加载，然后注意执行/etc/rc.d/init.d/iptables save进行保存后重启服务即可</li>
</ol>
</div>
<div></div>
<div>在linux关闭防火墙可以这样：<br />
1. 重启系统生效<br />
开启： chkconfig iptables on<br />
关闭： chkconfig iptables off2. 即时生效，重启后失效<br />
开启： service iptables start<br />
关闭： service iptables stop</div>
</div>
<div></div>
<div></div>
]]></content:encoded>
			<wfw:commentRss>http://www.bio-info-trainee.com/1688.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>linux服务器管理&#8211;系统服务设置命令systemctl</title>
		<link>http://www.bio-info-trainee.com/1685.html</link>
		<comments>http://www.bio-info-trainee.com/1685.html#comments</comments>
		<pubDate>Sat, 04 Jun 2016 01:22:48 +0000</pubDate>
		<dc:creator><![CDATA[ulwvfje]]></dc:creator>
				<category><![CDATA[linux]]></category>
		<category><![CDATA[生信基础]]></category>
		<category><![CDATA[chkconfig]]></category>
		<category><![CDATA[service]]></category>
		<category><![CDATA[systemctl]]></category>
		<category><![CDATA[服务器]]></category>

		<guid isPermaLink="false">http://www.bio-info-trainee.com/?p=1685</guid>
		<description><![CDATA[因为买过一个超算云服务器，所以前面我讲过Ubuntu服务器管理系列知识，正好最近 &#8230; <a href="http://www.bio-info-trainee.com/1685.html">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
				<content:encoded><![CDATA[<p>因为买过一个超算云服务器，所以前面我讲过<a href="http://www.bio-info-trainee.com/577.html">Ubuntu服务器管理系列知识</a>，正好最近要搞了个阿里云，用来做shiny服务器，发现服务器管理居然进化了好多，以前的知识都过时了，再记录一笔吧，真的是学习如逆水行舟，不进则退呀！</p>
<p>我的阿里云服务器版本是CentOS 6.5.，属于（RedHat 7, Ubuntu 15.04+, SLES 12+)  系列，是目前最新版本的服务器管理，所以大家重点是记住这个<span style="color: #ff00ff;"><strong>systemctl </strong></span>即可：</p>
<p><span id="more-1685"></span></p>
<blockquote>
<div>例子如下：</div>
</blockquote>
<div>
<blockquote>
<div><span style="color: #ff00ff;"><strong>sudo systemctl start shiny-server</strong></span></div>
<div><span style="color: #ff00ff;"><strong>sudo systemctl stop shiny-server</strong></span></div>
<div><span style="color: #ff00ff;"><strong>sudo systemctl restart shiny-server</strong></span></div>
</blockquote>
<div>
<blockquote>
<div>如果是稍微有点旧的(Ubuntu 12.04 through 14.10 and RedHat 6)</div>
<div>例子如下：</div>
<div>
<ul>
<li><span style="color: #ff00ff;"><strong>启动指令:sudo service iptables start   </strong></span></li>
<li><span style="color: #ff00ff;"><strong>重启指令:sudo service iptables restart   </strong></span></li>
<li><span style="color: #ff00ff;"><strong>关闭指令:sudo service iptables stop   </strong></span></li>
</ul>
</div>
<div>如果是特别老的linux服务器，如(RedHat 5, SLES 11) ，系统太老了，关键文件存放在<code>/etc/init.d/</code></div>
<div>sudo /sbin/service shiny-server start</div>
<div>sudo /sbin/service shiny-server stop</div>
<div>sudo /sbin/service shiny-server restart</div>
<div>sudo /sbin/service shiny-server reload</div>
<div>sudo /sbin/service shiny-server status</div>
</blockquote>
</div>
</div>
<p>总结一下就是，最新的系统用的是systemctl， 是一种管制服务的主要工具， 它整合了chkconfig 与 service功能于一体。如果你查看很多教程里面提到了chkconfig 与 service，你尽管用这个systemctl替代就好了</p>
<p>systemctl is-enabled iptables.service<br />
systemctl is-enabled servicename.service #查询服务是否开机启动<br />
systemctl enable *.service #开机运行服务<br />
systemctl disable *.service #取消开机运行<br />
<b>systemctl start *.service #启动服务<br />
systemctl stop *.service #停止服务<br />
systemctl restart *.service #重启服务</b><br />
systemctl reload *.service #重新加载服务配置文件<br />
systemctl status *.service #查询服务运行状态<br />
systemctl --failed #显示启动失败的服务</p>
<p>注：*代表某个服务的名字，如http的服务名为httpd</p>
]]></content:encoded>
			<wfw:commentRss>http://www.bio-info-trainee.com/1685.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>ubuntu服务器解决方案第十讲&#8211;虚拟机屏幕及联网设置</title>
		<link>http://www.bio-info-trainee.com/577.html</link>
		<comments>http://www.bio-info-trainee.com/577.html#comments</comments>
		<pubDate>Wed, 01 Apr 2015 02:45:08 +0000</pubDate>
		<dc:creator><![CDATA[ulwvfje]]></dc:creator>
				<category><![CDATA[linux]]></category>
		<category><![CDATA[服务器]]></category>
		<category><![CDATA[联网]]></category>
		<category><![CDATA[虚拟机]]></category>

		<guid isPermaLink="false">http://www.bio-info-trainee.com/?p=577</guid>
		<description><![CDATA[发现自己搞服务器遇到的困难还是蛮多的，所以记录了一下，给菜鸟们指个路。 ubun &#8230; <a href="http://www.bio-info-trainee.com/577.html">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
				<content:encoded><![CDATA[<p>发现自己搞服务器遇到的困难还是蛮多的，所以记录了一下，给菜鸟们指个路。<br />
ubuntu对生信菜鸟来说是最好用的linux服务器，没有之一，因为它有apt-get。</p>
<p>很多人可能并没有自己的服务器，那么就只能通过虚拟机来试试ubuntu啦</p>
<p>我想起来我以前玩虚拟机的时候遇到过一些困难，记录了一些，分享给大家，<span id="more-577"></span></p>
<h2 style="text-align: center;"><b>虚拟机</b><b>vmare</b><b>全屏</b></h2>
<p>vmare下安装了ubuntu, Ctrl+Alt+Enter将虚拟机全屏显示后，系统只能占据屏幕的一部分，</p>
<p>百度之，原因五花八门，解决方法各式各样， 依个人之间就是系统显示率的问题嘛！</p>
<p>Ctrl+Alt+Enter后，虚拟机倒是全屏了，但因为linux的显示率太小，所以只能占据屏幕的一部分！</p>
<p>故调整linux显示率即可：</p>
<p>右上角-&gt;系统设置-display&gt;显示，将分辨率调整成显示器的分辨率就ok了！</p>
<p>注意：</p>
<p>分辨率大于显示器建议分辨率，则系统只能显示一部分，右侧或底部会出现滚动条，</p>
<p>而当分辨率设置太小时，当然就不能占据整个屏幕了！</p>
<p>调整分辨率后，Ctrl+Alt+Enter将虚拟机全屏显示，ok，linux也全屏了！</p>
<h2 style="text-align: center;"><b>虚拟机</b><b>vmare</b><b>联网</b></h2>
<p>把你虚拟机中操作系统的“本地连接”也设置为自动获得IP、自动获得DNS服务器。</p>
<p>本例中：</p>
<p>System -&gt; Preferences -&gt; Network Connections -&gt; wired -&gt; Add.</p>
<p>然后填写connection name, 勾选Connect automatically，</p>
<p>其他的选择默认即可</p>
<p>最后登录网页查看是否可以上网，</p>
<p>PS: 要确保VMware 可以上网，具体操作如下:</p>
<p>开始---设置--控制面板---管理工具---服务</p>
<p>确保 VMware DHCP Service 和VMware NAT Service 服务已经启动</p>
]]></content:encoded>
			<wfw:commentRss>http://www.bio-info-trainee.com/577.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>ubuntu服务器解决方案第八讲&#8211;网络服务器配置lamp</title>
		<link>http://www.bio-info-trainee.com/573.html</link>
		<comments>http://www.bio-info-trainee.com/573.html#comments</comments>
		<pubDate>Wed, 01 Apr 2015 02:39:54 +0000</pubDate>
		<dc:creator><![CDATA[ulwvfje]]></dc:creator>
				<category><![CDATA[linux]]></category>
		<category><![CDATA[服务器]]></category>
		<category><![CDATA[网络]]></category>

		<guid isPermaLink="false">http://www.bio-info-trainee.com/?p=573</guid>
		<description><![CDATA[发现自己搞服务器遇到的困难还是蛮多的，所以记录了一下，给菜鸟们指个路。 ubun &#8230; <a href="http://www.bio-info-trainee.com/573.html">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
				<content:encoded><![CDATA[<p>发现自己搞服务器遇到的困难还是蛮多的，所以记录了一下，给菜鸟们指个路。<br />
ubuntu对生信菜鸟来说是最好用的linux服务器，没有之一，因为它有apt-get。</p>
<p>主流的网络服务器配置就是linux+apache+mysql+php咯，简称LAMP</p>
<p>在ubuntu系统里面安装这个是非常easy的</p>
<p>sudo apt-get install apache2 mysql-server mysql-client php5 php5-gd php5-mysql<span id="more-573"></span></p>
<p>由于LAMP大部分操作与/var/www目录相关，为了方便，修改该目录的权限为普通用户可访问。</p>
<p>sudo chmod 777 /var/www/</p>
<ol start="2">
<li>phpmyadmin 安装</li>
</ol>
<p>sudo apt-get install phpmyadmin</p>
<p>在安装过程中会要求选择Web server：apache2或lighttpd，选择apache2，按tab键然后确定。然后会要求输入设置的Mysql数据库密码连接密码 Password of the database's administrative user。</p>
<p>然后将phpmyadmin与apache2建立连接，以我的为例：www目录在/var/www，phpmyadmin在/usr/share /phpmyadmin目录，所以就用命令：sudo ln -s /usr/share/phpmyadmin /var/www 建立连接。</p>
<p>&nbsp;</p>
<p>phpmyadmin测试：在浏览器地址栏中打开http://localhost/phpmyadmin。</p>
<ol start="3">
<li>Apache 配置</li>
</ol>
<p>（1）启用 mod_rewrite 模块</p>
<p>终端命令：sudo a2enmod rewrite</p>
<p>（2）重启Apache服务器：sudo /etc/init.d/apache2 restart</p>
<p>Apache重启后可以测试一下，在/var/www目录下新建文件test.php，写入代码： 保存，在地址栏输入http://127.0.0.1/test.php 或 http://localhost/test.php ，如果正确出现了Mysql已经正确配置，表明Apache和mysql都正常了。(记得重启Apache服务器后再测试)。</p>
<p>&nbsp;</p>
<ol start="4">
<li>浏览器PHP中文乱码问题</li>
</ol>
<p>上面在FireFox浏览器中打开test.php测试时，如果出现了中文乱码，则是默认语言设置问题，解决方法如下：</p>
<p>打开apache配置文件： udo gedit /etc/apache2/apache2.conf，在最后面加上：AddDefaultCharset UTF-8，如果还是乱码的，再将UTF-8改用gb2312。</p>
<p>重启Apache：sudo /etc/init.d/apache2 restart 再刷新test.php 中文乱码没有了</p>
]]></content:encoded>
			<wfw:commentRss>http://www.bio-info-trainee.com/573.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>ubuntu服务器解决方案第七讲-perl安装模块</title>
		<link>http://www.bio-info-trainee.com/571.html</link>
		<comments>http://www.bio-info-trainee.com/571.html#comments</comments>
		<pubDate>Wed, 01 Apr 2015 02:36:56 +0000</pubDate>
		<dc:creator><![CDATA[ulwvfje]]></dc:creator>
				<category><![CDATA[linux]]></category>
		<category><![CDATA[perl]]></category>
		<category><![CDATA[服务器]]></category>
		<category><![CDATA[模块]]></category>

		<guid isPermaLink="false">http://www.bio-info-trainee.com/?p=571</guid>
		<description><![CDATA[此教程可能过期了，请直接看最新版(perl模块安装大全) 发现自己搞服务器遇到的 &#8230; <a href="http://www.bio-info-trainee.com/571.html">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
				<content:encoded><![CDATA[<p><strong><span style="color: #ff0000;">此教程可能过期了，请直接看最新版</span></strong>(<a href="http://www.bio-info-trainee.com/2451.html" target="_blank">perl模块安装大全</a>)</p>
<p>发现自己搞服务器遇到的困难还是蛮多的，所以记录了一下，给菜鸟们指个路。<br />
ubuntu对生信菜鸟来说是最好用的linux服务器，没有之一，因为它有apt-get。</p>
<p>前面我简单写了一个perl的cpan安装模块，但是前些天突然发现有些perl模块在cpan里面找不到，所以又总结了一下不同的perl模块安装方法。<span id="more-571"></span></p>
<p>一 Linux/Unix下安装Perl模块有两种方法：手工安装和自动安装。</p>
<p>第一种方法是从CPAN上下载您需要的模块，手工编译、安装。第二种方法是使用CPAN模块自动完成下载、编译、安装的全过程。</p>
<p>A、手工安装的步骤：</p>
<p>从 CPAN(http://search.cpan.org/)下载了Net-Server模块0.97版的压缩文件Net-Server-0.97.tar.gz，假设放在/usr/local/src/下。</p>
<p>cd /usr/local/src</p>
<p>tar xvzf Net-Server-0.97.tar.gz</p>
<p>cd Net-Server-0.97</p>
<p>perl Makefile.PL</p>
<p>make test</p>
<p>如果测试结果报告“all test ok”，您就可以放心地安装编译好的模块了。</p>
<p>安装模块前，先要确保您对 perl5 安装目录有可写权限(通常以 su 命令获得)，执行：</p>
<p>make install</p>
<p>现在，试试 DBI 模块吧。如果下面的命令没有给出任何输出，那就没问题。</p>
<p>$&gt;perl -MNet::Server -e1</p>
<p>上述步骤适合于 Linux/Unix下绝大多数的Perl模块。可能还有少数模块的安装方法略有差别，所以最好先看看<b>安装目录里的</b><b> </b><b>README 或</b><b> </b><b>INSTALL。</b></p>
<p>有的时候如果是build.pl的需要以下安装步骤：（需要Module::Build模块支持）</p>
<p>perl Build.PL</p>
<p>./Build</p>
<p>./Build test</p>
<p>./Build install</p>
<p>B、使用CPAN模块自动安装方法一：</p>
<p>安装前需要先联上网，并且您需要取得root权限。</p>
<p>perl -MCPAN -e shell</p>
<p>初次运行CPAN时需要做一些设置，如果您的机器是直接与因特网相联(拨号上网、专线，etc.)，那么一路回车就行了，只需要在最后一步选一个离您最近的 CPAN 镜像站点。例如我选的是位于国内的http://www.cnblogs.com/itech/admin/ftp://www.perl87.cn/CPAN/ 。否则，如果您的机器位于防火墙之后，还需要设置ftp代理或http代理。下面是常用 cpan 命令。</p>
<p>cpan&gt;help</p>
<p>cpan&gt;m</p>
<p>cpan&gt;install Net::Server</p>
<p>cpan&gt;quit</p>
<p>C、使用CPAN模块自动安装方法二：</p>
<p>cpan -i 模块名</p>
<p>例如：cpan -i Net::Server</p>
<p>先下载tar.gz ...然後手动安装..default 安装到/usr/local/目录下..</p>
<p>然後修改/usr/bin/perl的symbolic link到/usr/local/bin/perl</p>
]]></content:encoded>
			<wfw:commentRss>http://www.bio-info-trainee.com/571.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>ubuntu服务器解决方案第六讲-添加环境变量</title>
		<link>http://www.bio-info-trainee.com/569.html</link>
		<comments>http://www.bio-info-trainee.com/569.html#comments</comments>
		<pubDate>Wed, 01 Apr 2015 02:32:15 +0000</pubDate>
		<dc:creator><![CDATA[ulwvfje]]></dc:creator>
				<category><![CDATA[linux]]></category>
		<category><![CDATA[服务器]]></category>
		<category><![CDATA[环境变量]]></category>

		<guid isPermaLink="false">http://www.bio-info-trainee.com/?p=569</guid>
		<description><![CDATA[发现自己搞服务器遇到的困难还是蛮多的，所以记录了一下，给菜鸟们指个路。 ubun &#8230; <a href="http://www.bio-info-trainee.com/569.html">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
				<content:encoded><![CDATA[<p>发现自己搞服务器遇到的困难还是蛮多的，所以记录了一下，给菜鸟们指个路。<br />
ubuntu对生信菜鸟来说是最好用的linux服务器，没有之一，因为它有apt-get。</p>
<p>在我的第一讲里面，对JAVA的安装，其实就需要添加环境变量，大家可以回头看看！</p>
<p>添加PATH环境变量，第1种方法：</p>
<p>[root@lx_web_s1 ~]# export PATH=/usr/local/webserver/mysql/bin:$PATH</p>
<p>再次查看：</p>
<p>[root@lx_web_s1 ~]# echo $PATH</p>
<p>/usr/local/webserver/mysql/bin:/usr/local/webserver/mysql/bin/:/usr/kerberos/sbin:/usr/kerberos/bin:/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin:/root/bin</p>
<p>说明添加PATH成功。</p>
<p>上述方法的PATH 在终端关闭 后就会消失。所以还是建议通过编辑/etc/profile来改PATH，也可以修改家目录下的.bashrc(即：~/.bashrc)。</p>
<p>第2种方法：需要管理员权限。</p>
<p># vim /etc/profile</p>
<p>在最后，添加:</p>
<p>export PATH="/usr/local/webserver/mysql/bin:$PATH"</p>
<p>保存，退出，然后运行：</p>
<p>#source /etc/profile，不报错则成功。</p>
]]></content:encoded>
			<wfw:commentRss>http://www.bio-info-trainee.com/569.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>ubuntu服务器解决方案第五讲-配置ssh供远程登录</title>
		<link>http://www.bio-info-trainee.com/566.html</link>
		<comments>http://www.bio-info-trainee.com/566.html#comments</comments>
		<pubDate>Wed, 01 Apr 2015 02:30:32 +0000</pubDate>
		<dc:creator><![CDATA[ulwvfje]]></dc:creator>
				<category><![CDATA[linux]]></category>
		<category><![CDATA[服务器]]></category>
		<category><![CDATA[远程登录]]></category>

		<guid isPermaLink="false">http://www.bio-info-trainee.com/?p=566</guid>
		<description><![CDATA[发现自己搞服务器遇到的困难还是蛮多的，所以记录了一下，给菜鸟们指个路。 ubun &#8230; <a href="http://www.bio-info-trainee.com/566.html">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
				<content:encoded><![CDATA[<p>发现自己搞服务器遇到的困难还是蛮多的，所以记录了一下，给菜鸟们指个路。<br />
ubuntu对生信菜鸟来说是最好用的linux服务器，没有之一，因为它有apt-get。</p>
<p>同样，这个ssh也非常简单</p>
<p>sudo apt-get install openssh-server</p>
<p>SSH分客户端openssh-client和openssh-server</p>
<p>如果你只是想登陆别的机器的SSH只需要安装openssh-client（ubuntu有默认安装，如果没有则sudo</p>
<p>apt-get install openssh-client），如果要使本机开放SSH服务就需要安装openssh-server</p>
<p>sudo apt-get install openssh-server</p>
<p>然后确认sshserver是否启动了：</p>
<p>ps -e |grep ssh</p>
<p>如果看到sshd那说明ssh-server已经启动了。</p>
<p>如果没有则可以这样启动：sudo /etc/init.d/ssh start 或者 service ssh start</p>
<p>ssh-server配置文件位于/etc/ssh/sshd_config，在这里可以定义SSH的服务端口，默认端口是22，你可以自己定义成其他端口号，如222。</p>
<p>然后重启SSH服务：</p>
<p>sudo</p>
<p>/etc/init.d/ssh stop</p>
<p>sudo /etc/init.d/ssh start</p>
<p>然后使用以下方式登陆SSH：</p>
<p>ssh username@192.168.1.112 username为192.168.1.112 机器上的用户，需要输入密码。</p>
<p>我给七八个虚拟机都配置成功了，但是呢，偏偏别人的一个我始终不能解决，感觉linux里面的学问还是蛮多的</p>
]]></content:encoded>
			<wfw:commentRss>http://www.bio-info-trainee.com/566.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>ubuntu服务器解决方案第四讲-输入法-中文</title>
		<link>http://www.bio-info-trainee.com/562.html</link>
		<comments>http://www.bio-info-trainee.com/562.html#comments</comments>
		<pubDate>Wed, 01 Apr 2015 02:26:06 +0000</pubDate>
		<dc:creator><![CDATA[ulwvfje]]></dc:creator>
				<category><![CDATA[linux]]></category>
		<category><![CDATA[服务器]]></category>
		<category><![CDATA[输入法]]></category>

		<guid isPermaLink="false">http://www.bio-info-trainee.com/?p=562</guid>
		<description><![CDATA[发现自己搞服务器遇到的困难还是蛮多的，所以记录了一下，给菜鸟们指个路。 ubun &#8230; <a href="http://www.bio-info-trainee.com/562.html">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
				<content:encoded><![CDATA[<p>发现自己搞服务器遇到的困难还是蛮多的，所以记录了一下，给菜鸟们指个路。<br />
ubuntu对生信菜鸟来说是最好用的linux服务器，没有之一，因为它有apt-get。</p>
<p>这个主要是针对有界面的服务器来说的，不是我们通常意义的ssh登陆，一般ssh登陆的可以把中文复制张贴进去即可。</p>
<p>Ubuntu上的输入法主要有小小输入平台（支持拼音/二笔/五笔等），Fcitx，Ibus，Scim等。其中Scim和Ibus是输入法框架。</p>
<p>在Ubuntu的中文系统中自带了中文输入法，通过Ctrl+Space可切换中英文输入法。这里我们主要说下Ubuntu英文系统中，中文输入法的安装。</p>
<p>安装输入法的第一步，是安装语言包。我们选择System Settings--&gt;Language Support--&gt;Install/Remove Languages，这里面可以选择简体中文</p>
<p>输入密码后，系统会安装简体中文语言包。</p>
<p>第二步，安装完毕后切换到终端，安装IBus框架，在终端输入以下命令：</p>
<p>sudo apt-get install ibus ibus-clutter ibus-gtk ibus-gtk3 ibus-qt4</p>
<p>启动IBus框架，在终端输入：</p>
<p>im-switch -s ibus</p>
<p>安装完IBus框架后注销系统，保证更改立即生效。</p>
<p>第三步：安装拼音引擎</p>
<p>有下面几种常用选择：</p>
<p>IBus拼音：sudo apt-get install ibus-pinyin</p>
<p>IBUS五笔：sudo apt-get install ibus-table-wubi</p>
<p>谷歌拼音输入法：sudo apt-get install ibus-googlepinyin</p>
<p>Sun拼音输入法：sudo apt-get install ibus-sunpinyin</p>
<p>第四步：设置IBus框架</p>
<p>终端输入ibus-setup 此时，IBus Preference设置被打开。我们在Input Method选项卡中，选择自己喜欢的输入方式，并配置自己喜欢的快捷键即可。</p>
<p>第五步：通常情况下，IBus图标（一个小键盘）会出现在桌面右上角的任务栏中。有时候这个图标会自行消失，可使用以下命令，找回消失的IBus图标：</p>
<p>ibus-daemon –drx</p>
]]></content:encoded>
			<wfw:commentRss>http://www.bio-info-trainee.com/562.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>ubuntu服务器解决方案第三讲-perl最新版的安装</title>
		<link>http://www.bio-info-trainee.com/557.html</link>
		<comments>http://www.bio-info-trainee.com/557.html#comments</comments>
		<pubDate>Wed, 01 Apr 2015 02:16:03 +0000</pubDate>
		<dc:creator><![CDATA[ulwvfje]]></dc:creator>
				<category><![CDATA[linux]]></category>
		<category><![CDATA[perl]]></category>
		<category><![CDATA[服务器]]></category>

		<guid isPermaLink="false">http://www.bio-info-trainee.com/?p=557</guid>
		<description><![CDATA[发现自己搞服务器遇到的困难还是蛮多的，所以记录了一下，给菜鸟们指个路。 ubun &#8230; <a href="http://www.bio-info-trainee.com/557.html">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
				<content:encoded><![CDATA[<p>发现自己搞服务器遇到的困难还是蛮多的，所以记录了一下，给菜鸟们指个路。<br />
ubuntu对生信菜鸟来说是最好用的linux服务器，没有之一，因为它有apt-get。</p>
<p>理论上perl是不需要更新，但是我就不巧碰到了这个情况，所以也记录一下</p>
<p>linux下升级系统默认安装的perl版本，不建议先rm</p>
<p>先下载tar.gz ...然後手动安装..default 安装到/usr/local/目录下..</p>
<p>然後修改/usr/bin/perl的symbolic link到/usr/local/bin/perl</p>
<p>下载方式不用说了吧，各显神通，笔者习惯用wget.</p>
<p>所以wget[url]http://www.cpan.org/src/perl-5.10.0.tar.gz[/url] .现在最新是5.20</p>
<p>下载完以后解压安装</p>
<p>#tar zxvf perl-5.10.0.tar.gz</p>
<p>#cd perl-5.10.0</p>
<p>#./Configure -des -Dprefix=/usr/local/perl</p>
<p>参数-Dprefix指定安装目录为/usr/local/perl</p>
<p>#make</p>
<p>#make test</p>
<p>#make install</p>
<p>如果这个过程没有错误的话，那么恭喜你安装完成了.是不是很简单？</p>
<p>接下来替换系统原有的perl,有最新的了咱就用嘛.</p>
<p>#mv /usr/bin/perl/ usr/bin/perl.bak</p>
<p>#ln -s /usr/local/perl/bin/perl/ usr/bin/perl</p>
<p>#perl –v</p>
<p>然后就可以了用它来安装一些其它你需要的perl模块了</p>
<p>#perl -MCPAN-e shell</p>
<p>第一次执行的话，会提示安装cpan并要求连接网络下载最新的模块列表.然后就可以安装东西了</p>
<p>cpan[1]&gt; install DBI</p>
]]></content:encoded>
			<wfw:commentRss>http://www.bio-info-trainee.com/557.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>ubuntu服务器解决方案第二讲-R程序包最新版的安装</title>
		<link>http://www.bio-info-trainee.com/555.html</link>
		<comments>http://www.bio-info-trainee.com/555.html#comments</comments>
		<pubDate>Wed, 01 Apr 2015 02:13:39 +0000</pubDate>
		<dc:creator><![CDATA[ulwvfje]]></dc:creator>
				<category><![CDATA[linux]]></category>
		<category><![CDATA[R]]></category>
		<category><![CDATA[服务器]]></category>

		<guid isPermaLink="false">http://www.bio-info-trainee.com/?p=555</guid>
		<description><![CDATA[发现自己搞服务器遇到的困难还是蛮多的，所以记录了一下，给菜鸟们指个路。 ubun &#8230; <a href="http://www.bio-info-trainee.com/555.html">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
				<content:encoded><![CDATA[<div>发现自己搞服务器遇到的困难还是蛮多的，所以记录了一下，给菜鸟们指个路。</div>
<div>ubuntu对生信菜鸟来说是最好用的linux服务器，没有之一，因为它有apt-get。</div>
<div>首先，如果你的服务器里面有旧的R，那么删除Linux Ubuntu系统中原有的R软件包，代码如下：</div>
<div>sudo apt-get autoremove r-base-core # 删除系统中原有的R软件包</div>
<div>接下来，<span style="color: #ff0000;"><strong>随便</strong></span>找到一个Ubuntu的软件源镜像</div>
<div>（http://mirror.bjtu.edu.cn/cran/bin/linux/ubuntu/ )</div>
<div>因为看我教程的大部分在国内，所以我拿北京大学举例子。</div>
<div> 当然，厦门大学也很赞，<a href="http://mirrors.xmu.edu.cn/CRAN/bin/linux/ubuntu/xenial/" target="_blank">http://mirrors.xmu.edu.cn/CRAN/bin/linux/ubuntu/xenial/</a>  不过，版本代号一定药搞清楚哦。</div>
<div>PS(2017/12/20, 没想到随便找到来一个，就挂掉了，唉：</p>
<h1 class="entry-title"><a title="Permalink to 厦门大学不再提供R语言镜像" href="http://www.bio-info-trainee.com/2896.html" rel="bookmark">厦门大学不再提供R语言镜像</a></h1>
<p>)</p></div>
<div></div>
<div>Linux Ubuntu 12.04对应的名字是 precise，</div>
<div>ubuntu14.04，那么就应该是 trusty</div>
<div>ubuntu15.04 ，其代号为 vivid</div>
<div>Ubuntu 16.04 LTS，代号为Xenial Xerus（非洲的一种地松鼠），于UTC时间2016年4月21日正式发布。</div>
<div></div>
<div>比如我的Ubuntu 12.04就需要进入到 precise/目录，找到r-base-core相关的文件，发现有多个R的版本。</div>
<div>把这个软件源，增加到apt的sources.list文件中，代码如下：</div>
<div>deb http://mirror.bjtu.edu.cn/cran/bin/linux/ubuntu precise/</div>
<div>其余的ubuntu版本类似即可：</div>
<div></div>
<div>在/etc/apt/sources.list文件最下面，新加一行</div>
<div></div>
<div>~ sudo apt-get update # 更新源</div>
<div>~ sudo apt-get install r-base-core # 再次安装R语言软件包</div>
<div>~ R –version # 检查R的版本</div>
<div></div>
<div>这时我们就安装了最新的R语言版本—3.0.3版。</div>
<div></div>
<div>require(ggplot2)</div>
<div></div>
<div>Loading required package: ggplot2</div>
<div></div>
<div>Failed with error: ‘package ‘ggplot2’ was built before R 3.0.0: please re-install it’</div>
<div></div>
<div>这个失败原因是怎么回事？R 3.0.0 的问题吗？怎么解决？</div>
<div></div>
<div>R 2.x 升级 3.x 需要重新（编译）安装所有包：</div>
<div></div>
<div>update.packages(checkBuilt = TRUE, ask = FALSE)</div>
<div></div>
<div>当然如果你不是在R里面用install.package来安装包的话</div>
<div></div>
<div>你还需要</div>
<div></div>
<div>sudo apt-get install r-base-dev</div>
<div>这样你才能从源代码编译R的包</div>
<div></div>
<div>但是如果你导入的R源被你的服务器拒绝，你就惨了</div>
<div>The following signatures couldn't be verified because the public key is not</div>
<div>以下签名不能因为公钥未验证</div>
]]></content:encoded>
			<wfw:commentRss>http://www.bio-info-trainee.com/555.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
