Ò׽ؽØÍ¼Èí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

LINUXϵͳ±à³ÌÖ®ÈÕÀúʱ¼ä

LINUXÖÐʱ¼äÓÐÁ½ÖÖ£º
1£©ÈÕÀúʱ¼ä
2£©½ø³Ìʱ¼ä
ÈÕÀúʱ¼ä¹ËÃû˼Òå¼´ÓÃÀ´»ñÈ¡ÈÕÀú£»
Ö÷񻃾¼°µ½µÄº¯ÊýÓУº
time(time_t*);
stime(time_t*);
tm* gmtime(time_t*);
tm* localtime(time_t*);
char *strftime(tm*);
char *asctime(tm*);
time_t* mktime(tm*);
Êý¾Ý½á¹¹ÈçÏ£º
time_t
struct tm{
  int tm_sec;
  int tm_min;
  int tm_hour;
  int tm_mday;
  int tm_wday;
  int tm_yday;
  int tm_year;
  int tm_isdst;
}
ת»»¹ØÏµÈçÏÂͼ£º
ʾÀý´úÂëÈçÏ£º
struct utsname aname;
int a=uname(&aname);
cout << a;
cout << endl;
cout << aname.sysname<< endl;
cout << aname.machine<< endl;
cout << aname.release<< endl;
cout << aname.version<<endl;
cout << aname.nodename<< endl;


time_t time1;
time_t time2;
time2=time(&time1);
cout << time1 << endl;
cout << time2 << endl;
struct tm *tm1;
tm1=localtime(&time1);
cout << tm1->tm_sec<<endl;
cout << tm1->tm_min<<endl;
cout << tm1->tm_hour<<endl;
cout << tm1->tm_mday<<endl;
cout << tm1->tm_mon<<endl;
cout << tm1->tm_year<<endl;
cout << tm1->tm_wday<<endl;
cout << tm1->tm_yday<<endl;
char *css;
css=asctime(tm1);
cout << css;
size_t size=strftime(css,100,"%Y-%m-%d %H-%M-%S %w",tm1);
cout << size << ":"<<css;


Ïà¹ØÎĵµ£º

Linux c Êý¾ÝÀàÐÍ

µ±LinuxÄÚºËÔÚÌåϵ½á¹¹²îÒì½Ï´óµÄƽ̨֮¼äÒÆÖ²Ê±£¬»á²úÉúÓëÊý¾ÝÀàÐÍÏà¹ØµÄÎÊÌâ¡£
.ÔÚ±àÒëÄÚºËʱʹÓà -Wall  -W strict-prototypes Ñ¡Ïî, ¿ÉÒÔ±ÜÃâºÜ¶à´íÎóµÄ·¢Éú
.ÄÚºËʹÓõĻù±¾Êý¾ÝÀàÐÍÖ÷ÒªÓÐ:
     int           ±ê×¼CÓïÑÔÕûÊýÀàÐÍ
&n ......

LinuxÎļþϵͳµÄÌåϵ½á¹¹

Ò»¡¢Ó²ÅÌ·ÖÇøÓëÎļþϵͳ
1) ͨ³£ÔÚÄõ½Ò»¿éеÄÓ²ÅÌʱ£¬»á½«Ó²ÅÌ·Ö¸î³É¼¸¸ö²»Í¬µÄ·ÖÇø(partition)
2) ·ÖºÃ·ÖÇøºó£¬Òª°ÑÕâЩ·ÖÇø¸ñʽ»¯(Format)³ÉÌØ¶¨µÄÎļþϵͳ¸ñʽ(File System Format)£¬²ÅÄܹ»ÓÃÀ´´¢´æÎļþ¡£¸ñʽ»¯¾ÍÊǰѷÖÇøÇиî³ÉÒ»¸ö¸öСµ¥Î»(³ÆÎªblock)£¬²¢ÇÒblockÒÀÐò±àºÅ¡£blockÊÇ´¢´æÎļþÄÚÈݵÄ×îСµ¥Î»¡£ÔÚÔ¤Éè ......

linux zip ¼ÓÃܵÄshiyong


1.    
linux
ÃüÁîµÄµ÷ÊÔʹÓÃ
 
ÒÔÏÂÊÇ´ÓÍøÉϲéÕÒÀ´µÄ
linux
ÃüÁî
zip
µÄʹÓ÷½·¨¡£Èç¹ûÓв»ÖªµÀÃüÁîÈçºÎʹÓÃÄã¿ÉÒÔ
man+[
ÃüÁî
]
»òÕßÊÇ
[
ÃüÁî
]+

-h
”£¬À´²é¿´ÃüÁîµÄʹÓ÷½·¨¡£
 
zip
 
¹¦ÄÜ˵Ã÷£ºÑ¹ËõÎļþ¡£
Óï¡¡¡¡·¨£º
zip
[-AcdDfFghj ......

windowsºÍÐéÄâLINUX ÖеÄÎļþ¹²Ïí

ʹÓÃVMware ×Ô´øµÄVMware tools¿ÉÒÔÓÃÀ´ÊµÏÖwindowsºÍlinuxÖ®¼äµÄ¹²Ïí×ÊÔ´¡£
²½ÖèÈçÏ£º
1.         °²×°ÍêVMwareÐéÄâ»úºÍÐéÄâlinux ºó¡£
2.         ´ò¿ªVMware ÐéÄâ»ú ²Ëµ¥À¸µÄVM ——> intall VMware tools £¨»á³öÏÖ¹ ......

LinuxϵÄCPUÀûÓÃÂʼÆËãÔ­ÀíÏê½â

   ÎÒÃÇÔÚ¸ãÐÔÄܲâÊÔµÄʱºò£¬¶Ôºǫ́·þÎñÆ÷µÄCPUÀûÓÃÂÊ¼à¿ØÊÇÒ»¸ö³£ÓõÄÊֶΡ£·þÎñÆ÷µÄCPUÀûÓÃÂʸߣ¬Ôò±íÃ÷·þÎñÆ÷ºÜ·±Ã¦¡£Èç¹ûǰ̨ÏìӦʱ¼äÔ½À´Ô½´ó£¬¶øºǫ́CPUÀûÓÃÂÊʼÖÕÉϲ»È¥£¬ËµÃ÷ÔÚij¸öµØ·½ÓÐÆ¿¾±ÁË£¬ÏµÍ³ÐèÒªµ÷ÓÅ¡£Õâ¸öÊǼ´Ê¹²»¶®¼¼ÊõµÄÈ˶¼ÈÝÒ×Àí½âµÄÊÂÇé¡£
   ÉÏÃæÀí½â¶ÔÂð£¿ÎÒ¸öÈ˾õµÃ²»Ê®·Ö× ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØÍ¼ | ¸ÓICP±¸09004571ºÅ