Installing and Configuring Apache PHP and MySQL on ArchLinux
A server is an indispensable tool for any web developer, even if someone does not want to try a software developer as wordpress or joomla need to install a local server to do so.
Archlinux gives us the opportunity to have one very easily.
The first thing to do is install tenermos binaries MySQL, PHP and Apache and then configure the environment:
We add our user to the http:
where "Pahko" is the name of its user.
Edit the file / etc / hosts and add the following line (probably already have, if not be sure it is well):
Then you can access your server via http://localhost/, if you want to have another name being followed can put like this:
So you can also access your server via http://maebo/, you should just make sure the name you are giving to the server is the same as they have in / etc / rc.conf on the line HOSTNAME = "Maebe" .
Apache configuration:
Edit the file / etc / httpd / conf / httpd.conf and comment or rather we put a "#" in the following line:
being as follows:
Reboot the server:
Now you can see the server running on http://localhost/ or in my case also http://maebo/.
We added the devil in our / etc / rc.conf:
Create the directory "public_html" folder on our staff is, in my case / home / Pahko / running / home / Pahko / public_html / and give permissions:
Now we have the server with folders for each user accessing the server through http://localhost/ ~ user as mine would be: http://localhost/ ~ Pahko /
Configuring PHP:
Edit the file / etc / httpd / conf / httpd.conf and add the following line:
right after:
Add just after:
this:
Edit the file / etc / php / php.ini and and de-comment the following line:
look like this:
the same with:
to:
also change the mode to debug:
being:
and
change this:
by:
reboot the server:
php and configured.
Apache Configuration:
Edit the file / etc / php / php.ini and mysql support enabled:
Edit the file / etc / php / php.ini and mysql support enabled:
to:
We start the mysql server:
Assign a root password to manage mysql:
We added to our rc.conf daemon:
With that we have running our local server!
0 comments:
Post a Comment