Images not served by apache over a symbolic link folder
a variation of the problem i'm facing has be mentioned before here (however without resolution):
http://www.linuxquestions.org/questi...ic+link+images my setup involves a Centos 5 server and a Windows XP box with images 1. i mount the windows images directory e:\Pics on under /mnt/pics 2. on centos a vhost (www.mysite.org) is setup with the root as /var/www/web3/web 3. i created a symbolic link as Code:
ln -s /mnt/pics /var/www/web3/web/Pics Code:
<Directory /var/www/web3/web> Code:
http://www.mysite.org/Pics there are no permission issues because on the windows share i can access html and txt files just fine. for e.g. Code:
http://www.mysite.org/Pics/letter.txt Code:
http://www.mysite.org/Pics/foo.gif does this look like a mime issue to anyone? or is it just the way the mount was done. the question is why would it serve up non-images fine but fail while returning images.. |
The Solution
with a bit more creative use of keywords i was able to reach this post (surprise, it was again back on linuxquestions.org)
https://www.linuxquestions.org/quest...mlinks-443537/ the problem is with serving all binary files of which i had gotten just a taste with the images not working. the fix therefore was to turn off apache's memory-mapping of files. in the systems that supports this it could form a rather efficient cache by itself. my system won't be serving massive amounts of content but any large scale system should investigate this setting more closely. in /etc/httpd/conf/httpd.conf find the relevant sections as below and uncomment the lines: Code:
# Code:
service httpd restart to know more about why it does what it does you can look at the docs for these obscure attributes at http://httpd.apache.org/docs/2.2/mod...tml#enablemmap Quote:
and there went my entire day . . . |
All times are GMT -5. The time now is 02:17 AM. |