<-
Apache > HTTP Server > Documentation > Version 2.2 > ¸ðµâ

Please note

This document refers to the 2.2 version of Apache httpd, which is no longer maintained. The active release is documented here. If you have not already upgraded, please follow this link for more information.

You may follow this link to go to the current version of this document.

¾ÆÆÄÄ¡ ¸ðµâ mod_so

°¡´ÉÇÑ ¾ð¾î:  en  |  ja  |  ko  |  tr 

¼³¸í:½ÃÀÛÇÒ¶§ ȤÀº Àç½ÃÀÛÇÒ¶§ ½ÇÇà°¡´ÉÇÑ ÄÚµå¿Í ¸ðµâÀ» ¼­¹ö·Î ÀоîµéÀδÙ
»óÅÂ:Extension
¸ðµâ¸í:so_module
¼Ò½ºÆÄÀÏ:mod_so.c
Áö¿ø:À©µµ¿ìÁî¿¡¼­ (Ç×»ó Æ÷ÇÔÇÏ´Â) Base ¸ðµâÀÌ´Ù.

¿ä¾à

¸î¸î ¿î¿µÃ¼Á¦¿¡¼­ ¾ÆÆÄÄ¡´Â µ¿Àû°øÀ¯°´Ã¼ (DSO) ±â¼úÀ» »ç¿ëÇÏ¿© ¼­¹ö¸¦ ´Ù½Ã ÄÄÆÄÀÏÇÏÁö ¾Ê°íµµ ½ÇÇàÁß¿¡ ¸ðµâÀ» ÀоîµéÀÏ ¼ö ÀÖ´Ù.

ÀоîµéÀÏ ÄÚµå´Â, À¯´Ð½º¿¡¼­´Â (.so È®ÀåÀÚ¸¦ °¡Áø) ÀϹÝÀûÀÎ °øÀ¯°´Ã¼ÆÄÀÏÀÌ°í, À©µµ¿ìÁî¿¡¼­´Â .so ȤÀº .dll È®ÀåÀÚ¸¦ °¡Áø´Ù.

°æ°í

¾ÆÆÄÄ¡ 1.3 ¸ðµâÀ» ¾ÆÆÄÄ¡ 2.0¿¡¼­ »ç¿ëÇÒ ¼ö ¾ø´Ù. ¾ÆÆÄÄ¡ 2.0ÀÌ µ¿ÀûÀ¸·Î ÀоîµéÀ̰ųª ¾ÆÆÄÄ¡¿Í °°ÀÌ ÄÄÆÄÀÏÇÏ·Á¸é ¸ðµâÀ» ¼öÁ¤ÇØ¾ß ÇÑ´Ù.

ÁÖÁ¦

Áö½Ã¾îµé

top

À©µµ¿ìÁî¿¡¼­ ÀоîµéÀÏ ¸ðµâ ¸¸µé±â

ÁÖÀÇ

À©µµ¿ìÁîÀÇ ¸ðµâ¸í Çü½ÄÀº ¾ÆÆÄÄ¡ 1.3.15¿Í 2.0¿¡¼­ º¯°æµÇ¾ú´Ù. ¸ðµâ¸íÀº ÀÌÁ¦ mod_foo.so½ÄÀÌ´Ù.

mod_so´Â ¾ÆÁ÷µµ ApacheModuleFoo.dll ½ÄÀÇ ¸ðµâÀ» ÀоîµéÀÏ ¼ö ÀÖÁö¸¸, »õ·Î¿î À̸§ ±ÔÄ¢À» ¼±È£ÇÑ´Ù. ¸ðµâÀ» 2.0¿¡ ¸Â°Ô ¼öÁ¤ÇÑ´Ù¸é À̸§À» 2.0 ±ÔÄ¢¿¡ ¾Ë¸Â°Ô °íÄ¡±æ ¹Ù¶õ´Ù.

¾ÆÆÄÄ¡ ¸ðµâ API´Â À¯´Ð½º ¹öÀüÀ̰ųª À©µµ¿ìÁî ¹öÀüÀ̰ųª °°´Ù. ¸î¸î API´Â À©µµ¿ìÁî¿¡ ¾ø´Â À¯´Ð½º ±¸Á¶¿¡ ÀÇÁ¸Çϱ⶧¹®¿¡ »ç¿ëÇÒ ¼ö ¾øÁö¸¸, À¯´Ð½º¿¡¼­ ½ÇÇàµÇ´Â ¸¹Àº ¸ðµâÀ» ¼öÁ¤¾øÀÌ È¤Àº Á¶±Ý ¼öÁ¤ÇÏ¿© À©µµ¿ìÁî¿¡¼­ »ç¿ëÇÒ ¼ö ÀÖ´Ù.

