Drahcir
Drahcir

Reputation: 11982

How to find directory being served by Apache

I'm trying to debug someone else's script. They've given me access to the server and a URL, what they didn't tell me is where their scripts are located.

How can I find the directory that serves the URL?

I've already checked in /var/www/ but no luck, people have been messing with the server and Apache is serving pages from many directories.

Upvotes: 5

Views: 11885

Answers (1)

tishma
tishma

Reputation: 1885

I know this is old, but if it is ubuntu, you should look into apache config which probably has not been messed with. It's located in /etc/apache2/apache2.conf

Also, have a look in /etc/apache2/sites-enabled for possible virtual hosts that might be serving it.

You should search for Directory, and that should tell you where the scripts are served from.

Upvotes: 3

Related Questions