<?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; centos</title>
	<atom:link href="http://www.liguosong.com/category/centos/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.liguosong.com</link>
	<description></description>
	<lastBuildDate>Tue, 08 May 2018 01:02:19 +0000</lastBuildDate>
	<language>zh-CN</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.5.2</generator>
		<item>
		<title>centos 查询、设置、删除yum 源</title>
		<link>http://www.liguosong.com/2016/11/14/centos-%e6%9f%a5%e8%af%a2%e3%80%81%e8%ae%be%e7%bd%ae%e3%80%81%e5%88%a0%e9%99%a4yum-%e6%ba%90/</link>
		<comments>http://www.liguosong.com/2016/11/14/centos-%e6%9f%a5%e8%af%a2%e3%80%81%e8%ae%be%e7%bd%ae%e3%80%81%e5%88%a0%e9%99%a4yum-%e6%ba%90/#comments</comments>
		<pubDate>Mon, 14 Nov 2016 03:44:23 +0000</pubDate>
		<dc:creator>lgs</dc:creator>
				<category><![CDATA[centos]]></category>
		<category><![CDATA[未分类]]></category>

		<guid isPermaLink="false">http://www.liguosong.com/?p=600</guid>
		<description><![CDATA[查询是否安装了 某个yum源 rpm -qa &#124;grep -i repo-name 删除该yum源 rpm - [...]]]></description>
				<content:encoded><![CDATA[<p>查询是否安装了 某个yum源</p>
<p>rpm -qa |grep -i repo-name</p>
<p>删除该yum源</p>
<p>rpm -e repo-name</p>
<p>安装yum源</p>
<p>&nbsp;</p>
<pre>rpm -Uvh https:<strong>//</strong>mirror.webtatic.com<strong>/</strong>yum<strong>/</strong>el6<strong>/</strong>latest.rpm</pre>
]]></content:encoded>
			<wfw:commentRss>http://www.liguosong.com/2016/11/14/centos-%e6%9f%a5%e8%af%a2%e3%80%81%e8%ae%be%e7%bd%ae%e3%80%81%e5%88%a0%e9%99%a4yum-%e6%ba%90/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Could not locate Gemfile</title>
		<link>http://www.liguosong.com/2016/11/03/could-not-locate-gemfile/</link>
		<comments>http://www.liguosong.com/2016/11/03/could-not-locate-gemfile/#comments</comments>
		<pubDate>Thu, 03 Nov 2016 09:11:13 +0000</pubDate>
		<dc:creator>lgs</dc:creator>
				<category><![CDATA[centos]]></category>

		<guid isPermaLink="false">http://www.liguosong.com/?p=588</guid>
		<description><![CDATA[犹豫中国伟大的防火墙，导致在执行bundle命令就到一半挂掉了，然后在执行命令就提示 Could not lo [...]]]></description>
				<content:encoded><![CDATA[<p>犹豫中国伟大的防火墙，导致在执行bundle命令就到一半挂掉了，然后在执行命令就提示</p>
<pre class="brush:bash">Could not locate Gemfile</pre>
<p>上网搜了一会，是因为缺少Gemfile文件。后来执行</p>
<pre class="brush:bash">bundle -h</pre>
<p>命令发现，可以生成一个新的Gemfile文件，命令是：</p>
<pre class="brush:bash">bundle init</pre>
<p>问题解决~~</p>
<p>&nbsp;</p>
]]></content:encoded>
			<wfw:commentRss>http://www.liguosong.com/2016/11/03/could-not-locate-gemfile/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>centos安装jenkins</title>
		<link>http://www.liguosong.com/2016/09/29/centos%e5%ae%89%e8%a3%85jenkins/</link>
		<comments>http://www.liguosong.com/2016/09/29/centos%e5%ae%89%e8%a3%85jenkins/#comments</comments>
		<pubDate>Thu, 29 Sep 2016 13:47:39 +0000</pubDate>
		<dc:creator>lgs</dc:creator>
				<category><![CDATA[centos]]></category>

		<guid isPermaLink="false">http://www.liguosong.com/?p=583</guid>
		<description><![CDATA[Jenkins是开源的Java编写的持续集成的工具，在Centos上可以通过yum命令行直接安装。 安装Jav [...]]]></description>
				<content:encoded><![CDATA[<p>Jenkins是开源的Java编写的持续集成的工具，在Centos上可以通过yum命令行直接安装。</p>
<h2 id="articleHeader0">安装Java</h2>
<p>看到当前系统java版本。</p>
<pre class="brush:bash">java -version</pre>
<p>如果java不存在运行命令：</p>
<pre class="brush:bash">sudo yum install java</pre>
<p>如果java不存在可以安装java,如果java存在可以升级java。</p>
<h2 id="articleHeader1">安装Jenkins</h2>
<p>添加Jenkins源:</p>
<pre class="brush:bash">sudo wget -O /etc/yum.repos.d/jenkins.repo http://jenkins-ci.org/redhat/jenkins.repo 
sudo rpm --import http://pkg.jenkins-ci.org/redhat/jenkins-ci.org.key</pre>
<p>安装Jenkins:</p>
<pre class="brush:bash">yum install jenkins</pre>
<h2 id="articleHeader2">启动Jenkins</h2>
<p>输入命令启动Jenkins:</p>
<pre class="brush:bash">sudo service jenkins start</pre>
<p>在浏览器中输入：<a href="http://127.0.0.1:8080/" target="_blank">http://127.0.0.1:8080/</a> 就可以使用jenkins了,如果没有UI系统可以在其他的浏览器中输入<a href="http://%3C/" target="_blank">http://&lt;</a>所在机器的ip&gt;:8080/进入Jenkins界面 。</p>
<pre class="brush:bash">sudo service jenkins stop</pre>
<p>可以停止Jenkins服务。</p>
<h2 id="articleHeader3">相关配置</h2>
<p>Jenkins安装目录：</p>
<pre class="brush:bash">cd /usr/lib/jenkins/</pre>
<p>Jenkins配置文件：</p>
<pre class="brush:bash">cd /etc/sysconfig</pre>
<p>Jenkins的配置文件在这里,名字是<code>jenkins</code></p>
<pre class="brush:bash">cat jenkins</pre>
<p>可以查看jenkins默认的配置。这里介绍下三个比较重要的配置目录<code>JENKINS_HOME </code>,<code>JENKINS_USER </code>,<code>JENKINS_PORT</code></p>
<pre class="brush:bash">## Path:        Development/Jenkins
## Description: Jenkins Continuous Integration Server
## Type:        string
## Default:     "/var/lib/jenkins"
## ServiceRestart: jenkins
#
# Directory where Jenkins store its configuration and working
# files (checkouts, build reports, artifacts, ...).
#
JENKINS_HOME="/var/lib/jenkins"</pre>
<p>Jenkins储存文件的地址,Jenkins的插件，生成的文件都会放在这里。</p>
<pre class="brush:bash">## Type:        string
## Default:     "jenkins"
## ServiceRestart: jenkins
#
# Unix user account that runs the Jenkins daemon
# Be careful when you change this, as you need to update
# permissions of $JENKINS_HOME and /var/log/jenkins.
#
JENKINS_USER="jenkins"</pre>
<p>Jenkins使用的用户，默认为<code>jenkins</code><code> </code></p>
<pre class="brush:bash">## Type:        integer(0:65535)
## Default:     8080
## ServiceRestart: jenkins
#
# Port Jenkins is listening on.
# Set to -1 to disable
#
JENKINS_PORT="8080"</pre>
<p>Jenkins的端口，默认端口是8080。</p>
<p>&nbsp;</p>
]]></content:encoded>
			<wfw:commentRss>http://www.liguosong.com/2016/09/29/centos%e5%ae%89%e8%a3%85jenkins/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>centos安装crontab</title>
		<link>http://www.liguosong.com/2015/12/08/centos%e5%ae%89%e8%a3%85crontab/</link>
		<comments>http://www.liguosong.com/2015/12/08/centos%e5%ae%89%e8%a3%85crontab/#comments</comments>
		<pubDate>Tue, 08 Dec 2015 09:00:56 +0000</pubDate>
		<dc:creator>lgs</dc:creator>
				<category><![CDATA[centos]]></category>

		<guid isPermaLink="false">http://www.liguosong.com/?p=558</guid>
		<description><![CDATA[安装 yum install cronie 启动 service crond start 配置]]></description>
				<content:encoded><![CDATA[<p>安装</p>
<pre><code>yum install cronie</code></pre>
<p>启动</p>
<pre class="brush:bash">service crond start</pre>
<p>配置</p>
]]></content:encoded>
			<wfw:commentRss>http://www.liguosong.com/2015/12/08/centos%e5%ae%89%e8%a3%85crontab/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>centos yiic could not find driver</title>
		<link>http://www.liguosong.com/2015/12/08/centos-yiic-could-not-find-driver/</link>
		<comments>http://www.liguosong.com/2015/12/08/centos-yiic-could-not-find-driver/#comments</comments>
		<pubDate>Tue, 08 Dec 2015 08:55:29 +0000</pubDate>
		<dc:creator>lgs</dc:creator>
				<category><![CDATA[centos]]></category>

		<guid isPermaLink="false">http://www.liguosong.com/?p=555</guid>
		<description><![CDATA[今天部署线上环境的时候，需要执行定时任务，发现yii的commands无法执行，报出错误如下： excepti [...]]]></description>
				<content:encoded><![CDATA[<p>今天部署线上环境的时候，需要执行定时任务，发现yii的commands无法执行，报出错误如下：</p>
<pre class="brush:bash">exception 'CDbException' with message 'CDbConnection failed to open the DB connection: could not find driver' in /data/www/framework/db/CDbConnection.php:399</pre>
<p>经过查找最终原因是没有安装mysql的pdo驱动，安装命令如下：</p>
<pre class="brush:bash">yum install php-pdo_mysql</pre>
<p>&nbsp;</p>
]]></content:encoded>
			<wfw:commentRss>http://www.liguosong.com/2015/12/08/centos-yiic-could-not-find-driver/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
