#navi(linux関連);
昨年度の卒研でまとめた資料です。 バージョンが古いので参考程度にとどめてください。
なお、ディストリビュージョンに含まれるパッケージは予め削除する必要があります。

*httpd [#v5891b53]
%% wget http://sunsite.tus.ac.jp/pub/apache/httpd/httpd-2.0.58.tar.gz %%~
wget http://www.apache.org/dist/httpd/httpd-2.0.59.tar.gz~
tar zxvf httpd-2.0.59.tar.gz~
cd httpd-2.0.59~
./configure --enable-ssl --enable-so~
make~
make install~
vi /etc/rc.d/rc.local~
 /usr/local/apache2/bin/apachectl start を追加
vi /usr/local/apache2/conf/httpd.conf~
 ServerAdmin you@example.com -> 変更
 ServerAdmin hamada@nbu.ac.jp

 ServerName www.example.com:80 -> 変更
 ServerName xxx.xxxxx.xx.xx:80

~
~
~
*MySQL [#f31e748b]
groupadd mysql~
useradd -g mysql mysql~
passwd mysql~
wget http://dev.mysql.com/get/Downloads/MySQL-4.1/mysql-4.1.20.tar.gz/from/http://mirror.mysql-partners-jp.biz/~
tar zxvf mysql-4.1.20.tar.gz~
cd mysql-4.1.20~
./configure --prefix=/usr/local/mysql --with-charset=ujis --with-extra-charset=all --with-mysql-user=mysql~
make~
make install~
/usr/local/mysql/bin/mysql_install_db --user=mysql~
/usr/local/mysql/bin/mysqld_safe --user=mysql &~
/usr/local/mysql/bin/mysql -u root -p~
Enter password:<enter>
 SET PASSWORD FOR root@localhost=PASSWORD('xxxxxxx');
 GRANT ALL PRIVILEGES ON xoopsdb.* TO xoops@localhost IDENTIFIED BY 'xxxxxxx';
 create database xoopsdb;
 \q
cp /usr/local/mysql/share/mysql/mysql.server /etc/init.d/~
/sbin/chkconfig --add mysql.server~
~
 再起動後
 service mysql.server start
~
~
*PostgreSQL [#ge50e944]
useradd postgres~
passwd postgres~
mkdir /usr/local/pgsql~
chown postgres.postgres /usr/local/pgsql~
vi /etc/rc.d/init.d/postgres~
 #!/bin/sh
 #
 # PostgreSQL start and shutdown script
 #
 # chkconfig: 345 90 11
 # description: PostgreSQL start and shutdown script
 . /etc/init.d/functions
 case "$1" in
  start)
    runuser - postgres -c "pg_ctl -o \"-S -i\" start"
    touch /var/lock/subsys/postgres
    ;;
  stop)
    runuser - postgres -c "pg_ctl -m Fast stop"
    rm -f /var/lock/subsys/postgres
    ;;
  *)
    echo "Usage: /etc/rc.d/init.d/postgres  {start|stop}"
 esac
 exit 0

chmod 755 /etc/rc.d/init.d/postgres~
cd /etc/rc.d/init.d/~
chkconfig --add postgres~

su - postgres~
vi .bashrc~
 export POSTGRES_HOME=/usr/local/pgsql
 export PGLIB=$POSTGRES_HOME/lib
 export PGDATA=$POSTGRES_HOME/data
 export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$PGLIB
 PATH=$PATH:$POSTGRES_HOME/bin
source ~/.bashrc~
wget ftp2.jp.postgresql.org/pub/postgresql/source/v7.4.13/postgresql-7.4.13.tar.gz~
tar zxvf postgresql-7.4.13.tar.gz~
./configure --enable-multibyte=UNICOODE~
make~
make install~
initdb~


