mod_so.html.ko.euc-kr 12.4 KB
Newer Older
powelld's avatar
powelld committed
<?xml version="1.0" encoding="EUC-KR"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="ko" xml:lang="ko"><head>
<meta content="text/html; charset=EUC-KR" http-equiv="Content-Type" />
<!--
        XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
              This file is generated from xml source: DO NOT EDIT
        XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
      -->
<title>mod_so - Apache HTTP Server Version 2.4</title>
<link href="../style/css/manual.css" rel="stylesheet" media="all" type="text/css" title="Main stylesheet" />
<link href="../style/css/manual-loose-100pc.css" rel="alternate stylesheet" media="all" type="text/css" title="No Sidebar - Default font size" />
<link href="../style/css/manual-print.css" rel="stylesheet" media="print" type="text/css" /><link rel="stylesheet" type="text/css" href="../style/css/prettify.css" />
<script src="../style/scripts/prettify.min.js" type="text/javascript">
</script>

<link href="../images/favicon.ico" rel="shortcut icon" /></head>
<body>
<div id="page-header">
<p class="menu"><a href="../mod/">모듈</a> | <a href="../mod/directives.html">지시어들</a> | <a href="http://wiki.apache.org/httpd/FAQ">FAQ</a> | <a href="../glossary.html">용어</a> | <a href="../sitemap.html">사이트맵</a></p>
<p class="apache">Apache HTTP Server Version 2.4</p>
<img alt="" src="../images/feather.png" /></div>
<div class="up"><a href="./"><img title="&lt;-" alt="&lt;-" src="../images/left.gif" /></a></div>
<div id="path">
<a href="http://www.apache.org/">Apache</a> &gt; <a href="http://httpd.apache.org/">HTTP Server</a> &gt; <a href="http://httpd.apache.org/docs/">Documentation</a> &gt; <a href="../">Version 2.4</a> &gt; <a href="./">모듈</a></div>
<div id="page-content">
<div id="preamble"><h1>아파치 모듈 mod_so</h1>
<div class="toplang">
<p><span>가능한 언어: </span><a href="../en/mod/mod_so.html" hreflang="en" rel="alternate" title="English">&nbsp;en&nbsp;</a> |
<a href="../fr/mod/mod_so.html" hreflang="fr" rel="alternate" title="Fran&#231;ais">&nbsp;fr&nbsp;</a> |
<a href="../ja/mod/mod_so.html" hreflang="ja" rel="alternate" title="Japanese">&nbsp;ja&nbsp;</a> |
<a href="../ko/mod/mod_so.html" title="Korean">&nbsp;ko&nbsp;</a> |
<a href="../tr/mod/mod_so.html" hreflang="tr" rel="alternate" title="T&#252;rk&#231;e">&nbsp;tr&nbsp;</a></p>
</div>
<div class="outofdate">이 문서는 최신판 번역이 아닙니다.
            최근에 변경된 내용은 영어 문서를 참고하세요.</div>
<table class="module"><tr><th><a href="module-dict.html#Description">설명:</a></th><td>시작할때 혹은 재시작할때 실행가능한 코드와 모듈을
서버로 읽어들인다</td></tr>
<tr><th><a href="module-dict.html#Status">상태:</a></th><td>Extension</td></tr>
<tr><th><a href="module-dict.html#ModuleIdentifier">모듈명:</a></th><td>so_module</td></tr>
<tr><th><a href="module-dict.html#SourceFile">소스파일:</a></th><td>mod_so.c</td></tr>
<tr><th><a href="module-dict.html#Compatibility">지원:</a></th><td>윈도우즈에서 (항상 포함하는) Base 모듈이다.</td></tr></table>
<h3>요약</h3>


    <p>몇몇 운영체제에서 아파치는 <a href="../dso.html">동적공유객체</a>
    (DSO) 기술을 사용하여 서버를 다시 컴파일하지 않고도 실행중에
    모듈을 읽어들일 수 있다.</p>
    
    <p>읽어들일 코드는, 유닉스에서는 (<code>.so</code> 확장자를
    가진) 일반적인 공유객체파일이고, 윈도우즈에서는 <code>.so</code>
    혹은 <code>.dll</code> 확장자를 가진다.</p>

    <div class="warning"><h3>경고</h3>
    <p>아파치 1.3 모듈을 아파치 2.0에서 사용할 수 없다.
    아파치 2.0이 동적으로 읽어들이거나 아파치와 같이 컴파일하려면
    모듈을 수정해야 한다.</p>
    </div>
