Linux - SoftwareThis forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
I'm using CentOS4 x86_64, and I want to compile/install Apache, Php and MySQL from the source code.
I have downloaded and untarred all three softwares, but I'm not understanding what options should I include. This is the first time I compile form source, and I'm doing it because I want to have some experience, and because YUM does not offer the latest releases of these softwares.
I have downloaded the source code to ~/sourcecode/ folder. I have a basic experience, as I tried to compile apache once.
My question is: What kind of options do you recommend? and what should be compiled before the other?
so far, I have gathered these information: Apache first, then MySql, then php. I know the --prefix option, and something about apsx, which I have no idea what that is. For PHP, I think there is --with-mysql or something...
And what about security? I always read that each process (apache, php, mysql) should be run on different useraccount with tight privileges. Any of you have experience in that? and how do I exactly do it?
I couldn't compile MySQL. I'm trying to figure out how ....
Are you sure you've downloaded the sources. Because the common mysql software you can d/l from mysql.com is the binary. If it is the source you can install it with the usual procedure ./configure, make, make install. If it's the binary read the included INSTALL file to see how to install it.
Is there a way to enable MySQL later on when I compile it? As you noticed, I didn't use --with-mysql when compiling PHP.
you can install mysql whenever you want or need. You can take a binary version too. They are compiled with intel compiler and tend to run faster than those built with gcc. The --with-mysql would have been useful if you intend to connect to mysql from php...
You can search the support-files/ subdirectory where you've compiled mysql for various my-whatever.cnf. Pick the one that matches your needs and copy it in /etc, or under the subdir etc/ in the directory you've installed mysql.
ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/tmp/mysql.sock'
Make sure you did all the necessary steps before starting the server for the first time. You should give apropriate permissions to the databases directory and use the supplied scripts to create initial tables.
You can also search LQ for this error to find more answers.