¸ðµâÀº µÎ°¡Áö ¹æ¹ýÀ¸·Î ¼­¹ö¿¡ Ãß°¡ÇÒ ¼ö ÀÖ´Ù. À¯´Ð½º¿¡¼­´Â ¸ðµâÀ» ¼­¹ö¿Í °°ÀÌ ÄÄÆÄÀÏÇÒ ¼ö ÀÖ´Ù. À©µµ¿ìÁî¿ë ¾ÆÆÄÄ¡´Â À¯´Ð½º¿Í ´Þ¸® Configure ÇÁ·Î±×·¥ÀÌ ¾ø±â¶§¹®¿¡ ¸ðµâÀÇ ¼Ò½ºÆÄÀÏÀ» ApacheCore ÇÁ·ÎÁ§Æ® ÆÄÀÏ¿¡ Ãß°¡ÇÏ°í, ½Éº¼À» os\win32\modules.c ÆÄÀÏ¿¡ Ãß°¡ÇØ¾ß ÇÑ´Ù.

µÎ¹ø° ¹æ¹ýÀº ¸ðµâÀ» ¼­¹ö°¡ LoadModule Áö½Ã¾î¸¦ »ç¿ëÇÏ¿© ½ÃÀÛÇÒ¶§ ÀоîµéÀÏ ¼ö ÀÖ´Â °øÀ¯¶óÀ̺귯¸® DLL·Î ¸¸µå´Â °ÍÀÌ´Ù. ÀÌ ¸ðµâ DLLÀ» ¹èÆ÷ÇÏ¸é ¼­¹ö¸¦ ÀçÄÄÆÄÀÏÇÏÁö ¾Ê°í ¾î¶² À©µµ¿ìÁî¿ë ¾ÆÆÄÄ¡¿¡¼­µµ ¸ðµâÀ» »ç¿ëÇÒ ¼ö ÀÖ´Ù.

¸ðµâ DLLÀ» ¸¸µé±âÀ§Çؼ­´Â ¸ðµâÀÇ ¼Ò½ºÆÄÀÏÀ» Á¶±Ý ¼öÁ¤ÇØ¾ß ÇÑ´Ù. DLLÀº module record¸¦ exportÇØ¾ß ÇÑ´Ù. (¾Æ·¡ Âü°í) À̸¦ À§ÇØ ¸ðµâÀÇ module record Á¤ÀÇ¿¡ (¾ÆÆÄÄ¡ Çì´õÆÄÀÏ¿¡ Á¤ÀǵÈ) AP_MODULE_DECLARE_DATA¸¦ Ãß°¡ÇÑ´Ù. ¿¹¸¦ µé¾î, ´ÙÀ½°ú °°Àº ¸ðµâÀÌ ÀÖ´Ù¸é:

module foo_module;

´ÙÀ½°ú °°ÀÌ ¼öÁ¤ÇÑ´Ù:

module AP_MODULE_DECLARE_DATA foo_module;

ÀÌ ºÎºÐÀº À©µµ¿ìÁî¿¡¼­¸¸ »ç¿ëÇϱ⶧¹®¿¡ º¯°æÇÏ¿©µµ À¯´Ð½º¿¡¼­ ¼Ò½º¸¦ ±×´ë·Î »ç¿ëÇÒ ¼ö ÀÖ´Ù. ¶Ç, .DEF ÆÄÀÏ¿¡ Àͼ÷ÇÏ´Ù¸é ´ë½Å ÀÌ ÆÄÀÏÀ» »ç¿ëÇÏ¿© module record¸¦ exportÇÒ ¼öµµ ÀÖ´Ù.