</div>
<div id="quickview"><a href="https://www.apache.org/foundation/contributing.html" class="badge"><img src="https://www.apache.org/images/SupportApache-small.png" alt="Support Apache!" /></a><h3>주제</h3>
<ul id="topics">
<li><img alt="" src="../images/down.gif" /> <a href="#windows">윈도우즈에서 읽어들일 모듈 만들기</a></li>
</ul><h3 class="directives">지시어들</h3>
<ul id="toc">
<li><img alt="" src="../images/down.gif" /> <a href="#loadfile">LoadFile</a></li>
<li><img alt="" src="../images/down.gif" /> <a href="#loadmodule">LoadModule</a></li>
</ul>
<h3>Bugfix checklist</h3><ul class="seealso"><li><a href="https://www.apache.org/dist/httpd/CHANGES_2.4">httpd changelog</a></li><li><a href="https://bz.apache.org/bugzilla/buglist.cgi?bug_status=__open__&amp;list_id=144532&amp;product=Apache%20httpd-2&amp;query_format=specific&amp;order=changeddate%20DESC%2Cpriority%2Cbug_severity&amp;component=mod_so">Known issues</a></li><li><a href="https://bz.apache.org/bugzilla/enter_bug.cgi?product=Apache%20httpd-2&amp;component=mod_so">Report a bug</a></li></ul><h3>참고</h3>
<ul class="seealso">
<li><a href="#comments_section">Comments</a></li></ul></div>
<div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
<div class="section">
<h2><a name="windows" id="windows">윈도우즈에서 읽어들일 모듈 만들기</a></h2>

    <div class="note"><h3>주의</h3>
    <p>윈도우즈의 모듈명 형식은 아파치 1.3.15와 2.0에서 변경되었다.
    모듈명은 이제 mod_foo.so식이다.</p>

    <p>mod_so는 아직도 ApacheModuleFoo.dll 식의 모듈을 읽어들일
    수 있지만, 새로운 이름 규칙을 선호한다. 모듈을 2.0에 맞게
    수정한다면 이름을 2.0 규칙에 알맞게 고치길 바란다.</p></div>

    <p>아파치 모듈 API는 유닉스 버전이거나 윈도우즈 버전이거나
    같다. 몇몇 API는 윈도우즈에 없는 유닉스 구조에 의존하기때문에
    사용할 수 없지만, 유닉스에서 실행되는 많은 모듈을 수정없이
    혹은 조금 수정하여 윈도우즈에서 사용할 수 있다.</p>

    <p>모듈은 두가지 방법으로 서버에 추가할 수 있다. 유닉스에서는
    모듈을 서버와 같이 컴파일할 수 있다. 윈도우즈용 아파치는
    유닉스와 달리 <code>Configure</code> 프로그램이 없기때문에
    모듈의 소스파일을 ApacheCore 프로젝트 파일에 추가하고, 심볼을
    <code>os\win32\modules.c</code> 파일에 추가해야 한다.</p>

    <p>두번째 방법은 모듈을 서버가
    <code><code class="directive">LoadModule</code></code> 지시어를
    사용하여 시작할때 읽어들일 수 있는 공유라이브러리 DLL로
    만드는 것이다. 이 모듈 DLL을 배포하면 서버를 재컴파일하지
    않고 어떤 윈도우즈용 아파치에서도 모듈을 사용할 수 있다.</p>

    <p>모듈 DLL을 만들기위해서는 모듈의 소스파일을 조금 수정해야
    한다. DLL은 module record를 export해야 한다. (아래 참고)
    이를 위해 모듈의 module record 정의에 (아파치 헤더파일에
    정의된) <code>AP_MODULE_DECLARE_DATA</code>를 추가한다.
    예를 들어, 다음과 같은 모듈이 있다면:</p>

