�ncelikle anlat?m masa�st� bilgisayarlar i�indir, server s�r�mleri i�in de?ildir.
Kurulum PC-BSD 8.2 de ger�ekle?mi?tir.
Asl?nda buna kurulum de?ilde "derleme" demek daha do?ru olur, zatende �yle
Portlar? g�ncellemek isterseniz komutlar? verebilirsiniz. (?art de?il)
# portsnap fetch
# portsnap extract
# portsnap extract
1. MySQL kurulumu ;
Komut a
# cd /usr/ports/databases/mysql55-client; make install clean
# cd /usr/ports/databases/mysql55-client; make install clean
**mysql51-client hata verirse altaki komutla kald?r?n, sonra tekrar Komut a'y? verin.**
# cd /usr/ports/databases/mysql51-client ; make deinstall
Komut b
# cd /usr/ports/databases/mysql55-server; make install clean
# cd /usr/ports/databases/mysql55-server; make install clean
**mysql51-cserver hata verirse altaki komutla kald?r?n, sonra tekrar Komut b'yi verin.**
# cd /usr/ports/databases/mysql51-server ; make deinstall
Komut c
# echo 'mysql_enable="YES"' >> /etc/rc.conf
# echo 'mysql_enable="YES"' >> /etc/rc.conf
Komut d
# /usr/local/etc/rc.d/mysql-server onestart
# /usr/local/etc/rc.d/mysql-server onestart
MySQL ?ifresi
Komut e
# rehash
# mysqladmin -uroot password �mysql_?ifreni_yaz�
# rehash
# mysqladmin -uroot password �mysql_?ifreni_yaz�
Komut f
# /usr/local/etc/rc.d/mysql-server onestop
# /usr/local/etc/rc.d/mysql-server onestart
# /usr/local/etc/rc.d/mysql-server onestop
# /usr/local/etc/rc.d/mysql-server onestart
Apache Kurulumu ;
Komut a
# cd /usr/ports/www/apache22; make install clean
# cd /usr/ports/www/apache22; make install clean
Komut b
# echo 'apache22_enable="YES"' >> /etc/rc.conf
# echo 'apache22_enable="YES"' >> /etc/rc.conf
Komut c >> /usr/local/etc/apache22/httpd.conf
##ServerName www.example.com:80 alt?na altaki komutu ekle
Servername 127.0.0.1
##ServerName www.example.com:80 alt?na altaki komutu ekle
Servername 127.0.0.1
Komut d
http://127.0.0.1/ adresinde It works! g�rd�yseniz Apache i?lemi tamamd?r.
http://127.0.0.1/ adresinde It works! g�rd�yseniz Apache i?lemi tamamd?r.
3. PHP Kurulumu ;
Komut a
# cd /usr/ports/lang/php5; make install clean
# cd /usr/ports/lang/php5; make install clean
**Not**
Kurarken konfigurasyon penceresinde "APACHE Build Apache module" se�meyi unutmay?n..
Komut b
# cd /usr/ports/lang/php5-extensions; make install clean
# cd /usr/ports/lang/php5-extensions; make install clean
Komut c
# cp /usr/local/etc/php.ini-production /usr/local/etc/php.ini
# cp /usr/local/etc/php.ini-production /usr/local/etc/php.ini
Komut d >> /usr/local/etc/apache22/httpd.conf
## Dosyan?n en alt?nda </IfModule> alt?na ekle
AddType application/x-httpd-php .php
AddType application/x-httpd-php-source .phps
Ayn? dosyada <IfModule dir_module> alt?nda
## Bul
DirectoryIndex index.html
## De?i?tir
DirectoryIndex index.php index.html
## Dosyan?n en alt?nda </IfModule> alt?na ekle
AddType application/x-httpd-php .php
AddType application/x-httpd-php-source .phps
Ayn? dosyada <IfModule dir_module> alt?nda
## Bul
DirectoryIndex index.html
## De?i?tir
DirectoryIndex index.php index.html
Komut e >> /usr/local/etc/apache22/extra/httpd-languages.conf
## En alt?na ekle
AddDefaultCharset On
## En alt?na ekle
AddDefaultCharset On
Komut d >> /etc/host
## Benzer ?ekilde olacak ayn?s? olmas?na gerek yok !!
::1 localhost localhost.pcbsd-1893 pcbsd-1893
127.0.0.1 localhost localhost.pcbsd-1893 pcbsd-1893
## Benzer ?ekilde olacak ayn?s? olmas?na gerek yok !!
::1 localhost localhost.pcbsd-1893 pcbsd-1893
127.0.0.1 localhost localhost.pcbsd-1893 pcbsd-1893
Komut e
# /usr/local/etc/rc.d/apache22 onestart
# /usr/local/etc/rc.d/apache22 onestart
4. phpMyAdmin kurulumu ;
Komut a
# cd /usr/ports/databases/phpmyadmin; make install clean
# cd /usr/ports/databases/phpmyadmin; make install clean
Komut b >> /usr/local/etc/apache22/httpd.conf
## Sat?r? bul <IfModule alias_module> alt?na ekle
Alias /phpmyadmin /usr/local/www/phpMyAdmin
<Directory �/usr/local/www/phpMyAdmin�>
Order allow,deny
Allow from all
</Directory>
## Sat?r? bul <IfModule alias_module> alt?na ekle
Alias /phpmyadmin /usr/local/www/phpMyAdmin
<Directory �/usr/local/www/phpMyAdmin�>
Order allow,deny
Allow from all
</Directory>
Komut c
# cd /usr/local/www
# chown -R root:wheel phpMyAdmin
# chmod +x phpMyAdmin
# cd /usr/local/www
# chown -R root:wheel phpMyAdmin
# chmod +x phpMyAdmin
Komut d
# ln -s /usr/local/www/phpMyAdmin/ /usr/local/www/apache22/data/
# ln -s /usr/local/www/phpMyAdmin/ /usr/local/www/apache22/data/
Komut e
# cp config.sample.inc.php config.inc.php
# cd phpMyAdmin; mkdir config; chmod o+rw config
# cp config.inc.php config/; chmod o+w config/config.inc.php
# cp config.sample.inc.php config.inc.php
# cd phpMyAdmin; mkdir config; chmod o+rw config
# cp config.inc.php config/; chmod o+w config/config.inc.php
Bu noktada taray?c?da http://127.0.0.1/phpMyAdmin/setup/ adresi a�?l?p phpMyAdmin'e ayar �ekilebilir, ayar bitince, Komut d'yi d�nd�r.
Komut d
# rm /usr/local/www/phpMyAdmin/config.inc.php
# mv config/config.inc.php .; chmod o-rw config.inc.php; rm -rf config
# rm /usr/local/www/phpMyAdmin/config.inc.php
# mv config/config.inc.php .; chmod o-rw config.inc.php; rm -rf config
Art?k phpMyAdmin'in aray�z�n� g�rebilmeniz laz?md?r.
http://127.0.0.1/phpMyAdmin/
Sorunlar ve ��z�mleri ;
phpMyAdmin'in aray�z�n� g�r�yor ama ?ifre problemi y�z�nden i�eri giremiyorsan?z MySql ?ifresini resetleyin.
* MySql ?ifre resetleme ;
"Sistem izleyici"sinde �al??an mysql programlar? varsa killall ile durdurun ve devam..
% which mysqld_safe
# /usr/local/bin/mysqld_safe --skip-grant-tables &
a�?lan sayfay? ctrl x ile kapatabilirsiniz, ard?ndan devam..
mysql -uroot
mysql>use mysql
mysql> UPDATE user SET password=PASSWORD('yeni_?ifre_gir') WHERE user='root';
mysql> FLUSH PRIVILEGES;
mysql> quit
% which mysqld_safe
# /usr/local/bin/mysqld_safe --skip-grant-tables &
a�?lan sayfay? ctrl x ile kapatabilirsiniz, ard?ndan devam..
mysql -uroot
mysql>use mysql
mysql> UPDATE user SET password=PASSWORD('yeni_?ifre_gir') WHERE user='root';
mysql> FLUSH PRIVILEGES;
mysql> quit
MySQL'e tam UTF-8 deste?i vermek ;
E?er MySQL'de karakter problemleri ya?arsan?z kurdu?unuz mysql55-server'i �nce durdurun.
# /usr/local/etc/rc.d/mysql-server onestop
Ard?ndan kald?r?n.
# cd /usr/ports/databases/mysql55-server; make deinstall
Ard?ndan da b�yle derleyebilirsiniz.
# make BUILD_OPTIMIZED=yes BUILD_STATIC=yes WITH_CHARSET=utf8 WITH_COLLATION=utf8_general_ci install
Devam..
# cp /usr/local/share/mysql/my-huge.cnf /etc/my.cnf
Dosyay? a�?n >> /etc/my.cnf
[mysqld] b�l�m�nde gelen ilk bo? yere a?a??dakileri ekleyin..
init_connect='SET collation_connection = utf8_general_ci'
init_connect='SET NAMES utf8'
default-character-set=utf8
character-set-server=utf8
collation-server=utf8_general_ci
skip-character-set-client-handshake
Devam..
# /usr/local/etc/rc.d/mysql-server onestart
Sorun ya?arsan?z MySQL ?ifrenizi resetlemek gerekebilir.
# /usr/local/etc/rc.d/mysql-server onestop
Ard?ndan kald?r?n.
# cd /usr/ports/databases/mysql55-server; make deinstall
Ard?ndan da b�yle derleyebilirsiniz.
# make BUILD_OPTIMIZED=yes BUILD_STATIC=yes WITH_CHARSET=utf8 WITH_COLLATION=utf8_general_ci install
Devam..
# cp /usr/local/share/mysql/my-huge.cnf /etc/my.cnf
Dosyay? a�?n >> /etc/my.cnf
[mysqld] b�l�m�nde gelen ilk bo? yere a?a??dakileri ekleyin..
init_connect='SET collation_connection = utf8_general_ci'
init_connect='SET NAMES utf8'
default-character-set=utf8
character-set-server=utf8
collation-server=utf8_general_ci
skip-character-set-client-handshake
Devam..
# /usr/local/etc/rc.d/mysql-server onestart
Sorun ya?arsan?z MySQL ?ifrenizi resetlemek gerekebilir.
* phpMyAdmin girince b�yle bir hata al?rsan?z taray?c? �erezlerini silin.
phpMyAdmin - Error
Cannot start session without errors, please check errors given in your PHP and/or webserver log file and configure your PHP installation properly.
Cannot start session without errors, please check errors given in your PHP and/or webserver log file and configure your PHP installation properly.
* Apache Mod_rewrite ;
Dosyay? bul >> /usr/local/etc/apache22/httpd.conf
<Directory "/usr/local/www/apache22/data"> bir ka� sat?r alt?nda
--
Bul
AllowOverride None
De?i?tir
AllowOverride All
<Directory "/usr/local/www/apache22/data"> bir ka� sat?r alt?nda
--
Bul
AllowOverride None
De?i?tir
AllowOverride All
Public_html ; (sanal dizin)
�rn: ev dizinine public_html diye bir dizin a�?l?r.
% mkdir public_html
# ln -s /home/kul_ad?/public_html /usr/local/www/apache22/data/
yazma izni i�inde
# chmod -R 777 /home/kul_ad?/public_html
Adres sat?r? b�yle olunca public_html i�indesiniz
http://127.0.0.1/public_html/
% mkdir public_html
# ln -s /home/kul_ad?/public_html /usr/local/www/apache22/data/
yazma izni i�inde
# chmod -R 777 /home/kul_ad?/public_html
Adres sat?r? b�yle olunca public_html i�indesiniz
http://127.0.0.1/public_html/
MySQL
Sunucu: Localhost via UNIX socket
Sunucu s�r�m�: 5.5.12
Protokol s�r�m�: 10
Kullan?c?: root@localhost
MySQL karakter grubu: UTF-8 Unicode (utf8)
Web sunucusu
Apache/2.2.19 (FreeBSD) mod_ssl/2.2.19 OpenSSL/0.9.8q DAV/2 PHP/5.3.6 with Suhosin-Patch
MySQL istemci s�r�m�: mysqlnd 5.0.8-dev - 20102224 - $Revision: 308673 $
PHP uzant?s?: mysqli
phpMyAdmin
S�r�m bilgisi: 3.4.1, son sa?lam s�r�m: 3.4.1
Sunucu: Localhost via UNIX socket
Sunucu s�r�m�: 5.5.12
Protokol s�r�m�: 10
Kullan?c?: root@localhost
MySQL karakter grubu: UTF-8 Unicode (utf8)
Web sunucusu
Apache/2.2.19 (FreeBSD) mod_ssl/2.2.19 OpenSSL/0.9.8q DAV/2 PHP/5.3.6 with Suhosin-Patch
MySQL istemci s�r�m�: mysqlnd 5.0.8-dev - 20102224 - $Revision: 308673 $
PHP uzant?s?: mysqli
phpMyAdmin
S�r�m bilgisi: 3.4.1, son sa?lam s�r�m: 3.4.1