These emits occur mainline, outside of the pphrase_callback, so we never
opened readtty or writetty. But they are absolute failures, nothing the
user could do to deal with them. They are logged in the ssl vhost's error
log.
In this case, I forgot my SSLCertificateKeyFile, so the server never
tried the callback. writetty wasn't initialized, so we segfaulted.
This segfault is due to misconfig, not to the dialog with the user.
This is the easiest fix (easier to read, too), but we shouldn't need
to worry too much that the release is tagged. If we retag, fine, then
grab it, but it only addresses a config problem.
Rewrite ap_get_client_block to rely on assumptions that have been
solidified after this code was originally written. Namely:
- AP_MODE_READBYTES will only return a brigade representing AT MOST bytes
of data. It can NOT return MORE than requested.
- APR_BLOCK_READ is respected - it is considered a design error of a filter
if it returns without reading something.
- apr_brigade_flatten is available to do the heavy lifting of the copying
into a flat buffer (as hinted at by the removed comment).
Brian Pane [Sun, 16 Jun 2002 22:55:11 +0000 (22:55 +0000)]
More changes to bring the performance tuning guide closer to compatibility
with httpd-2.0:
- Updated the sample system call trace with a 2.0/worker example
- Removed the section on the preforking model
Formating, whitespace, following {} rules, 80 char lines, etc. The only
significant variation from the general Apache rules is the construct:
switch ()
{
case foo:
case_fns();
}
indentation, since win32 switches are very common, but it's impossible
to follow that rule and maintain legible 80 character line limits. This
is a common enough exception that I don't expect vocal objections.
Ryan Bloom [Sun, 16 Jun 2002 15:14:41 +0000 (15:14 +0000)]
First pass at cleaning up htpasswd. This removes the tmpnam call in
favor of apr_file_mktemp. This also APR-izes most of the code. The
file access code is still not using APR, but that will be fixed next.
I also re-organized some of the code to make it a little cleaner, and
to use functions where I could.
Rich Bowen [Sun, 16 Jun 2002 12:17:18 +0000 (12:17 +0000)]
There's already a program distributed with Apache that does this.
Thanks, Joshua, for pointing this out. Do folks with binary
distributions (RPM or whatever) get this program installed somewhere
accessible?
For debug builds, toss the .pdb's alongside the binaries for debugging
in the install tree [note: you still need some sources handy, at least
this solves the 80/20 headache.]
David Reid [Sat, 15 Jun 2002 21:48:53 +0000 (21:48 +0000)]
Fix the build on BSDi machines. The bsd_makefile trick didn't completely
work as autoconf may run config.status and remove the fixes we've just
applied, so this allows us to workaround that problem.
Initailly suggested by Cliff, this is a modified version.
Rich Bowen [Sat, 15 Jun 2002 20:11:41 +0000 (20:11 +0000)]
A little clarification of the command line which is to be typed. People
seem to like to have an example of EXACTLY what they are supposed to
type.
Also, added a "subtitle" for the File Descriptor Limits page, to reflect
some of the material that I just added to it.
Rich Bowen [Sat, 15 Jun 2002 20:09:08 +0000 (20:09 +0000)]
Added configuration example, code example, and a little explanation, to
facilitate logging all of your virtual hosts to a single file, and then
splitting them back up after. Note that if Apache has problems with this
many file handles, Perl might also. I'm not sure.
Rich Bowen [Sat, 15 Jun 2002 11:43:11 +0000 (11:43 +0000)]
Not to pick nits, but I think that the "add this back in" phrasing will
confuse people, and leave them unsure what they are actually supposed to
do, in the unlikely event that they want to turn this back on. Made it a
little clearer what they actually need to do. Tested.
Ryan Bloom [Sat, 15 Jun 2002 07:20:59 +0000 (07:20 +0000)]
We must set the MIME-type for .shtml files to text/html if we want them
to be parsed for SSI tags. Add the config for that to the default
config file so that it is easier to enable .shtml parsing.
PR: 9787
Submitted by: Dave Dyer <ddyer@real-me.net>
Ryan Bloom [Sat, 15 Jun 2002 07:01:25 +0000 (07:01 +0000)]
Comment out the SERVER_STRING variable from our default error documents.
Some people do not like having this information in their error pages, and
it makes sense to not do it by default. If users want this back, they
can uncomment it.
Ryan Bloom [Sat, 15 Jun 2002 05:49:06 +0000 (05:49 +0000)]
Make the default_handler catch all requests that aren't served by
another handler. This also gets us to return a 404 if a directory
is requested, there is no DirectoryIndex, and mod_autoindex isn't
loaded.
Ryan Bloom [Sat, 15 Jun 2002 04:41:52 +0000 (04:41 +0000)]
Allow 'make install DESTDIR=/path'. This allows packagers to install
into a directory different from the one that was configured. This
also mirrors the root= feature from 1.3. We cannot use prefix=,
because both APR and APR-util resolve their installation paths at
configuration time. This means that there is no variable prefix
to replace.
PR: 7803
Submitted by: Andreas Hasenack <andreas@netbank.com.br>
Jeff Trawick [Fri, 14 Jun 2002 03:11:43 +0000 (03:11 +0000)]
prefork MPM: Ignore mutex errors during graceful restart. For
certain types of mutexes (particularly SysV semaphores), we
should expect to occasionally fail to obtain or release the
mutex during restart processing.
These mutex failures seem to be a pretty rare occurrence, but
it was fatal.
Joshua Slive [Fri, 14 Jun 2002 02:31:01 +0000 (02:31 +0000)]
Remove some directive docs from mpm_netware and point them at mpm_common, plus
update the mpm_common docs to deal with multiple meanings for the same directives.
In the future, it would be a wise idea not to use the same directive name as
another MPM unless the directive really does exactly the same thing in both
MPMs.
Cliff Woolley [Thu, 13 Jun 2002 21:10:39 +0000 (21:10 +0000)]
This has magically gone away, and prefork's graceful now passes my
torture test.
Things I changed:
1) make extraclean and rebuild after cvs up (it was not *that* old though)
2) removed mod_pop3, mod_ldap, mod_auth_ldap, and mod_php4
Jeff Trawick [Thu, 13 Jun 2002 18:46:28 +0000 (18:46 +0000)]
Fix install-bindist.sh so that it finds any perl instead of just
early perl 5.x versions. This is consistent with a build/install
from source, and it allows the perl scripts installed by a bindist
to work on systems with perl 5.6.
Bradley Nicholes [Thu, 13 Jun 2002 18:39:04 +0000 (18:39 +0000)]
Enabled Server-Side Includes by default in the /manual directory so that all
headers and footers will be included correctly in the documentation pages.
Add a note on the overall problem with HEAD requests generating wrong headers.
Again, I believe this is a showstopper, but no one seems to agree with me.
Point at patch for 500/501 problem - I don't plan on testing or committing it.
Per RFC 2616 section 9.4, we SHOULD return the content-length if possible on
HEAD requests (even for CGI requests). Also do it because it fixes the cause
of .37's demise.
This also fixes a condition seen on FreeBSD-4.6 where HEAD requests on CGI
scripts would hang because the OS would return EAGAIN in log_script_err
(via apr_file_gets). Since we never read the script output, this caused
FreeBSD to not let us read stderr.
Rich Bowen [Thu, 13 Jun 2002 01:07:09 +0000 (01:07 +0000)]
Added example of Using * as argument to NameVirtualHost. Added note that
arg to NameVirtualHost is supposed to match the arg to VirtualHost, as
this seems to come up several times a week on #apache
Solve the 80/20 by initializing and storing server_rec->timeout and
server_rec->keep_alive_timeout in apr_time_interval_t format (in apr
units, whatever they be), as both values exist to pass into APR, and
all APR timeouts are in apr_time_t.