<div class="example"><p><code>
    module foo_module;
</code></p></div>

    <p>다음과 같이 수정한다:</p>
<div class="example"><p><code>
    module AP_MODULE_DECLARE_DATA foo_module;
</code></p></div>

    <p>이 부분은 윈도우즈에서만 사용하기때문에 변경하여도 유닉스에서
    소스를 그대로 사용할 수 있다. 또, <code>.DEF</code> 파일에
    익숙하다면 대신 이 파일을 사용하여 module record를 export할
    수도 있다.</p>

    <p>이제 모듈을 포함한 DLL을 만든다. 이를 공유라이브러리
    libhttpd.dll을 컴파일할때 만든 libhttpd.lib export 라이브러리와
    링크한다. 아파치 헤더파일을 올바로 찾도록 컴파일러 설정을
    수정해야 할지도 모른다. 서버의 modules 디렉토리에서 이
    라이브러리를 찾을 수 있다. 컴파일환경을 올바로 설정하기위해
    기존 모듈의 .dsp 파일을 가져다 쓰거나 직접 만든 .dsp와
    컴파일러/링커 옵션을 비교하는 것이 좋다.</p>

    <p>이제 모듈을 DLL로 만든다. 이것을 서버의
    <code>modules</code> 디렉토리에 두고,
    <code class="directive">LoadModule</code> 지시어를 사용하여 읽어들인다.</p>

</div>
<div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
<div class="directive-section"><h2><a name="LoadFile" id="LoadFile">LoadFile</a> <a name="loadfile" id="loadfile">지시어</a></h2>
<table class="directive">
<tr><th><a href="directive-dict.html#Description">설명:</a></th><td>지정한 목적파일이나 라이브러리를 읽어들인다</td></tr>
<tr><th><a href="directive-dict.html#Syntax">문법:</a></th><td><code>LoadFile <em>filename</em> [<em>filename</em>] ...</code></td></tr>
<tr><th><a href="directive-dict.html#Context">사용장소:</a></th><td>주서버설정</td></tr>
<tr><th><a href="directive-dict.html#Status">상태:</a></th><td>Extension</td></tr>
<tr><th><a href="directive-dict.html#Module">모듈:</a></th><td>mod_so</td></tr>
</table>

    <p>LoadFile 지시어는 서버가 시작하거나 재시작할때 지정한
    목적파일이나 라이브러리를 읽어들인다(link in). 이 지시어는
    어떤 모듈이 동작하기위해 필요한 코드를 추가로 읽어들일때
    사용한다. <em>Filename</em>은 절대경로이거나 <a href="core.html#serverroot">ServerRoot</a>에 대한 상대경로이다.</p>

    <p>예를 들어:</p>

    <div class="example"><p><code>LoadFile libexec/libxmlparse.so</code></p></div>


