0

I run a webpage on CentOS 6.6 by using Apache 2.4.10. My documentroot is /var/www/htdocs. Last month, because my disk became full, I added another disk in /disk1. I want to place large movie files in this directory and want visitors of my website to watch the videos. However, when I tried to make symbolic links from /var/www/htdocs/movies to /disk1/movies, I failed. How can I make symbolic links on Apache? Is there another good way to realize what I want to do?

junao
  • 3
  • 1
  • Could you add the command you ran and the error you got , to the question ? – Roshith Dec 08 '14 at 07:37
  • "ln -s /disk1/movies/movie1.wav /var/www/htdocs/movies/movie1.wav" and the error_log says, "Symbolic link not allowed". – junao Dec 08 '14 at 18:21
  • Have you set the 'FollowSymLinks' Option in httpd.conf ? Does you apache user has rx permission for the symlink target dir path. – Roshith Dec 09 '14 at 08:04
  • Oh... I misconfigured FollowSymlinks in httpd.conf... Now it works. Is it better to configure in each .htaccess file? – junao Dec 11 '14 at 08:24
  • You should configure it in httpd.conf , if you don't have access to it , update .htaccess. – Roshith Dec 11 '14 at 09:57
  • Thank you so much! I did not now which I should modify httpd.cond or .htaccess. – junao Dec 12 '14 at 16:45
  • No probs ,happy learning! Please accept the answer to close the question if it helped. – Roshith Dec 13 '14 at 05:02

1 Answers1

0

Make sure you have you set the 'FollowSymLinks' Option in httpd.conf and your apache user has rx permission for the symlink target dir path.

Roshith
  • 2,116
  • 13
  • 21