)]}'
{"lib/apache":[{"author":{"_account_id":7118,"name":"Ian Wienand","email":"iwienand@redhat.com","username":"iwienand"},"change_message_id":"36b3d77fdbd3fa593522589bc65ae7a44235678d","unresolved":false,"context_lines":[{"line_number":150,"context_line":""},{"line_number":151,"context_line":"# restart_apache_server"},{"line_number":152,"context_line":"function restart_apache_server {"},{"line_number":153,"context_line":"    # Apache can be slow to stop, doing an explicit stop, sleep, start helps"},{"line_number":154,"context_line":"    # to mitigate issues where apache will claim a port it\u0027s listening on is"},{"line_number":155,"context_line":"    # still in use and fail to start."},{"line_number":156,"context_line":"    stop_service $APACHE_NAME"}],"source_content_type":"application/octet-stream","patch_set":1,"id":"baada198_59c5ed08","line":153,"updated":"2014-07-16 04:23:13.000000000","message":"this seem fragile; let\u0027s just use \"service httpd restart\" and let the init scripts do the right thing.   rhel/fedora service files already seem to have some logic in them for graceful restart \u0026 timeout","commit_id":"2df0046fa759481f793d9c51563728b21c7858d8"},{"author":{"_account_id":2903,"name":"Morgan Fainberg","email":"morgan.fainberg@gmail.com","username":"mdrnstm"},"change_message_id":"186e2e88035019c5809450bb714c2cdcf71c9f9c","unresolved":false,"context_lines":[{"line_number":150,"context_line":""},{"line_number":151,"context_line":"# restart_apache_server"},{"line_number":152,"context_line":"function restart_apache_server {"},{"line_number":153,"context_line":"    # Apache can be slow to stop, doing an explicit stop, sleep, start helps"},{"line_number":154,"context_line":"    # to mitigate issues where apache will claim a port it\u0027s listening on is"},{"line_number":155,"context_line":"    # still in use and fail to start."},{"line_number":156,"context_line":"    stop_service $APACHE_NAME"}],"source_content_type":"application/octet-stream","patch_set":1,"id":"baada198_e46538e3","line":153,"in_reply_to":"baada198_59c5ed08","updated":"2014-07-16 04:54:58.000000000","message":"The issue is that restart via either init scripts or apachectl, etc is fragile. The init scripts often do the wrong things. I\u0027ve seen this across many distributions (fedora included), it is more prevalent in cases where you are running applications under the direction of Apache.\n\nThe real issue is that as soon as the \"stop\" finishes the \"start\" is tried via the init scripts (or apachectl, etc) and the port is still in use, this causes the start to fail.\n\nThis issue isn\u0027t extremely common, but when you have as many devstacks start up as we do in a given day, it doesn\u0027t take much to start showing up.\n\nI\u0027m happy to expand this comment if that would make it more clear.","commit_id":"2df0046fa759481f793d9c51563728b21c7858d8"},{"author":{"_account_id":2903,"name":"Morgan Fainberg","email":"morgan.fainberg@gmail.com","username":"mdrnstm"},"change_message_id":"0f8bbb8c35ff7c1a25a7470d19d69034d231f392","unresolved":false,"context_lines":[{"line_number":154,"context_line":"    # to mitigate issues where apache will claim a port it\u0027s listening on is"},{"line_number":155,"context_line":"    # still in use and fail to start."},{"line_number":156,"context_line":"    stop_service $APACHE_NAME"},{"line_number":157,"context_line":"    sleep 3"},{"line_number":158,"context_line":"    start_service $APACHE_NAME"},{"line_number":159,"context_line":"}"},{"line_number":160,"context_line":""}],"source_content_type":"application/octet-stream","patch_set":1,"id":"baada198_a480a0f8","line":157,"updated":"2014-07-16 05:07:47.000000000","message":"A sleep 1 or 2 might be sufficient to catch 95+% of the cases this is actually hit.","commit_id":"2df0046fa759481f793d9c51563728b21c7858d8"},{"author":{"_account_id":7118,"name":"Ian Wienand","email":"iwienand@redhat.com","username":"iwienand"},"change_message_id":"fc96e1bcdefa544eb53a50bacb56147fa120dd21","unresolved":false,"context_lines":[{"line_number":154,"context_line":"    # to mitigate issues where apache will claim a port it\u0027s listening on is"},{"line_number":155,"context_line":"    # still in use and fail to start."},{"line_number":156,"context_line":"    stop_service $APACHE_NAME"},{"line_number":157,"context_line":"    sleep 3"},{"line_number":158,"context_line":"    start_service $APACHE_NAME"},{"line_number":159,"context_line":"}"},{"line_number":160,"context_line":""}],"source_content_type":"application/octet-stream","patch_set":1,"id":"baada198_a4aee07f","line":157,"in_reply_to":"baada198_a480a0f8","updated":"2014-07-16 05:16:00.000000000","message":"If \"service httpd restart\" isn\u0027t restarting properly, then it\u0027s broken and a serious upstream bug.  What\u0027s the point of restart if it doesn\u0027t work?  :)\n\nI can\u0027t replicate this (although all I did was a loop for a while on a small rhel vm) but if this is seen on Fedora/RHEL/CentOS I will volunteer to file a bug and chase it up.  I couldn\u0027t see any linked failures in the attached bug but i\u0027m happy to have details\n\nI would only like to see this as a workaround for a specific known broken platform (gate by if is_[fedora|ubunut|etc]) and with a comment pointing to the upstream bug of why it doesn\u0027t work","commit_id":"2df0046fa759481f793d9c51563728b21c7858d8"},{"author":{"_account_id":2903,"name":"Morgan Fainberg","email":"morgan.fainberg@gmail.com","username":"mdrnstm"},"change_message_id":"7211d413baa220b4e58409356553af8f2edd2501","unresolved":false,"context_lines":[{"line_number":154,"context_line":"    # to mitigate issues where apache will claim a port it\u0027s listening on is"},{"line_number":155,"context_line":"    # still in use and fail to start."},{"line_number":156,"context_line":"    stop_service $APACHE_NAME"},{"line_number":157,"context_line":"    sleep 3"},{"line_number":158,"context_line":"    start_service $APACHE_NAME"},{"line_number":159,"context_line":"}"},{"line_number":160,"context_line":""}],"source_content_type":"application/octet-stream","patch_set":1,"id":"baada198_f4479175","line":157,"in_reply_to":"baada198_a4aee07f","updated":"2014-07-16 13:52:16.000000000","message":"This is a long standing issue and isn\u0027t really a *serious* upstream bug. It affects a minority of cases. And most operational software (cms, etc) have worked around this by ensuring apache starts even if a restart fails. Sometimes a rapid stop (which most init scripts will claim has completed) will immediately issue a start, which if a resource (in this case the port) hasn\u0027t been freed completely, the start fails even thought anyone inspecting the system would be confused as to why.\n\nHere is an example of the error case:\n\nhttp://logs.openstack.org/25/102425/5/check/check-devstack-dsvm-cells/9991da4/logs/devstacklog.txt.gz#_2014-07-13_00_50_53_921\n\nNothing has changed in the restart case but if you look at the next set of tempest runs after the recheck against the bug this fixes, everything passes. https://review.openstack.org/#/c/102425/\n\nThis is a fairly uncommon edge case, but uncommon edge cases occur and cause noticeable failures for us just strictly due to volume. It takes one slow VM to release the resources and we\u0027ll see an occasional check or gate failure.\n\nThis issue has been documented in the apache wiki, though it appears apachectl restart avoids this issue (according to the wiki).\n\nI\u0027ll circle back later and change the apache restart from *init* to apachectl which should also resolve the issue without requiring an explicit sleep (as documented in the apache httpd wiki): https://wiki.apache.org/httpd/CouldNotBindToAddress (the message is slightly different due to newer versions of apache). Init scripts don\u0027t just wrap `apachectl restart`, they do a stop/start.","commit_id":"2df0046fa759481f793d9c51563728b21c7858d8"},{"author":{"_account_id":2903,"name":"Morgan Fainberg","email":"morgan.fainberg@gmail.com","username":"mdrnstm"},"change_message_id":"850a82e62a78564b88e349163db8fb2c7d24d77f","unresolved":false,"context_lines":[{"line_number":154,"context_line":"    # to mitigate issues where apache will claim a port it\u0027s listening on is"},{"line_number":155,"context_line":"    # still in use and fail to start."},{"line_number":156,"context_line":"    stop_service $APACHE_NAME"},{"line_number":157,"context_line":"    sleep 3"},{"line_number":158,"context_line":"    start_service $APACHE_NAME"},{"line_number":159,"context_line":"}"},{"line_number":160,"context_line":""}],"source_content_type":"application/octet-stream","patch_set":1,"id":"baada198_e6536437","line":157,"in_reply_to":"baada198_f4479175","updated":"2014-07-16 15:36:21.000000000","message":"By later, i mean in the next patch I\u0027ll update it.","commit_id":"2df0046fa759481f793d9c51563728b21c7858d8"},{"author":{"_account_id":7118,"name":"Ian Wienand","email":"iwienand@redhat.com","username":"iwienand"},"change_message_id":"4657f563d1fd0a3b18eabd09bbc543dcf859fe10","unresolved":false,"context_lines":[{"line_number":154,"context_line":"    # to mitigate issues where apache will claim a port it\u0027s listening on is"},{"line_number":155,"context_line":"    # still in use and fail to start."},{"line_number":156,"context_line":"    stop_service $APACHE_NAME"},{"line_number":157,"context_line":"    sleep 3"},{"line_number":158,"context_line":"    start_service $APACHE_NAME"},{"line_number":159,"context_line":"}"},{"line_number":160,"context_line":""}],"source_content_type":"application/octet-stream","patch_set":1,"id":"baada198_e6527267","line":157,"in_reply_to":"baada198_f4479175","updated":"2014-07-17 00:15:56.000000000","message":"Please leave \"is_fedora\" using the system init scripts.  rhel seems to have a 10-second timeout before issuing a sigkill, and systemd should be watching the process.  If these aren\u0027t working we want to know\n\nIf this is a workaround for ubuntu, OK -- but it should be tagged with a comment to an upstream bug.","commit_id":"2df0046fa759481f793d9c51563728b21c7858d8"}]}
