home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
PC World 2004 May
/
PCWorld_2004-05_cd.bin
/
komunikace
/
apache
/
apache_2.0.48-win32-x86-no_ssl.msi
/
Data.Cab
/
F252272_stopping.xml.ko
< prev
next >
Wrap
Extensible Markup Language
|
2003-05-10
|
8KB
|
186 lines
<?xml version='1.0' encoding='EUC-KR' ?>
<!DOCTYPE manualpage SYSTEM "./style/manualpage.dtd">
<?xml-stylesheet type="text/xsl" href="./style/manual.ko.xsl"?>
<!-- English revision: 1.2.2.6 -->
<manualpage metafile="stopping.xml.meta">
<title>┴▀┤▄░· └τ╜├└█</title>
<summary>
<p>└╠ ╣«╝¡┤┬ └»┤╨╜║╖∙ ╜├╜║┼█┐í╝¡ ╛╞╞──í╕ª ┴▀┤▄╟╧░φ └τ╜├└█╟╧┤┬
│╗┐δ└╗ ┤π░φ└╓┤┘. └⌐╡╡┐∞┴ε NT, 2000, XP ╗τ┐δ└┌┤┬ <a
href="platform/windows.html#winsvc">╝¡║±╜║╖╬ ╛╞╞──í
╜╟╟α╟╧▒Γ</a>┐í╝¡, └⌐╡╡┐∞┴ε 9x┐═ ME ╗τ┐δ└┌┤┬ <a
href="platform/windows.html#wincons">─▌╝╓ ╟┴╖╬▒╫╖Ñ└╕╖╬
╛╞╞──í ╜╟╟α╟╧▒Γ</a>┐í╝¡ ╟├╖í╞√║░ ╛╞╞──í ┴╢└█╣²└╗ ╛╦ ╝÷ └╓┤┘.</p>
</summary>
<seealso><a href="programs/httpd.html">httpd</a></seealso>
<seealso><a href="programs/apachectl.html">apachectl</a></seealso>
<section id="introduction"><title>╝╥░│</title>
<p>╛╞╞──í╕ª ┴▀┤▄╟╧░φ └τ╜├└█╟╧╖┴╕Θ ╜╟╟α╟╧░φ └╓┤┬
<code>httpd</code> ╟┴╖╬╝╝╜║┐í ╜├▒╫│╬└╗ ║╕│╗╛▀ ╟╤┤┘. ╜├▒╫│╬└╗
║╕│╗┤┬ ╣µ╣²└║ ╡╬░í┴÷┤┘. ╟╧│¬┤┬ └»┤╨╜║ <code>kill</code>
╕φ╖╔╛ε╕ª ╗τ┐δ╟╧┐⌐ ╟┴╖╬╝╝╜║┐í ┴≈┴ó ╜├▒╫│╬└╗ ║╕│╗┤┬ ╣µ╣²└╠┤┘.
╜├╜║┼█┐í ╕╣└║ <code>httpd</code>░í ╜╟╟α╡╟┴÷╕╕, <directive
module="mpm_common">PidFile</directive>┐í pid░í ▒Γ╖╧╡╚ ║╬╕≡┐▄┐í
┤┘╕Ñ ╟┴╖╬╝╝╜║┐í ╜├▒╫│╬(signal)└╗ ║╕│╗╕Θ ╛╚╡╚┤┘. ┴∩, ║╬╕≡└╠┐▄┐í
┤┘╕Ñ ╟┴╖╬╝╝╜║┐í ╜├▒╫│╬└╗ ║╕│╛ ╟╩┐Σ░í ╛°┤┘┤┬ ╕╗└╠┤┘. ║╬╕≡┐í░╘
║╕│╛ ╝÷ └╓┤┬ ╜├▒╫│╬└║ ╝╝░í┴÷╖╬, └╠┴ª ╝│╕φ╟╥ <code><a
href="#term">TERM</a></code>, <code><a
href="#hup">HUP</a></code>, <code><a
href="#graceful">USR1</a></code>└╠┤┘.</p>
<p>┤┘└╜░· ░░└╠ ║╬╕≡┐í░╘ ╜├▒╫│╬└╗ ║╕│╜┤┘:</p>
<example>kill -TERM `cat /usr/local/apache2/logs/httpd.pid`</example>
<p><code>httpd</code> ╟┴╖╬╝╝╜║┐í░╘ ╜├▒╫│╬└╗ ║╕│╗┤┬ ┤┘╕Ñ ╣µ╣²└║
╕φ╖╔╟α ┐╔╝╟ <code>-k</code>╕ª ╗τ┐δ╟╧┤┬ ░═└╠┤┘. ╛╞╖í╝¡ ╝│╕φ╟╥
<code>stop</code>, <code>restart</code>, <code>graceful</code>└║
<a href="programs/httpd.html">httpd</a> ╜╟╟α╞─└╧└╟ ╛╞▒╘╕╒╞«╡Θ└╠┤┘.
▒╫╖»│¬ └╠ ╛╞▒╘╕╒╞«╡Θ╖╬ <code>httpd</code>╕ª ╜╟╟α╟╧┤┬, <a
href="programs/apachectl.html">apachectl</a> ╜║┼⌐╕│╞«╕ª
╗τ┐δ╟╧▒µ ▒╟╟╤┤┘.</p>
<p><code>httpd</code>┐í ╜├▒╫│╬└╗ ║╕│╜╚─, ┤┘└╜ ╕φ╖╔╛ε╖╬
┴°╟α╗≤╚▓└╗ ╛╦ ╝÷ └╓┤┘:</p>
<example>tail -f /usr/local/apache2/logs/error_log</example>
<p>└º ┐╣╕ª ┤τ╜┼└╟ <directive
module="core">ServerRoot</directive>┐═ <directive
module="mpm_common">PidFile</directive> ╝│┴ñ┐í ╛╦╕┬░╘ ╝÷┴ñ╟╧╢≤.</p>
</section>
<section id="term"><title>┤τ└σ ┴▀┤▄</title>
<dl><dt>╜├▒╫│╬: TERM</dt>
<dd><code>apachectl -k stop</code></dd>
</dl>
<p><code>TERM</code>└╠│¬ <code>stop</code> ╜├▒╫│╬└╗ ║╬╕≡┐í░╘
║╕│╗╕Θ ┴∩╜├ ╕≡╡τ └┌╜─└╗ ┴╫└╬┤┘. └┌╜─└╗ ┐╧└ⁿ╚≈ ┴╫└╠┤┬╡Ñ┤┬
╕ε ├╩░í ░╔╕▒ ╝÷ └╓┤┘. ▒╫╖▒╚─ ║╬╕≡░í ┴╛╖ß╟╤┤┘. ├│╕«┴▀└╬ ┐Σ├╗└║
┴▀┤▄╡╟░φ, ┤⌡ └╠╗≤ ┐Σ├╗└╗ ╣▐┴÷╛╩┤┬┤┘.</p>
</section>
<section id="graceful"><title>┴í└▌└║ └τ╜├└█</title>
<dl><dt>╜├▒╫│╬: USR1</dt>
<dd><code>apachectl -k graceful</code></dd>
</dl>
<p><code>USR1</code>└╠│¬ <code>graceful</code> ╜├▒╫│╬└╗
║╬╕≡┐í░╘ ║╕│╗╕Θ ║╬╕≡ ╟┴╖╬╝╝╜║┤┬ └┌╜─╡Θ┐í░╘ ╟÷└τ ┐Σ├╗└╗
├│╕«╟╤╚─ ┴╛╖ß╟╧╢≤░φ (╚ñ└║ ╟÷└τ ╛╞╣½░═╡╡ ├│╕«╟╧┴÷ ╛╩┤┘╕Θ
┴∩╜├ ┴╛╖ß╟╧╢≤░φ) <em>┴╢╛≡╟╤┤┘</em>. ║╬╕≡┤┬ ╝│┴ñ╞─└╧└╗
┤┘╜├└╨░φ ╖╬▒╫╞─└╧╡╡ ┤┘╜├ ┐¼┤┘. └┌╜─└╠ ┴╫└╗╢º╕╢┤┘ ║╬╕≡┤┬
┴╫└║ └┌╜─┤δ╜┼ ╗⌡╖╬┐ε ╝│┴ñ <em>╝╝┤δ</em>┐í ▒Γ├╩╟╤ └┌╜─└╗
╜╟╟α╟╧┐⌐ ┴∩╜├ ┐Σ├╗└╗ ├│╕«╟╧░╘ ╟╤┤┘.</p>
<note>┴í└▌└║ └τ╜├└█(graceful restart)└╕╖╬ <code>USR1</code>└╗
╗τ┐δ╟╥ ╝÷ ╛°┤┬ ╟├╖í╞√┐í╝¡┤┬ ┤δ╜┼ (<code>WINCH</code>┐═ ░░└║)
┤┘╕Ñ ╜├▒╫│╬└╗ ╗τ┐δ╟╥ ╝÷ └╓┤┘. <code>apachectl graceful</code>└║
╟├╖í╞√┐í ╛╦╕┬└║ ╜├▒╫│╬└╗ ║╕│╜┤┘.</note>
<p>┴í└▌└║ └τ╜├└█└║ ╟╫╗≤ MPM└╟ ╟┴╖╬╝╝╜║ ┴╢└² ┴÷╜├╛ε ╝│┴ñ└╗
░φ╖┴╟╧┐⌐, └τ╜├└█╡┐╛╚ ┼¼╢≤└╠╛≡╞«╕ª ╝¡║±╜║╟╧┤┬ ╟┴╖╬╝╝╜║│¬ ╛▓╖╣╡σ░í
└√┤τ╟╤ ╝÷╕ª └»┴÷╟╧╡╡╖╧ ╝│░Φ╡╟╛·┤┘. ░╘┤┘░í <directive
module="mpm_common">StartServers</directive>┤┬, └╧├╩ ╚─
├╓╝╥╟╤ StartServers╕╕┼¡ ╗⌡╖╬┐ε └┌╜─└╠ ╛╚╕╕╡Θ╛ε┴÷╕Θ └┌╜─└╠
StartServers ░│░í ╡╟╡╡╖╧ ╗⌡╖╬ ╕╕╡τ┤┘. ┴∩, ╟┴╖╬▒╫╖Ñ└║ ╝¡╣÷└╟
╟÷└τ ║╬╟╧┐í ╛╦╕┬└║ └┌╜─└╟ ░│╝÷╕ª └»┴÷╟╧╕τ,
<directive>StartServers</directive> ╞─╢≤╣╠┼═╖╬ ┴÷┴ñ╟╤ ┤τ╜┼└╟
▒Γ┤δ╕ª ┴╕┴▀╟╤┤┘.</p>
<p><module>mod_status</module> ╗τ┐δ└┌┤┬ <code>USR1</code>└╗
╣▐└╗╢º ╝¡╣÷ ┼δ░Φ░í 0└╠ ╡╟┴÷ <strong>╛╩└╜└╗</strong> ║├└╗
░═└╠┤┘. ╝¡╣÷┤┬ ╗⌡╖╬┐ε ┐Σ├╗└╗ (┐ε┐╡├╝┴ª┤┬ └╠╡Θ└╗ ┼Ñ┐í ┤π╛╞╝¡
╛ε╢▓ ░µ┐∞┐í╡╡ └╥╛ε╣÷╕«┴÷ ╛╩┤┬┤┘) ├│╕«╟╧┴÷ ╕°╟╧┤┬ ╜├░ú└╗
├╓╝╥╚¡╟╧░φ ┤τ╜┼└╟ ╞⌐┤╫ ╞─╢≤╣╠┼═╕ª ┴╕┴▀╟╧╡╡╖╧ ╕╕╡Θ╛ε┴│┤┘.
└╠╕ª └º╟╪ ╝╝┤δ░ú ╕≡╡τ └┌╜─└╗ ▒Γ╖╧╟╧┤┬ <em>scoreboard</em>╕ª
└»┴÷╟╤┤┘.</p>
<p>status ╕≡╡Γ└║ ╢╟╟╤ ┴í└▌└║ └τ╜├└█ └ⁿ┐í ╜├└█╟╧┐⌐ ╛╞┴≈╡╡
┐Σ├╗└╗ ├│╕«╟╧░φ └╓┤┬ └┌╜─└╗ <code>G</code>╖╬ ╛╦╖┴┴╪┤┘.</p>
<p>╟÷└τ╖╬┤┬ <code>USR1</code>└╗ ╗τ┐δ╟╧┤┬ ╖╬▒╫╝°╚» ╜║┼⌐╕│╞«░í
└τ╜├└█└ⁿ┐í ╕≡╡τ └┌╜─└╠ ╖╬▒╫└█╝║└╗ ╕╢├╞┤┬┴÷ ╛╦ ╝÷ └╓┤┬
╣µ╣²└╠ ╛°┤┘. ┐∞╕«┤┬ <code>USR1</code> ╜├▒╫│╬└╗ ║╕│╗░φ
└√┤τ╟╤ ╜├░ú└╠ ┴÷│¡╚─ └╠└ⁿ ╖╬▒╫╕ª ┤┘╖τ╡╡╖╧ ┴ª╛╚╟╤┤┘. ┐╣╕ª
╡Θ╛ε │╖└║ ┤δ┐¬╞° ╗τ┐δ└┌└╟ ░µ┐∞ ┴ó╝╙ ┤δ║╬║╨└╠ ╕╢─í┤┬╡Ñ 10║╨└╠
╛╚░╔╕░┤┘╕Θ, └╠└ⁿ ╖╬▒╫╕ª ┤┘╖τ▒Γ└ⁿ┐í 15║╨ ▒Γ┤┘╕░┤┘.</p>
<note>╝│┴ñ╞─└╧┐í ┐└╖∙░í └╓┤┘╕Θ └τ╜├└█╜├ ║╬╕≡┤┬ └τ╜├└█╟╧┴÷
╛╩░φ ┐└╖∙╕ª │╗╕τ ┴╛╖ß╟╤┤┘. ╢╟, ┴í└▌└║ └τ╜├└█└╟ ░µ┐∞ ┴╛╖ß╟╥╢º
└┌╜─└╠ ╜╟╟α╡╟╡╡╖╧ │÷╡╨┤┘. (└┌╜─╡Θ└║ └┌╜┼└╟ ╕╢┴÷╕╖ ┐Σ├╗└╗
├│╕«╟╧░φ "┴í└▌░╘ ┴╛╖ß╟╤┤┘".) └╠┤┬ ╝¡╣÷╕ª └τ╜├└█╟╥╢º
╣«┴ª░í ╡╚┤┘. ╝¡╣÷┤┬ └┌╜┼└╠ ▒Γ┤┘╕▒ ╞≈╞«┐í ┐¼░ß╟╧┴÷ ╕°╟╤┤┘.
└τ╜├└█└ⁿ┐í <code>-t</code> ╕φ╖╔╟α ┐╔╝╟(<a
href="programs/httpd.html">httpd</a> ┬ⁿ░φ)└╕╖╬ ╝│┴ñ╞─└╧
╣«╣²└╗ ░╦╗τ╟╥ ╝÷ └╓┤┘. ▒╫╖»│¬ └╠╖▒ ░╦╗τ╡╡ ╝¡╣÷░í ┐├╣┘╖╬
└τ╜├└█╟╥┴÷╕ª ║╕└σ╟╧┴÷ ╕°╟╤┤┘. ╝│┴ñ╞─└╧└╟ ╣«╣²└╠ ╛╞┤╤ └╟╣╠╕ª
░╦╗τ╟╧╖┴╕Θ root░í ╛╞┤╤ ╗τ┐δ└┌╖╬ <code>httpd</code>╕ª ╜├└█╟╪║╝ ╝÷ └╓┤┘.
root░í ╛╞┤╧▒Γ╢º╣«┐í (╛╞┤╧╕Θ ╟÷└τ ▒╫ ╞≈╞«╕ª ╗τ┐δ╟╧┤┬
<code>httpd</code>░í ╜╟╟α╡╟▒Γ╢º╣«┐í) ┐└╖∙░í ╛°┤┘╕Θ ╝╥─╧░·
╖╬▒╫╞─└╧└╗ ┐¡╖┴░φ ╜├╡╡╟╧┤┬ ░·┴ñ┐í╝¡ ╜╟╞╨╟╥ ░═└╠┤┘. ┤┘╕Ñ
└╠└»╢º╣«┐í ╜╟╞╨╟╤┤┘╕Θ ╛╞╕╢╡╡ ╝│┴ñ╞─└╧┐í ┐└╖∙░í └╓└╗ ░═└╠┤┘.
┴í└▌└║ └τ╜├└█└╗ ╟╧▒Γ└ⁿ┐í ┐└╖∙╕ª ░φ├─╛▀╟╤┤┘.</note>
</section>
<section id="hup"><title>┤τ└σ └τ╜├└█</title>
<dl><dt>╜├▒╫│╬: HUP</dt>
<dd><code>apachectl -k restart</code></dd>
</dl>
<p><code>HUP</code>└╠│¬ <code>restart</code> ╜├▒╫│╬└╗
║╬╕≡┐í░╘ ║╕│╗╕Θ <code>TERM</code>░· ░░└╠ ╕≡╡τ └┌╜─└╗
┴╫└╠┴÷╕╕ ║╬╕≡┤┬ ┴╛╖ß╟╧┴÷ ╛╩┤┬┤┘. ║╬╕≡┤┬ ╝│┴ñ╞─└╧└╗ ┤┘╜├└╨░φ
╖╬▒╫╞─└╧└╗ ┤┘╜├ ┐¼┤┘. ▒╫╕«░φ ╗⌡╖╬┐ε └┌╜─╡Θ└╗ ╕╕╡Θ░φ ╝¡║±╜║╕ª
░Φ╝╙╟╤┤┘.</p>
<p><module>mod_status</module> ╗τ┐δ└┌┤┬ <code>HUP</code>╕ª
║╕│╗╕Θ ╝¡╣÷ ┼δ░Φ░í 0└╠ ╡╩└╗ ╛╦ ╝÷ └╓┤┘.</p>
<note>╝│┴ñ╞─└╧┐í ┐└╖∙░í └╓┤┘╕Θ └τ╜├└█└╗ ╟╪╡╡ ║╬╕≡┤┬ └τ╜├└█╟╧┴÷
╛╩░φ ┐└╖∙╕ª │╗╕τ ┴╛╖ß╟╥ ░═└╠┤┘. └╠╕ª ╟╟╟╧┤┬ ╣µ╣²└║ └º╕ª ┬ⁿ░φ╟╧╢≤.</note>
</section>
<section id="race"><title>║╬╖╧: ╜├▒╫│╬░· ╖╣└╠╜║ ─┴╡≡╝╟</title>
<p>Apache 1.2b9 └╠└ⁿ┐í┤┬ └τ╜├└█░· ┴╛╖ß ╜├▒╫│╬┐í ░ⁿ░Φ╡╚
<em>╖╣└╠╜║ ─┴╡≡╝╟(race condition)</em>└╠ └╓╛·┤┘. (╖╣└╠╜║
─┴╡≡╝╟└║ ░ú┤▄╟╤ ╝│╕φ╟╧└┌╕Θ, ╛ε╢▓ └╧└╠ └▀╕°╡╚╢º └╧╛ε│¬╝¡
▒Γ┤δ╟╤┤δ╖╬ ╡┐└█╟╧┴÷ ╛╩┤┬ ╜├░ú┐í ╣╬░¿╟╤ ╣«┴ª┤┘.) "┐├╣┘╕Ñ"
▒Γ┤╔└╠ └╓┤┬ ╛╞┼░┼╪├─┐í╝¡ ┐∞╕«┤┬ └╠╖▒ ╣«┴ª╕ª ├╓┤δ╟╤ ╟╪░ß╟▀┤┘.
▒╫╖»│¬ ╛ε╢▓ ╛╞┼░┼╪├─┐í┤┬ ╛╞┴≈╡╡ ╖╣└╠╜║ ─┴╡≡╝╟└╠ ┴╕└τ╟╘└╗
┴╓└╟╟╧╢≤.</p>
<p><directive module="mpm_common">ScoreBoardFile</directive>└╗
╡≡╜║┼⌐┐í └·└σ╟╧┤┬ ╛╞┼░┼╪├─┤┬ scoreboard╕ª ╕┴░í╞«╕▒ ░í┤╔╝║└╠
└╓┤┘. ▒╫╖»╕Θ (<code>HUP</code>╚─) "bind: Address already in use"
╚ñ└║ (<code>USR1</code> ╚─) "long lost child came home!"└╠
╣▀╗²╟╥ ╝÷ └╓┤┘. └ⁿ└┌┤┬ ╜╔░ó╟╤ ┐└╖∙└╠░φ, ╚─└┌┤┬ ┤▄┴÷ ╝¡╣÷░í
scoreboard slot└╗ └╥░╘ ╕╕╡τ┤┘. ▒╫╖í╝¡ ░¡┴ª └τ╜├└█└╗ ┴┘└╠░φ
┴í└▌└║ └τ╜├└█└╗ ╗τ┐δ╟╧▒µ ├▀├╡╟╤┤┘. └╠ ╣«┴ª┤┬ ╟╪░ß╟╧▒Γ ╕┼┐∞
╚√╡Θ┤┘. ▒╫╖»│¬ ┤┘╟α╚≈╡╡ ┤δ║╬║╨└╟ ╛╞┼░┼╪├─┤┬ scoreboard╖╬ ╞─└╧└╗
╗τ┐δ╟╧┴÷ ╛╩┤┬┤┘. ╞─└╧└╗ ╗τ┐δ╟╧┤┬ ╛╞┼░┼╪├─╢≤╕Θ <directive
module="mpm_common">ScoreBoardFile</directive> ╣«╝¡╕ª ┬ⁿ░φ╟╧╢≤.</p>
<p>╕≡╡τ ╛╞┼░┼╪├─┐í┤┬ ┴÷╝╙╡╟┤┬ HTTP ┐¼░ß (KeepAlive)┐í╝¡
╡╬╣°┬░ └╠╚─ ┐Σ├╗└╗ ├│╕«╟╧┤┬ └┌╜─┐í ╛α░ú└╟ ╖╣└╠╜║ ─┴╡≡╝╟└╠
└╓┤┘. └┌╜─└║ ┐Σ├╗┴┘└╗ └╨└║ ╚─ ┐Σ├╗ ╟∞┤⌡╕ª └╨▒Γ└ⁿ┐í ┴╛╖ß╟╥ ╝÷
└╓┤┘. └╠ ╣«┴ª┤┬ │╩╣½ ┤╩░╘ ╣▀░▀╟╧┐⌐ 1.2 ╣÷└ⁿ└╠ │¬┐┬╚─┐í╛▀
╝÷┴ñ╡╟╛·┤┘. ▒╫╖»│¬ │╫╞«┐≈ ┴÷┐¼└╠│¬ ╝¡╣÷ ╜├░ú┴ª╟╤╢º╣«┐í KeepAlive
┼¼╢≤└╠╛≡╞«┤┬ └╠╖▒ ░µ┐∞╕ª ┐╣╗≤╟╪╛▀╟╧▒Γ ╢º╣«┐í └╠╖╨╗≤ ╣«┴ª┤┬
╛╚╡╚┤┘. ╜╟┴ª╖╬ ╝¡╣÷╕ª ░╦╗τ╟╧▒Γ└º╟╪ └╧├╩┐í 20╣° └τ╜├└█╟╧┤┬ ╡┐╛╚
┼¼╢≤└╠╛≡╞«░í ▒·┴° ▒╫╕▓└╠│¬ ║≤ ╣«╝¡╛°└╠ ╗τ└╠╞«╕ª ╝║░°└√└╕╖╬
└╨╛ε╡Θ└╠▒µ ▒Γ┤δ╟╧┴÷ ╛╩┤┬┤┘╕Θ ╣«┴ª░í ╛╚╡╚┤┘.</p>
</section>
</manualpage>