Will you guys give me a hand for setting up a web server??? I'm cracking this for about a week and 2 re-install of OS with no progress.
First of all, I'm in the University with a static IP 10.66.1.2 which is behind a firewall. The OS is RHLE AS 3.0 (Taroon Update 3) with 2 Lan Card. The Eth0 is disabled (Inactive) no ip setting while the Eth1 is Active and configured at:
IP: 10.66.1.2
Netmask: 255.255.0.0
Gateway: 10.66.255.254
Primary DNS: 10.0.1.1
I can browse the internet using proxy server settings with latest Firefox & Mozilla.
I have done the following:
1) Update RHLE's MySQL from 3 to 4 by following exact instruction here:
Download MySQL 4.1.x Source
Invoke the following:
# rpm -ivh MySQL-4.1.7-0.src.rpm ----> /usr/src/redhat/SOURCES
download the mysql.in & my.cnf-def -----> /usr/src/redhat/SOURCES
download mysql4.1.specs -----> /usr/src/redhat/SPECS
Invoke the following:
# rpmbuild -ba mysql4.1.specs
After an 1 hour & half of compiling...I got my own MySQL installation with no reported problem.
download mysql-3.23.58.9.i386.rpm ------> /usr/src/redhat/SOURCES
download MySQL-shared-compat.spec ------> /usr/src/redhat/SPECS
Invoke the following:
# rpmbuild -ba MySQL-shared-compat.spec
Now went to /usr/src/redhat/RPMS/i386
Invoke the following:
# rpm -Uvh --force mysql-shared-compat-3.23.58-9.i386.rpm mysql-server-4.1.7-OFC2.i386.rpm mysql-client-4.1.7-0FC2.i386.rpm
after a succesfull update.
Edited the following "/etc/ld.so.conf" to add this line
/usr/lib/mysql
Then Invoke the following to start mysql daemon:
# service mysql start
2) Installing Apache:
Download httpd-2.0.52.tar.gz
Invoke the following:
# tar -xvzf httpd-2.0.52.tar.gz
# mv httpd-2.0.58 /usr/src/httpd-2.0.52
# mkdir /usr/local/apache2
Went to -----> /usr/src/httpd-2.0.52
Invoke the following:
# ./configure --prefix=/usr/local/apache2 --enable-module=so
# make
# make install
After that done the following:
# /usr/local/apache2/bin/httpd -v
With the following output:
Server version: Apache/2.0.52
Server built: Dec 10 2004 16:00:03
After that I have edited the "/usr/local/apache2/conf/httpd.conf" add/modify the following:
"ServerAdmin" =
backroger@gmail.com
"ServerName" = 10.66.1.2:80
"UseCanonicalName" = On
"Options Indexes Includes FollowSymLinks SymLinksifOwnerMatch ExecCGI MultiViews"
"AllowOverride Options FileInfo AuthConfig Limit"
"DirectoryIndex index.html index.html.var" to "DirectoryIndex index.html index.html.var index.shtml index.cgi index.php index.phtml index.php3 index.htm home.html welcome.html"
"AddType application/x-httpd-php .php .phps .php3 .phtml .html .htm .shtml .fds"
"AddHandler cgi-script .cgi .pl"
Then copy favicon.ico "cp favicon.ico /var/www/html"
After that, went to "System Settings" > "Security Level" > and checked for "WWW (HTTP) & Eth1 " in the "Trusted services". After that restarted my computer.
Thanks to this site
http://stanton-finley.net/fedora_co..._notes.html#Web
After a successful restart, I have Invoke the following:
# /usr/local/apache2/bin/apachectl start
# ps auxw|grep httpd
Has the following output:
root 1292 0.1 1.4 9924 3596 ? S 15:10 0:00 /usr/local/apache2/bin/httpd -k start
nobody 1293 0.0 1.4 9924 3616 ? S 15:10 0:00 /usr/local/apache2/bin/httpd -k start
nobody 1294 0.0 1.4 9924 3616 ? S 15:10 0:00 /usr/local/apache2/bin/httpd -k start
nobody 1295 0.0 1.4 9924 3616 ? S 15:10 0:00 /usr/local/apache2/bin/httpd -k start
nobody 1296 0.0 1.4 9924 3616 ? S 15:10 0:00 /usr/local/apache2/bin/httpd -k start
nobody 1297 0.0 1.4 9924 3616 ? S 15:10 0:00 /usr/local/apache2/bin/httpd -k start
root 1301 0.0 0.2 3680 684 pts/0 S 15:11 0:00 grep httpd
Launch firefox or mozilla..configure my connection to "No Proxy
http://localhost/, 10.66.1.2"
Put the address "http://localhost/" and firefox says "The connection was refused when attempting to contact
www.google.com". If I put the following address "10.66.1.2" it resulted to a window that says
"You have chosen to open which is a: application/x-httpd.php from
http://10.66.1.2/ what should firefox do with this file: Open or Save to Disk"
Now if I try to put firefox to Manual Proxy Setting with "No Proxy
http://localhost/, 10.66.1.2" and try to put "http://localhost/", I get the message:
--------------------------
The requested URL could not be retrieved
While trying to retrieve the URL:
http://localhosts/
The following error was encountered:
Unable to determine IP address from host name for localhosts
The dnsserver returned:
Name Error: The domain name does not exist.
This means that:
The cache was not able to resolve the hostname presented in the URL.
Check if the address is correct.
Your cache administrator is
admin@ateneo.edu.
Generated Sat, 11 Dec 2004 07:10:20 GMT by proxy3.admu.edu.ph (squid/2.5.STABLE4)
----------------------------
If I put the following address "10.66.1.2" it resulted to a window that says
"You have chosen to open which is a: application/x-httpd.php from
http://10.66.1.2/ what should firefox do with this file: Open or Save to Disk" Same as without proxy setting connection.
Now i'm lost, no apache web!!!..so anyway I went ahead with PHP.
3) Install PHP to hope that it will resolve the problem.
download php-5.0.2.tar.gz
Invoke the following:
# tar -xvzf php-5.0.2.tar.gz
# mv php-5.0.2 /usr/src/php-5.0.2
# mkdir /usr/local/php
# cd /usr/src/php-5.0.2
# ./configure --prefix=/usr/local/php --with-mysql --with-apxs2=/usr/local/apache2/bin/apxs
# make
# make install
# cd /libs
# cp libphp5.so /usr/local/apache2/modules/
Double check the "/usr/local/apache2/conf/httpd.conf" has the following lines:
LoadModule php5_module modules/libphp5.so
Check the "/usr/local/apache2/logs/error_logs" and has an entry:
[notice] Apache/2.0.52 (Unix) PHP/5.0.2 configured -- resuming normal operations
Now to test the installation:
Created a the following:
# gedit phpinfo.php
<?
phpinfo();
?>
then save it at "/var/www/html"
Launch Firefox, done the File > Open File >
Went to "/var/www/html/phpinfo.php" and returned a blank page!!!.
Were did I do wrong ???
I also want to inquire about this problem:
In my 1st installation I manage to "telnet 10.66.1.2:80" and tried to invoke the following:
HEAD / HTTP/1.1
The output of this is that "No Permision" or something along that line.
Now my 2nd Installation when I "telnet 10.66.1.2:80"...I get a reply that "Unknown Host"
I remembered that I have set the following in my 2nd installation. Create the following files in "/etc/profile.d" directory:
#gedit proxy.sh
export http_proxy=http://host.com:port/
export ftp_proxy=http://host.com:port/
export no_proxy=.domain.com
export HTTP_PROXY=http://host.com:port/
export FTP_PROXY=http://host.com:port/
#gedit proxy.csh
setenv http_proxy
http://host.com:port/
setenv ftp_proxy
http://host.com:port/
setenv no_proxy .domain.com
setenv HTTP_PROXY
http://host.com:port/
setenv FTP_PROXY
http://host.com:port/
I want to verify the following:
What will I put in the "export no_proxy=.domain.com" & "setenv no_proxy .domain.com". Is it the static IP Address "10.66.1.2" or the "host name" which is "rsbs" of the machine that I named to when I installed the OS?
Thank you very much for the assistance.