</div>
<div class="top"><a href="#page-header"><img alt="top" src="../images/up.gif" /></a></div>
<div class="directive-section"><h2><a name="LoadModule" id="LoadModule">LoadModule</a> <a name="loadmodule" id="loadmodule">지시어</a></h2>
<table class="directive">
<tr><th><a href="directive-dict.html#Description">설명:</a></th><td>목적파일이나 라이브러리를 읽어들이고, 사용가능한
모듈 목록에 추가한다</td></tr>
<tr><th><a href="directive-dict.html#Syntax">문법:</a></th><td><code>LoadModule <em>module filename</em></code></td></tr>
<tr><th><a href="directive-dict.html#Context">사용장소:</a></th><td>주서버설정</td></tr>
<tr><th><a href="directive-dict.html#Status">상태:</a></th><td>Extension</td></tr>
<tr><th><a href="directive-dict.html#Module">모듈:</a></th><td>mod_so</td></tr>
</table>
    <p>LoadModule 지시어는 목적파일 혹은 라이브러리 <em>filename</em>
    읽어들이고, 사용가능한 모듈 목록에 <em>module</em>이라는
    모듈 구조체를 추가한다. <em>Module</em>은 파일의
    <code>module</code> 자료형 외부변수명이며, 모듈 문서의 <a href="module-dict.html#ModuleIdentifier">모듈명</a>
    나온다. 예를 들면:</p>

    <div class="example"><p><code>
      LoadModule status_module modules/mod_status.so
    </code></p></div>

    <p>ServerRoot의 modules 하위디렉토리에서 지정한 모듈을 읽어들인다.</p>

</div>
</div>
<div class="bottomlang">
<p><span>가능한 언어: </span><a href="../en/mod/mod_so.html" hreflang="en" rel="alternate" title="English">&nbsp;en&nbsp;</a> |
<a href="../fr/mod/mod_so.html" hreflang="fr" rel="alternate" title="Fran&#231;ais">&nbsp;fr&nbsp;</a> |
<a href="../ja/mod/mod_so.html" hreflang="ja" rel="alternate" title="Japanese">&nbsp;ja&nbsp;</a> |
<a href="../ko/mod/mod_so.html" title="Korean">&nbsp;ko&nbsp;</a> |
<a href="../tr/mod/mod_so.html" hreflang="tr" rel="alternate" title="T&#252;rk&#231;e">&nbsp;tr&nbsp;</a></p>
</div><div class="top"><a href="#page-header"><img src="../images/up.gif" alt="top" /></a></div><div class="section"><h2><a id="comments_section" name="comments_section">Comments</a></h2><div class="warning"><strong>Notice:</strong><br />This is not a Q&amp;A section. Comments placed here should be pointed towards suggestions on improving the documentation or server, and may be removed again by our moderators if they are either implemented or considered invalid/off-topic. Questions on how to manage the Apache HTTP Server should be directed at either our IRC channel, #httpd, on Freenode, or sent to our <a href="http://httpd.apache.org/lists.html">mailing lists</a>.</div>
<script type="text/javascript"><!--//--><![CDATA[//><!--
var comments_shortname = 'httpd';
var comments_identifier = 'http://httpd.apache.org/docs/2.4/mod/mod_so.html';
(function(w, d) {
    if (w.location.hostname.toLowerCase() == "httpd.apache.org") {
        d.write('<div id="comments_thread"><\/div>');
        var s = d.createElement('script');
        s.type = 'text/javascript';
        s.async = true;
        s.src = 'https://comments.apache.org/show_comments.lua?site=' + comments_shortname + '&page=' + comments_identifier;
        (d.getElementsByTagName('head')[0] || d.getElementsByTagName('body')[0]).appendChild(s);
    }
    else { 
        d.write('<div id="comments_thread">Comments are disabled for this page at the moment.<\/div>');
    }
})(window, document);
//--><!]]></script></div><div id="footer">
<p class="apache">Copyright 2017 The Apache Software Foundation.<br />Licensed under the <a href="http://www.apache.org/licenses/LICENSE-2.0">Apache License, Version 2.0</a>.</p>
<p class="menu"><a href="../mod/">모듈</a> | <a href="../mod/directives.html">지시어들</a> | <a href="http://wiki.apache.org/httpd/FAQ">FAQ</a> | <a href="../glossary.html">용어</a> | <a href="../sitemap.html">사이트맵</a></p></div><script type="text/javascript"><!--//--><![CDATA[//><!--
if (typeof(prettyPrint) !== 'undefined') {
    prettyPrint();
}
//--><!]]></script>
</body></html>