Linux - ServerThis forum is for the discussion of Linux Software used in a server related context.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I'm trying to build Apache 2.2.21 from source on Ubuntu server 11.04. I have succeeded and run it, but found that suexec is failing because it's trying to open logs where it cannot. So back to the build configuration.
--with-suexec-logfile=FILE
This defines the filename to which all suEXEC transactions and errors are logged (useful for auditing and debugging purposes). By default the logfile is named "suexec_log" and located in your standard logfile directory (--logfiledir).
There appears to be no such configure option according to document http://httpd.apache.org/docs/2.2/pro...configure.html but I went ahead and tried it, anyway, just in case they overlooked something (has happened before). But it failed to finish the "./configure" step saying the option was not recognized.
So, how can I get the logs to be directed to the proper directory?
They are trying to go to "/opt/logs" (because --prefix=/opt) but I want the logs to go to /var/log/httpd. The access_log and error_log do go there by way of being specified in httpd.conf. However, suexec is not doing this and doesn't get this info from httpd.conf anyway (has to be compiled in for security and/or performance reasons, presumably).
There appears to be no such configure option according to document http://httpd.apache.org/docs/2.2/pro...configure.html but I went ahead and tried it, anyway, just in case they overlooked something (has happened before). But it failed to finish the "./configure" step saying the option was not recognized.
Are you sure?
Just for testing, I compiled apache 2.2.21 using the following config.nice, without a hitch
So it accepts a full path instead of just a name? They need to update the documentation, then.
It can accept both.
From apache documentation:
Quote:
--with-suexec-logfile=FILE
This defines the filename to which all suEXEC transactions and errors are logged (useful for auditing and debugging purposes). By default the logfile is named "suexec_log" and located in your standard logfile directory (--logfiledir).
This is half-correct as it states that by default the log file "suexec_log" is created under the logfile directory (if you don't use the --with-suexec-logfile option), which is true.
But if you use "--with-suexec-logfile=FILE" omitting the absolute path to the logfile, then it will be created in the directory from where you are trying to run your scripts. I.e. for a URL like http://host/cgi-bin/foo.cgi, it will be created into the cgi-bin directory, for http://host/whatever/foo.php, that will be in /<docroot>/whatever/ and so on. And you'll end up with various suexec logs in various places!!!
That is why it's better to give the full path to the logfile.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.