Re: Samba or Apache issue? (solved)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Allen Chen 写道:
m.roth2006@xxxxxxx ??:
Allen,

Date: Thu, 09 Apr 2009 11:31:43 -0500
From: Allen Chen <achen@xxxxxxxxxxxxxxxxxxxxxx>
I have a samba 2.0.22 and a apache 2.2.3 running on a separate RHEL4
machine.
If I change apache DocumentRoot to a mounted samba share, I cannot see
any static pages or files(images,css..) show up in broswer.In global
settings of httpd.conf, if I use EnableMMAP off and EnableSendfile off
options, this only changes apache access_log info from
"GET /mypage/test.html HTTP/1.1" 206 1106
to
"GET /mypage/test.html HTTP/1.1" 200 -

But any php page works fine. It looks like apache doesn't like mounted
samba share. Any idea?

What's the ownership and permissions on the samba share, and are they the same as who apache's running as?

mark

Apache is running as nobody/nobody and all files&folders have nobody/nobody as the ownership. I think there is no permissions issue. Because php page works fine in the same folder. I have worked with samba and apache for 5 yrs. This is my first time to use a mounted samba share as the DocumentRoot. I googled and found it is ralated to the httpd.conf:

#
# EnableMMAP and EnableSendfile: On systems that support it,
# memory-mapping or the sendfile syscall is used to deliver
# files. This usually improves server performance, but must
# be turned off when serving from networked-mounted
# filesystems or if support for these functions is otherwise
# broken on your system.
#
EnableMMAP off
EnableSendfile off

Samba log has no error message.

Has anybody ever used mounted samba share as DocumentRoot for apache?


Allen
just reply to myself.
When I chenge mount option from:
mount -t cifs -o ......
to
mount -t smbfs -o .....
It works perfect. So it is samba mount issue. Can anybody explain this?
or Is cifs too new to use from RHEL4? After a deep dig, I found that
if I mount it with cifs and restart apache and broswer a couple of pages,
some of the files get messed(extra code is appended to the end of the file).
but the original files on samba side are OK.

samba info:
samba server: compiled samba 2.0.22
apache server: samba-client-3.0.10-1.4E(comes with RHEL4 rpm)


cheers,

--
redhat-list mailing list
unsubscribe mailto:redhat-list-request@xxxxxxxxxx?subject=unsubscribe
https://www.redhat.com/mailman/listinfo/redhat-list

[Index of Archives]     [CentOS]     [Kernel Development]     [PAM]     [Fedora Users]     [Red Hat Development]     [Big List of Linux Books]     [Linux Admin]     [Gimp]     [Asterisk PBX]     [Yosemite News]     [Red Hat Crash Utility]


  Powered by Linux