Tom's Guide | Tom's Hardware | Tom's Games
![]() |
![]() |
![]() |
I installed red hat 9 as a workstation, i then added the apache web server to it, so i can make .jsp applications. I can not seem to find the apache directory?? where would i put the sample .jsp files i make to see them work? Its running find and i get its default page telling me its installed succesfully. the page has this message in it also;
You may now add content to this directory, and replace this page. Note that until you do so, people visiting your website will see this page, and not your content.
what directory is it talking about??
I made a simple .jsp file that shows the date, this file was made by a logged in user, not as root, the jave code in it is <%= java.util.Date() %> along with the html tags and the "hello world" message. were do i put these files?

the problem is, there is no apache dir anywhere!!!!!!!!!! not in usr/local/, no where, but i find the default.html pages dir, the page to confirm that your server was set up correctly. Then i found the dir that contains the dirs cg-bin error www and a couple more directories, i believe the default html page was in the error dir. When i run my .jsp page with a simple <%= new java.util.Date() %> it does not print the date, it prints the statement?

Did you compile the Apache yourself or did you use Redhat and install it through one of there RPM's? I am assuming you let Redhat do it, because if you would have done it you would have had to select where you place the directory. I have not used Redhat, When I let Suse install it they installed it in several places. You might need to hit there web site or read the manual to see where they would have put the Apache Directory.

The location of the directory is kept in httpd.conf (the apache confi file) as well as the location of any script directories.
$ grep -i documentroot `find / -name httpd.conf`
or a quicker way if your locate database is up to date:
$ grep -i documentroot `locate httpd.conf`Mine is /var/www/htdocs.

um.. i may be wrong but i seem to remember
apache defaulting to /var/www/html for the
directory to put your content once you got
it up and running. try making a sample
index.html, save it in /var/www/html and
then refresh in a browser http://your ip
address or vhost name/index.html and you
SHOULD see the index.html file you just
saved in /var/www/html
Also, if the orginal poster happens to be a
linux newbie and is not already using
webmin, i highly reccomend checking it out.
It makes the setup of apache a lot easier
to deal with for someone new to linux.

Configuration file directory:
/etc/httpd/conf/httpd.confDocumentRoot:
/var/www/htdocsThis is confirmed as I have my Red Hat 9 isntalled with Apache 2.0.46 (RPM with the CD).
Ben,
Pentium 4 1.7GHz, 256 Cache
512 DDR RAM PC2700
ATI Radeon 9200SE 128 DDR RAM
Western Digital 80GB 7200 RPM

![]() |
![]() |
![]() |

This post is quite old and has been locked from receiving new replies. Please create a new posting instead.
| Ads by Google |