This install log is for a Xen/Fedora. For an Ubuntu server, see [[EMF Build Server Setup]].

+

= EMFT Build Server Setup =

= EMFT Build Server Setup =

You will need to be root for most of these tasks.

You will need to be root for most of these tasks.

+

+

== UPDATE: Apache 2.2, MySQL 5.0, PHP 5.2 ==

+

+

Since build.eclipse.org and most of the rest of *.eclipse.org has now completed the [[SLES_10_Upgrade_Plan | SLES 10 Upgrade]], I decided to do the same with emft.eclipse.org. A few weeks ago we tried to build PHP 5 w/ support for MySQL 5 and get that working with Apache 2, but ultimately the make failed and we had to give up. Tonight, I discovered [http://www.apachefriends.org/en/xampp-linux.html#374 XAMPP 1.5.5a], which is '''SO MUCH EASIER''' it's kinda embarassing I didn't try it earlier. In about 15 mins I had 4 services set up: httpd, mysqld, php, and ftpd. Since I didn't feel like reconfiguring the MySQL 5 server - all that was missing was Apache's support for MySQL 5 with PHP 5 - I have since only turned on the XAMPP Apache 2.2 server, and disabled the rest.

+

+

Beyond the crazy-easy install instructions provided on the [http://www.apachefriends.org/en/xampp-linux.html#374 XAMPP] website, the only additional thing I had to do was to create a replacement for <code>/etc/init.d/httpd</code>, then symlink that new script back to the previous so that the new apache would be used instead of the old one.

+

+

I also had to symlink the existing content in <code>/var/www/html</code> into the new location, <code>/opt/lampp/htdocs/</code>.

UPDATE (2006/12/20): XAMPP (lampp) runs by default as user and group "nobody". This might be a problem if that user doesn't exist on your system or you've already got folders set to be owned by a different web user, such as "www-data" or "apache". You can fix this problem by editing <code>/opt/lampp/etc/httpd.conf</code> thus:

If you can't use the yum-xen.conf file noted above, you can update using the repository information in your /etc/yum.repos.d/*.repo files. If you're looking to upgrade your FC version, see [http://fedoraproject.org/wiki/YumUpgradeFaq Yum Upgrade FAQ].

* Ensure your <tt style="color:DarkGreen">/etc/hosts</tt> file contains a line such as this, so that the server knows its own name:

+

+

127.0.0.1 foo.eclipse.org localhost localhost.localdomain

+

+

== Configure Sendmail Message Relay ==

+

+

Your build server is [https://bugs.eclipse.org/bugs/show_bug.cgi?id=212980 probably not allowed] to send mail by itself for a number of security and performance reasons. As such, you need to enable message relaying via a secondary mail host. Here's how.

+

+

* Edit <code>/etc/mail/sendmail.cf</code>

+

+

{{codeblock|# "Smart" relay host (may be null)

+

DSmail.eclipse.org}}

+

+

* Restart sendmail

+

+

{{codeblock| /etc/init.d/sendmail restart}}

+

+

* Test w/ <code>/usr/sbin/sendmail -t -v</code>

+

+

{{codeblock|Subject: test relay send

+

To: your.name.here@some.address.com

+

+

Hey, this is a test.

+

.}}

== Fix web user (apache) ==

== Fix web user (apache) ==

Line 191:

Line 250:

* Create password file, where <tt style="color:DarkGreen">_username_</tt> should be replaced with an actual username and <tt style="color:DarkGreen">/path/to/password/file</tt> should be replaced with an actual path:

* Create password file, where <tt style="color:DarkGreen">_username_</tt> should be replaced with an actual username and <tt style="color:DarkGreen">/path/to/password/file</tt> should be replaced with an actual path:

−

<pre>httpasswd -c /path/to/password/file _username_</pre>

+

<pre>htpasswd -c /path/to/password/file _username_</pre>

* You can add additional users to the password file like this:

* You can add additional users to the password file like this:

−

<pre>httpasswd /path/to/password/file _username2_</pre>

+

<pre>htpasswd /path/to/password/file _username2_</pre>

* Create <tt style="color:DarkGreen">.htaccess</tt> file, replacing <tt style="color:DarkGreen">/path/to/password/file</tt> with the same path used in the previous step:

* Create <tt style="color:DarkGreen">.htaccess</tt> file, replacing <tt style="color:DarkGreen">/path/to/password/file</tt> with the same path used in the previous step:

Line 256:

Line 315:

adduser -p '''''newuserpassword''''' ''newuser''

adduser -p '''''newuserpassword''''' ''newuser''

−

* Then copy .bashrc, .bash_profile, and .alias from an existing user to the new user's home dir.

+

* Then copy .bashrc, .bash_profile, and .alias from an existing user (if not using <code>/etc/skel</code>) to the new user's home dir.

EMFT Build Server Setup

You will need to be root for most of these tasks.

UPDATE: Apache 2.2, MySQL 5.0, PHP 5.2

Since build.eclipse.org and most of the rest of *.eclipse.org has now completed the SLES 10 Upgrade, I decided to do the same with emft.eclipse.org. A few weeks ago we tried to build PHP 5 w/ support for MySQL 5 and get that working with Apache 2, but ultimately the make failed and we had to give up. Tonight, I discovered XAMPP 1.5.5a, which is SO MUCH EASIER it's kinda embarassing I didn't try it earlier. In about 15 mins I had 4 services set up: httpd, mysqld, php, and ftpd. Since I didn't feel like reconfiguring the MySQL 5 server - all that was missing was Apache's support for MySQL 5 with PHP 5 - I have since only turned on the XAMPP Apache 2.2 server, and disabled the rest.

Beyond the crazy-easy install instructions provided on the XAMPP website, the only additional thing I had to do was to create a replacement for /etc/init.d/httpd, then symlink that new script back to the previous so that the new apache would be used instead of the old one.

I also had to symlink the existing content in /var/www/html into the new location, /opt/lampp/htdocs/.

UPDATE (2006/12/20): XAMPP (lampp) runs by default as user and group "nobody". This might be a problem if that user doesn't exist on your system or you've already got folders set to be owned by a different web user, such as "www-data" or "apache". You can fix this problem by editing /opt/lampp/etc/httpd.conf thus:

Troubleshooting

If you can't use the yum-xen.conf file noted above, you can update using the repository information in your /etc/yum.repos.d/*.repo files. If you're looking to upgrade your FC version, see Yum Upgrade FAQ.

Add a user

Start up mysql if not already connected.

mysql -u root -p

In mysql, run the following commands:

GRANT ALL PRIVILEGES ON *.* TO newuser@"%" IDENTIFIED BY 'newuser' WITH GRANT OPTION;
GRANT ALL PRIVILEGES ON *.* TO newuser@"localhost" IDENTIFIED BY 'newuser' WITH GRANT OPTION;
UPDATE mysql.user SET Password=PASSWORD('newuserpwd') WHERE User='newuser';
FLUSH PRIVILEGES;
QUIT;