Turn on directory listing in Linux

23 views
asked May 20, 2012 in General by chris (500 points)
hi all..
does anyone here know ho to turn on directory listing in Linux? I want to turn on the directory listing in my linux server but I don't known how to. can anyone please help.

thank you

1 Answer

0 like 0 dislike
answered May 20, 2012 by expert (14,380 points)
1.Login to the server via SSH
2.Open the following file in a text editor: vi /etc/httpd/conf/vhosts.conf
3.Locate the virtual host container for the site in question and add the following:
<Directory "/path/to/document/root/subfolder">
</Directory>
4.Save the file and test the Apache configuration with the following command: /etc/init.d/httpd configtest
5.If you get a "Syntax Ok" response, then run this command to restart Apache: /etc/init.d/httpd restart
...