|
|||||||||
centos6.4 の変更点
su
yum -y update
yum -y install emacs lrzsz nkf gcc zlib-devel openssl-devel sqlite sqlite-devel gcc-c++ nmap policycoreutils-python
* 日本語化 [#gfcdeec7]
** キーボード配列を日本配列に [#s2357579]
/etc/sysconfig/keyboard
KEYTABLE="jp106"
MODEL="jp106"
LAYOUT="jp"
KEYBOARDTYPE="pc"
** 起動時のログを出す [#h98bad51]
/boot/grub/grub.conf
rhgb quiet を消す
** Xを落とす [#v6ce9b39]
/etc/inittab
id:3:initdefault:
** ネットワークをブリッジ化 [#jd30bb6f]
player -> 管理 -> 仮想マシン設定
/etc/init.d/network restart
ssh で入れることを確認後再起動
shutdown -r now
** 日本語環境のインストール [#a69edce6]
yum -y groupinstall "Japanese Support"
fc-cache -fv
** emacs nowindow の設定 [#s1ecd4a1]
/root/.bashrc
alias emacs="emacs -nw"
/root/.emacs
;; for japanese
(set-language-environment "Japanese")
(prefer-coding-system 'utf-8-unix)
(set-terminal-coding-system 'utf-8)
(set-keyboard-coding-system 'utf-8)
(set-buffer-file-coding-system 'utf-8)
(set-default-coding-systems 'utf-8)
(setq default-buffer-file-coding-system 'utf-8)
** timezone の変更 [#j9b89006]
cp -p /usr/share/zoneinfo/Japan /etc/localtime
** atomic repository の追加 [#b1e982c5]
wget -q -O - http://www.atomicorp.com/installers/atomic | sh
/etc/yum.repos.d/atomic.repo
enabled = 0
yum remove httpd
yum -y install --enablerepo=atomic httpd
mkdir -p /var/www/html
chown apache. /var/www/html
** imagemagic [#rd8f4f65]
yum -y install --enablerepo=atomic ImageMagick ImageMagick-perl
** mysql [#e4f28950]
yum -y remove mysql
yum -y install --enablerepo=atomic mysql mysql-server
///etc/my.cnf
// [mysqld]
// default-character-set=utf8
** php [#kf1fac8f]
yum remove php
yum -y install --enablerepo=atomic php php-mysqlnd
yum -y install --enablerepo=atomic php-pear
pear upgrade PEAR
//** iptables 無効化 [#v8275c70]
// chkconfig iptables off
** iptables 設定 [#v9b293fe]
iptables -I INPUT 5 -p tcp -m tcp --dport 80 -j ACCEPT
iptables -I INPUT 5 -p tcp -m tcp --dport 443 -j ACCEPT
service iptables save
service iptables restart
** ntpd [#nafc48a8]
chkconfig ntpd on
** httpd [#i97eb4c3]
chkconfig httpd on
----
** epel [#l3834fab]
wget http://ftp-srv2.kddilabs.jp/Linux/distributions/fedora/epel/6/x86_64/epel-release-6-8.noarch.rpm
rpm -ivh epel-release-6-8.noarch.rpm
----
** ruby [#p809ff66]
cd /usr/local/src
wget ftp://ftp.ruby-lang.org/pub/ruby/2.0/ruby-2.0.0-p353.tar.gz
tar xzfp ruby-2.0.0-*.tar.gz
cd ruby-2.0.0-*
./configure
make
make install
* SELinux [#vc69806b]
開発機なら無効化、本番機なら設定する
** SELinux 無効化 [#reb70918]
/etc/selinux/config
SELINUX=desabled
** SELinux 設定 [#aed680d7]
例: httpd で公開するサービスで有効化したいものがある場合
setenforce 0
service httpd restart
wget localhost -O /dev/null
grep httpd /var/log/audit/audit.log | audit2allow -M 【有効化したいプログラム】
semodule -i 【有効化したいプログラム】.pp
setenforce 1
service httpd restart
|
|||||||||