*php (with mysql&postgresql) [#j1fa6ce3]
%% wget http://jp2.php.net/get/php-4.4.2.tar.gz/from/jp.php.net/mirror %%~
%% wget http://www.php.net/get/php-4.4.2.tar.gz/from/a/mirror %%~
wget http://jp2.php.net/get/php-4.4.4.tar.gz/from/jp.php.net/mirror~
tar zxvf php-4.4.4.tar.gz~
cd php-4.4.4~~
 環境に応じて変えてください。
 mysql + postgresql
 ./configure --enable-mbstr-enc-trans --enable-track-vars --enable-trans-sid --with-apxs2=/usr/local/apache2/bin/apxs --enable-ftp --with-mysql=/usr/local/mysql --with-pgsql=/usr/local/pgsql
 mysqlのみ
 ./configure --enable-mbstr-enc-trans --enable-track-vars --enable-trans-sid --with-apxs2=/usr/local/apache2/bin/apxs --enable-ftp --with-mysql=/usr/local/mysql
 postgresqlのみ
 ./configure --enable-mbstr-enc-trans --enable-track-vars --enable-trans-sid --with-apxs2=/usr/local/apache2/bin/apxs --enable-ftp --with-pgsql=/usr/local/pgsql


make~
make install~
vi /usr/local/apache2/conf/httpd.conf~
 AddType application/x-httpd-php .php   ->追加
 LoadModule php4_module        modules/libphp4.so ->追加
 DirectoryIndex index.html index.html.var    ->変更
 DirectoryIndex index.php index.html index.html.var

~
~
~
*xoops [#md59803a]
%% wget http://prdownloads.sourceforge.jp/xoops/20474/xoops-2.0.15-JP.tar.gz %%~
wget http://qgpop.dl.sourceforge.jp/xoops/20474/xoops-2.0.15-JP.tar.gz~
tar zxvf xoops-2.0.15-JP.tar.gz~
mv xoops-2.0.15-JP/html /usr/local/apache2/htdocs/xoops~
cd /usr/local/apache2/htdocs/xoops/~
chmod 777 uploads cache templates_c~
chmod 666 mainfile.php~
~
~
 webブラウザでインストール作業を継続
 その後、
 cd /usr/local/apache2/htdocs/xoops/
 mv install install_org
 chmod 644 mainfile.php
~
 ユーザ毎に作成する場合
 su - xxxxx
 wget http://qgpop.dl.sourceforge.jp/xoops/20474/xoops-2.0.15-JP.tar.gz
 tar zxvf xoops-2.0.15-JP.tar.gz
 %%mv xoops-2.0.15-JP/html /usr/local/apache2/htdocs/xoops%%
 mv xoops-2.0.15-JP/html/ ./public_html
 chmod 701 .
 chmod 701 public_html
 chmod 777 public_html/uploads public_html/cache public_html/templates_c
 chmod 666 public_html/mainfile.php

 webブラウザでインストール作業を継続の後、
 mv install install_org
 chmod 644 mainfile.php


~
~
*pukiwiki [#r0c378cf]
wget http://prdownloads.sourceforge.jp/pukiwiki/12957/pukiwiki-1.4.7.tar.gz ~

%% cp pukiwiki-1.4.4.tar.gz ./ %%~
tar zxvf pukiwiki-1.4.7.tar.gz~
mv pukiwiki-1.4.7 public_html~
cd public_html ~
chmod 755 . ~
chmod 644 *.gif *.png *.php *.lng ~
chmod 777 ./attach ./backup ./counter ./diff ./wiki ./cache ~
chmod 755 ./face  ./image  ./plugin  ./skin ~

 chmod 755 . ~
 chmod 644 *.gif *.png *.php *.lng ~
 chmod 777 ./attach ./backup ./counter ./diff ./wiki ./cache ~
 chmod 755 ./face  ./image  ./plugin  ./skin ~
 
 chmod 666 ./wiki/*.txt
 chmod 666 ./cache/*
 chmod 666 ./cache/*.*

 
 chmod 644 ./face/*.png
 chmod 644 ./image/*.png
 chmod 644 ./image/*.gif
 chmod 644 ./plugin/*.php
 chmod 644 ./skin/*.php
 chmod 644 ./skin/*.css
 
 rm COPYING.txt
 rm UPDATING.txt
 rm  README.txt
~
*VMWareのインストール用空イメージ [#jfc4702f]
添付のzipファイルを展開して使用してください。

トップ   編集 差分 バックアップ 添付 複製 名前変更 リロード   新規 一覧 単語検索 最終更新   ヘルプ   最終更新のRSS