How To Install Apache Server on your Unix Account
Following are steps to install Apachee Server in your area and you get the chance to become your own server administrator
Step 1: visit http://www.apache.org/
Step 2: Click on Apache Server (seventh item from the left).
Step 3: Click on Download.
Step 4: Click on apache_1.3.28.tar.z this the 12th item from the left and it is for Unix. Remember the place where you saved it on your PC. For the sake of explanation assume that you saved it on the desk_top. Thus on your desk_top now you have apache_1.3.28.tar.z . Notice z tells that the file is zipped and tar tells that the file is an archieve file contains more than one file.
Step 5: log in into your Unix account.
Step 6: type the following two commands to create apache directory and to make it to be the current working directory
Step 7: Use an FTP facility such as CuteFTP 32 or lite Ftp to transfer apache_1.3.28.tar.z from the desk_top to your directory in Unix. To achieve that do the following items:
a. click on the FTP facility
b. Login into your Unix account on FTP,.
c. Click on apache directory in your home directory (in FTp).
d. Click on C: then click on WINDOWS, click on desk_top, click on apache_1.3.28.tar.z on some FTP
facilities you also have to click on -->> to transfer it from desk top to your account. Now you have
apache_1.3.28.tar.z in apache directory on your home directory. Close the FTP facility.
Step 8: Make sure you are at apache directory by typing pwd command. If you are not at apache directory type
command cd apache.
Step 9: To unzip the file issue the command
Now the file is unzipped and if you type ls command you see you have only apache_1.3.28.tar file in apache
Step 10: To extract files from apache_1.3.28.tar type the following command:
tar xvf apache_1.3.28.tar
Notice xvf are options to tar command.
Step 11: Since files are extracted from apache_1.3.28.tar, now delete apache_1.3.28.tar file by typing:
Step 12: type the following command
Change directory to Apache_1.3.28 by executing
Notice replace USERDIR by your home director. Thus this command for user ks6241 will be:
Step 13: Type the command
Step 14: Type the command
Step 14a: Type the command - this will save you a significant amount of disk space!
Step 15: Edit apache/conf/httpd.conf by using an editor such as pico or vi. Assume that we use pico editor, then type
make the following changes while you are at pico:
Listen 3000 Notice any port number above 1000 will be fine.
Now make the following changes:
If you done every right the following message. Notice the installation takes approximately 40 minutes.
| You now have successfully built and installed the
| Apache 1.3 HTTP server. To verify that Apache actually
| works correctly you now should first check the
| (initially created or preserved) configuration files
| and then you should be able to immediately fire up
| Apache the first time by running:
| /usr/users/cis/khailany/apache/bin/apachectl start
| Thanks for using Apache. The Apache Group
After installing apache server you have to make the following changes
1. Edit 'httpd.conf' file. Assuming that you are at your home directory.
use other path if you 'httpd.conf' is in another directory
Notice in pico control c tells in which line the editor is.
2. Comment "Listen" by using '#', since "Listen" is not being used
3. Find value "Port" (line 236) and make sure it is uncommented. The default value is '8080' which is the EMU unix web server, and therefore can not be used. Change that value to a UNIQUE value that is specific to you server.
Notice to find all port numbers which are used type the command:
4. Find values "User" and "Group" (line 250). Change them to your own username and group.
5. Make sure that "world" can access your apache/htdocs directory which is root directory for html web pages. In other words change the protections of apache/htdocs by typing chmod 755 apache/htdocs
6. The default cgi-bin directory is apache/cgi-bin. To change it go to line# 535 and change the value of the directory here and couple of line below to the one that you want to be your cgi-bin.
7. Close pico
8. If your apache server is running stop it by typing
9. Restart apache by typing
Notice: If someone using your server you may not want to stop it immediately. In such cases use gracefull
command by typing