Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Apache htdocs question

Status
Not open for further replies.

AlStl

MIS
Oct 2, 2006
83
0
0
US
I have installed apache 2.2.23 using following instructions:

$ gzip -d httpd-NN.tar.gz
$ tar xvf httpd-NN.tar
$ cd httpd-NN
Configure $ ./configure --prefix=PREFIX
Compile $ make
Install $ make install
Customize $ vi PREFIX/conf/httpd.conf
Test $ PREFIX/bin/apachectl -k start

Apache started just fine, but when I used a browser to bring it up..it says It Works!

I was expecting to see apache interface where documentation links and other graphics. So, this is new to me. I went to look at httpd.conf and saw that: DocumentRoot /appl/apache/htdocs. htdocs has a file called index.html that contains the text it works. So everything is working as it should.

Now, my questions is why i only have index.html in htdocs directory? I remember previous versions used to have bunch of files in this directory including graphics and other html files for documentation etc. Where are all these files located?

Thanks,

Al
 
Hi

What if you access ?

For example my Apache 2.2.23 installed from Frugalware package has the [tt]DocumentRoot[/tt] set to /var/ and the documentation in /var/ but there is an [tt]AliasMatch[/tt] directive making the documentation accessible through the mentioned URL.


Feherke.
[link feherke.github.com/][/url]
 
Feherke, thanks for taking a jab at my question.
BTW I am doing it on Solaris machine.

I tried


and it gave me Not Found "The requested URL /manual/ is not found on this server. Port is set us Listen 10010 in httpd.conf

I do have /appl/apache/manual directory.

Also, I do not see anything under /appl/apache/var/ expect a directory called logs /appl/apache/var/log and it has a file called httpd.pid, which i think is a log file for process ID.

Not sure what is going on here?
 
Hi

Well, I would search the configuration file(s) for the mentioned [tt]AliasMatch[/tt] directive and for that /appl/apache/manual path you mentioned. If found something, check whether those lines are not commented.

If no such directive exists, try to add something like the one I have :
Code:
AliasMatch ^/manual(?:/(?:de|en|fr|ja|ko|ru))?(/.*)?$ "/appl/apache/manual$1"

<Directory "/appl/apache/manual">
    Options Indexes
    AllowOverride None
    Order allow,deny
    Allow from all

    <Files *.html>
        SetHandler type-map
    </Files>

    SetEnvIf Request_URI ^/manual/de/ prefer-language=de
    SetEnvIf Request_URI ^/manual/en/ prefer-language=en
    SetEnvIf Request_URI ^/manual/fr/ prefer-language=fr
    SetEnvIf Request_URI ^/manual/ja/ prefer-language=ja
    SetEnvIf Request_URI ^/manual/ko/ prefer-language=ko
    SetEnvIf Request_URI ^/manual/ru/ prefer-language=ru
    RedirectMatch 301 ^/manual(?:/(de|en|fr|ja|ko|ru)){2,}(/.*)?$ /manual/$1$2
</Directory>
And of course, restart Apache after modifying the configuration.


Feherke.
[link feherke.github.com/][/url]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top