ÀÌÁ¦ ¸ðµâÀ» Æ÷ÇÔÇÑ DLLÀ» ¸¸µç´Ù. À̸¦ °øÀ¯¶óÀ̺귯¸® libhttpd.dllÀ» ÄÄÆÄÀÏÇÒ¶§ ¸¸µç libhttpd.lib export ¶óÀ̺귯¸®¿Í ¸µÅ©ÇÑ´Ù. ¾ÆÆÄÄ¡ Çì´õÆÄÀÏÀ» ¿Ã¹Ù·Î ãµµ·Ï ÄÄÆÄÀÏ·¯ ¼³Á¤À» ¼öÁ¤ÇØ¾ß ÇÒÁöµµ ¸ð¸¥´Ù. ¼­¹öÀÇ modules µð·ºÅ丮¿¡¼­ ÀÌ ¶óÀ̺귯¸®¸¦ ãÀ» ¼ö ÀÖ´Ù. ÄÄÆÄÀÏȯ°æÀ» ¿Ã¹Ù·Î ¼³Á¤ÇϱâÀ§ÇØ ±âÁ¸ ¸ðµâÀÇ .dsp ÆÄÀÏÀ» °¡Á®´Ù ¾²°Å³ª Á÷Á¢ ¸¸µç .dsp¿Í ÄÄÆÄÀÏ·¯/¸µÄ¿ ¿É¼ÇÀ» ºñ±³ÇÏ´Â °ÍÀÌ ÁÁ´Ù.

ÀÌÁ¦ ¸ðµâÀ» DLL·Î ¸¸µç´Ù. ÀÌ°ÍÀ» ¼­¹öÀÇ modules µð·ºÅ丮¿¡ µÎ°í, LoadModule Áö½Ã¾î¸¦ »ç¿ëÇÏ¿© ÀоîµéÀδÙ.

top

LoadFile Áö½Ã¾î

¼³¸í:ÁöÁ¤ÇÑ ¸ñÀûÆÄÀÏÀ̳ª ¶óÀ̺귯¸®¸¦ ÀоîµéÀδÙ
¹®¹ý:LoadFile filename [filename] ...
»ç¿ëÀå¼Ò:ÁÖ¼­¹ö¼³Á¤
»óÅÂ:Extension
¸ðµâ:mod_so

LoadFile Áö½Ã¾î´Â ¼­¹ö°¡ ½ÃÀÛÇϰųª Àç½ÃÀÛÇÒ¶§ ÁöÁ¤ÇÑ ¸ñÀûÆÄÀÏÀ̳ª ¶óÀ̺귯¸®¸¦ ÀоîµéÀδÙ(link in). ÀÌ Áö½Ã¾î´Â ¾î¶² ¸ðµâÀÌ µ¿ÀÛÇϱâÀ§ÇØ ÇÊ¿äÇÑ Äڵ带 Ãß°¡·Î ÀоîµéÀ϶§ »ç¿ëÇÑ´Ù. FilenameÀº Àý´ë°æ·ÎÀ̰ųª ServerRoot¿¡ ´ëÇÑ »ó´ë°æ·ÎÀÌ´Ù.

¿¹¸¦ µé¾î:

LoadFile libexec/libxmlparse.so

top

LoadModule Áö½Ã¾î

¼³¸í:¸ñÀûÆÄÀÏÀ̳ª ¶óÀ̺귯¸®¸¦ ÀоîµéÀÌ°í, »ç¿ë°¡´ÉÇÑ ¸ðµâ ¸ñ·Ï¿¡ Ãß°¡ÇÑ´Ù
¹®¹ý:LoadModule module filename
»ç¿ëÀå¼Ò:ÁÖ¼­¹ö¼³Á¤
»óÅÂ:Extension
¸ðµâ:mod_so

LoadModule Áö½Ã¾î´Â ¸ñÀûÆÄÀÏ È¤Àº ¶óÀ̺귯¸® filenameÀ» ÀоîµéÀÌ°í, »ç¿ë°¡´ÉÇÑ ¸ðµâ ¸ñ·Ï¿¡ moduleÀ̶ó´Â ¸ðµâ ±¸Á¶Ã¼¸¦ Ãß°¡ÇÑ´Ù. ModuleÀº ÆÄÀÏÀÇ module ÀÚ·áÇü ¿ÜºÎº¯¼ö¸íÀ̸ç, ¸ðµâ ¹®¼­ÀÇ ¸ðµâ¸í¿¡ ³ª¿Â´Ù. ¿¹¸¦ µé¸é:

LoadModule status_module modules/mod_status.so

ServerRootÀÇ modules ÇÏÀ§µð·ºÅ丮¿¡¼­ ÁöÁ¤ÇÑ ¸ðµâÀ» ÀоîµéÀδÙ.

°¡´ÉÇÑ ¾ð¾î:  en  |  ja  |  ko  |  tr 

top

Comments

Notice:
This is not a Q&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 Libera.chat, or sent to our mailing lists.