!HP Microserver Gen8 に CentOSをインストール 面倒な場合には DVD付きを注文すること 今回はCentOS6.5 をインストールする (オンボードの RAIDでRAID1 を構成) 標準では RAIDカードは認識しないのでダウンロードの事 http://downloads.linux.hp.com/SDR/repo/spp/2013.09.0_supspp_rhel6.5_x86_64/hpvsa-1.2.8-140.rhel6u5.x86_64.dd.gz USB-起動の場合には USB_KEY ポートに接続の事!! GRUB 起動時に"ESCキー"を押して text ブートにする事 boot: 時に linux dd blacklist=ahci と入力して にて起動し device driver の質問に [yes] 接続しているデバイスを選択すると デバイスの中身の一覧が表示されるので hpvsa-1.2.8-140.rhel6u5.x86_64.dd を選択して  起動する  後は通常のインストールと同じ DownLoadPoint http://downloads.linux.hp.com/ http://downloads.linux.hp.com/SDR/repo/mcp/ http://downloads.linux.hp.com/SDR/repo/spp/ !yum の proxy の設定 # /etc/yum.conf に次の行を # Proxy Setting proxy=http://your.proxy.server:8080 proxy_username=username proxy_password=password !gcc のインストール yum -y update yum install gcc yum install ncurses-devel # pthread を使うとき yum install boost-thread.x86_64 ## セルフビルドするときは次の物が必要?? gmp-devel.x86_64 gmp-static.x86_64 glib2-devel.x86_64 glibc-devel.x86_64 compat-glibc.x86_64 compat-glibc-headers.x86_64 glibc-static.x86_64 glibc-utils.x86_64 glibc-devel.i686 glibc.i686 glibc-devel.i686 glibc-static.i686 ## GMP 4.2+, gmp-6.0.0a.tar.bz2 ## MPFR 2.4.0+, mpfr-3.1.2.tar.bz2 ## MPC 0.8.0+, mpc-1.0.2.tar.gz ## ##../configure --with-gmp --p--with-mpfr --with-mpc --with-mpc prefix=$HOME/opt/ ## ../configure --with-gmp --with-mpfr --with-mpc --prefix=$TGT/opt/ ## ## パスを通す方法を調べないと。。エラーが。。 ## ln -s $TGT/opt/include/mpfr.h ./gcc ## ln -s $TGT/opt/include/mpc.h ./gcc ## ln -s $TGT/opt/lib/libmpc.so .libs ## ln -s $TGT/opt/lib/libmpfr.so .libs !telnetd/ftpd のインストール yum install telnet-server yum install vsftpd yum install tcp_wrappers yum install sharutils yum install jwhois yum install mt-st !gnome のインストール yum groupinstall "Desktop" "Desktop Platform" "General Purpose Desktop" !FW の停止 #/etc/rc.d/init.d/iptables stop iptables: Flushing firewall rules: [ OK ] iptables: Setting chains to policy ACCEPT: filter [ OK ] iptables: Unloading iptables modules: [ OK ] # chkconfig iptables off # chkconfig ip6tables off # setenforce 0 # getenforce Permissive # vi /etc/selinux/config SELINUX=disabled ################# # SL7 の時 systemctl stop iptables systemctl stop ip6tables # # chkconfig iptables off # chkconfig ip6tables off systemctl diseble iptables systemctl diseble ip6tables setenforce 0 getenforce vi /etc/selinux/config !VMへの設定 yum groupinstall 'Development Tools' yum install kernel-devel yum xorg-x11-server-devel VMware が update できなく。。 ## A previous installation of VMware Tools has been detected. ## The previous installation was made by the tar installer (version 4). ## Keeping the tar4 installer database format. と言って VMwareTool がインストール出来なくなったら。。 tar xvfz ./VMwareTools-X.X.X-xxxxxxxx.tar.gz を展開して cd ./vmware-tools-distrib/ ./bin/vmware-uninstall-tools.pl と uninstaller を実行する !Cable 抜けの確認 cat /sys/class/net/eth0/operstate ! ether ネットの IPアドレスの設定 CentOS6 の IPアドレスの設定が 変わった ifconfig コマンドでは動かない場合がある ip addr add 10.1.1.1/24 dev eth1 ip addr add 10.1.1.2/24 dev eth1:1 ip link set eth1 up ip route add default via 10.1.1.254 dev eth1 ip route add 10.2.2.0/24 via 10.1.1.210 dev eth1 !routing の追加(恒久的についか) DefaultGateway /etc/sysconfig/network に GATEWAY=10.1.1.254 の様についか StatucRouting eth1 の場合 /etc/sysconfig/network-scripts/route-eth1 に 10.2.2.0/24 via 10.1.1.210 172.17.0.0/16 via 10.1.1.253 192.168.250.0/24 via 10.1.1.250 192.168.55.0/24 via 10.1.1.254 192.168.1.0/24 via 10.1.1.252 192.168.55.0/24 via 10.1.1.254 192.168.2.0/24 via 10.1.1.249 192.168.56.0/24 via 10.1.1.254 # 10.0.0.0/8 via 10.1.1.250 の様についか !hosts ファイルのチェック /etc/nsswitch.conf hosts: files dns の順番を入れ替える !IPv6 の停止 # service ip6tables stop # chkconfig ip6tables off /etc/sysconfig/network に NETWORKING_IPV6=no を追加 !mail ######### yum install sendmail.x86_64 yum install sendmail-cf.noarch ## chkconfig postfix off chkconfig sendmail on ######### # /etc/sendmail.mc の 修正 116c116 < DAEMON_OPTIONS(`Port=smtp,Addr=127.0.0.1, Name=MTA')dnl --- > dnl DAEMON_OPTIONS(`Port=smtp,Addr=127.0.0.1, Name=MTA') # MTA の切り替え # alternatives --display mta # alternatives --config mta ######### yum install dovecot ## chkconfig dovecot on ## /etc/dovecot/dovecot.conf /etc/dovecot/conf.d/10-mail.conf /etc/dovecot/conf.d/10-auth.conf をそれぞれ編集 /etc/dovecot/dovecot.conf ... ###protocols = imap imaps pop3 pop3s protocols = pop3 pop3s ... /etc/dovecot/conf.d/10-mail.conf ... mail_location = mbox:~/mail:INBOX=/var/mail/%u ... /etc/dovecot/conf.d/10-auth.conf ... ## ??? ToDO ??? # mkdir -p /etc/skel/mail/.imap/INBOX # chmod -R 700 /etc/skel/mail # chmod 770 /etc/skel/mail/.imap/INBOX/ !named TIPS named.conf へ 20,21c25,28 < dnssec-enable yes; < dnssec-validation yes; --- > // dnssec-enable yes; > // dnssec-validation yes; > dnssec-enable no; > dnssec-validation no; /etc/sysconfig/named OPTIONS="-4" !! apache の設定 ! 特定ユーザの公開(http.conf) # UserDir is disabled by default since it can confirm the presence # of a username on the system (depending on home directory # permissions). # # ( all user ) # UserDir enable # ( Just usage user green & miki ) UserDir disable UserDir enabled green miki # # To enable requests to /~user/ to serve the user's public_html # directory, remove the "UserDir disable" line above, and uncomment # the following line instead: # UserDir public_html !SElinuxが有効な場合の設定( public_html を公開する) SELinux有効時は、ディレクトリのラベルを再設定しないと、 apacheが読み込めません。 ( パーミッションの許可がありませんになる ) ラベルを設定するにはrootにて以下を実行します。 # restorecon /home/ユーザ名/public_html # restorecon -R /home/ユーザ名/public_html restorecon /home/green/public_html restorecon -R /home/green/public_html # restorecon /home/miki/public_html restorecon -R /home/miki/public_html 最初に、~/public_htmlのラベルを初期化し、 -Rで、~/public_html配下のファイル/ディレクトリを初期化する。 結果的に、public_htmlを含めたファイル/ディレクトリのラベルが system_u:object_r:httpd_user_content_t になります。