SYSINFO

Section: ¸®´ª½º ÇÁ·Î±×·¡¸Ó ¸Å´º¾ó (2)
Updated: 1997³â 8¿ù 25ÀÏ
Index
Return to Main Contents
 

À̸§

sysinfo - ÀüüÀûÀÎ ½Ã½ºÅÛ Åë°è Á¤º¸¸¦ ¹ÝȯÇÑ´Ù.  

»ç¿ë¹ý

#include <sys/sysinfo.h>

int sysinfo(struct sysinfo *info);  

¼³¸í

sysinfo´Â ´ÙÀ½ ±¸Á¶Ã¼ ¾È¿¡ Á¤º¸¸¦ ¹ÝȯÇÑ´Ù.

struct sysinfo {
        long uptime;              /* ºÎÆà ÀÌÈÄ Áö³ª°£ ÃÊ´ÜÀ§ ½Ã°£*/
        unsigned long loads[3];   /* 1, 5, ±×¸®°í 15 ºÐ ºÎÇÏ Æò±Õ*/
        unsigned long totalram;   /* »ç¿ëÇÒ ¼ö ÀÖ´Â ÃÑ ¸Þ¸ð¸® Å©±â*/
        unsigned long freeram;    /* ÀÌ¿ëÇÒ ¼ö ÀÖ´Â ¸Þ¸ð¸® Å©±â*/
        unsigned long sharedram;  /* °øÀ¯ ¸Þ¸ð¸®ÀÇ ¾ç*/
        unsigned long bufferram;  /* ¹öÆÛ¿¡ ÀÇÇØ »ç¿ëµÈ ¸Þ¸ð¸®*/
        unsigned long totalswap;  /* ÃÑ ½º¿Ò °ø°£ÀÇ Å©±â*/
        unsigned long freeswap;   /* ÀÌ¿ëÇÒ ¼ö ÀÖ´Â ½º¿Ò °ø°£*/
        unsigned short procs;     /* ÇöÀç ÇÁ·Î¼¼½ºÀÇ ¼ö*/
        char _f[22];              /* ±¸Á¶Ã¼¸¦ 64 bytes·Î ä¿î´Ù(pad)*/
};

sysinfo´Â ÀüüÀûÀÎ ½Ã½ºÅÛ Åë°è Á¤º¸¸¦ °¡Á®¿Ã ¼ö ÀÖ´Â °£´ÜÇÑ ¹æ¹ýÀ» Á¦°øÇÑ´Ù. ¶ÇÇÑ /dev/kmem¸¦ Àд°ͺ¸´Ù ÈξÀ ȣȯ¼ºÀÌ ÁÁ´Ù. »ç¿ë ¿¹¸¦ º¼·Á¸é, intro(2)¸¦ ÂüÁ¶Çضó.  

¹Ýȯ°ª

¼º°ø½Ã, 0À» ¹ÝȯÇÑ´Ù. ¿¡·¯½Ã, -1À» ¹ÝȯÇϸç, errno´Â Àû´çÇÑ °ªÀ¸·Î ¼³Á¤µÈ´Ù.  

¿¡·¯

EFAULT
struct sysinfo°¡ °¡¸®Å°´Â Æ÷ÀÎÅÍ°¡ À¯È¿ÇÏÁö ¾Ê´Ù.
 

ȣȯ

ÀÌ ÇÔ¼ö´Â ¸®´ª½º¿¡ ÀÇÁ¸ÀûÀ̹ǷΠȣȯ¼ºÀ» ¿°µÎ¿¡ µÐ ÇÁ·Î±×·¥¿¡¼­ »ç¿ëÇؼ­´Â ¾ÈµÈ´Ù.

¸®´ª½º Ä¿³ÎÀº 0.98.pl6 ÀÌÈÄ¿¡ sysinfo½Ã½ºÅÛ ÄÝÀ» °¡Áö°í ÀÖ´Ù. ¸®´ª½º libc´Â 5.3.5 ÀÌÈÄ¿¡ sysinfo() ·çƾÀ» Æ÷ÇÔÇÏ¿´À¸¸ç glibc¿¡¼­´Â 1.9 ÀÌÈÄ¿¡ Æ÷ÇÔÇÏ¿´´Ù.  

°ü·Ã Ç׸ñ

proc(5)  

¿ªÀÚ

Á¤°­ÈÆ <skyeyes@soback.kornet.net>, 2000³â 5¿ù 28ÀÏ


 

Index

À̸§
»ç¿ë¹ý
¼³¸í
¹Ýȯ°ª
¿¡·¯
ȣȯ
°ü·Ã Ç׸ñ
¿ªÀÚ

This document was created by man2html, using the manual pages.
Time: 08:06:59 GMT, March 25, 2004