Learn the powerful enterprise adaptable database:

Getting Started With ADABAS & Natural

Thursday, January 24, 2013

XAMPP for Linux On Centos 6.3


Setup steps for XAMPP for Linux On Centos 6.3

Note:
a. This tutorial is based on VirtualBox Image of Centos 6.3 downloadable from http://sourceforge.net/projects/virtualboximage/files/CentOS/6.0/CentOS-6-Gnome-i386.7z/download.
b. This image uses Italian Keyboard Layout. It is recommended that you change the layout to United States. Otherwise, you may have problem such as vi commands not getting through the system.
c. The steps below were adapted from http://www.host1free.com/forum/vps-technical-support/7609-tutorial-how-install-xampp-centos-6-a.html.


1. Run Centos 6.3.
a. Log in as Centos.
b. Run Terminal.
c. Change user to root. Enter password "reverse".

[centos@localhost ~]$ su



2. Update system using yum
[root@localhost centos]# yum update


3. Get the latest version of XAMPP Linux
[root@localhost centos]# wget http://www.apachefriends.org/download.php?xampp-linux-1.8.1.tar.gz



4.  Extract it to /opt/ folder
[root@localhost centos]# tar xvfz xampp-linux-1.8.1.tar.gz -C /opt


5.after you run the xampp be sure you stop the httpd service(in case it is pre-installed)
[root@localhost centos]# service httpd stop


6.add password to the /xampp/,Phpmyadmin,mysql and FTP
[root@localhost centos]# /opt/lampp/lampp security
you will asked to add password. be sure you will remember the password. the password in mysql is not recoverable.

The Virtual Image that we are using is currently using centos/reverse and root/reverse for username/password. To make it easy, set all passwords to 'reverse'. Remember that username for XAMPP is 'lampp'.


7.Edit the httpd-xampp.conf
[root@localhost centos]# vi /opt/lampp/etc/extra/httpd-xampp.conf


8. Remove the following line(end of the file):
<LocationMatch "^/(?i:(?:xampp|security|licenses|phpmyadmin|webalizer|server-status|server-info))">
Order deny,allow
Deny from all
Allow from ::1 127.0.0.0/8 \
fc00::/7 10.0.0.0/8 172.16.0.0/12 192.168.0.0/16 \
81.196.40.94/32
ErrorDocument 403 /error/XAMPP_FORBIDDEN.html.var
</LocationMatch>
useful vi commands:
[alt]+i = INSERT mode
[esc] = shift from INSERT mode to COMMAND mode
dd = delete a line
zz = save
:wq = save before quit
:q = quit without save

9. Run XAMPP
[root@localhost centos]# /opt/lampp/lampp start


10. The XAMPP is now working. if you don't know the username this is the default username:
Code:
/xampp/ - lampp
PhpMyAdmin - root
MySql - root
ProFTP - nobody




11. Useful Paths:
/opt/lampp/bin/ - The XAMPP commands home. /opt/lampp/bin/mysql calls for example the MySQL monitor.
/opt/lampp/htdocs/ - The Apache DocumentRoot directory.
/opt/lampp/etc/httpd.conf - The Apache configuration file.
/opt/lampp/etc/my.cnf - The MySQL configuration file.
/opt/lampp/etc/php.ini - The PHP configuration file.
/opt/lampp/etc/proftpd.conf - The ProFTPD configuration file. (since 0.9.5)
/opt/lampp/phpmyadmin/config.inc.php - The phpMyAdmin configuration file.


1 comment: