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

Linux shell½Å±¾µÄ×Ö·û´®½ØÈ¡

Linux µÄ×Ö·û´®½ØÈ¡ºÜÓÐÓá£ÓаËÖÖ·½·¨¡£
¼ÙÉèÓбäÁ¿ var=http://www.hao.com/123.htm
.
.
Ò» # ºÅ½ØÈ¡£¬É¾³ý×ó±ß×Ö·û£¬±£ÁôÓÒ±ß×Ö·û¡£
echo ${var#*//}
ÆäÖÐ var ÊDZäÁ¿Ãû£¬# ºÅÊÇÔËËã·û£¬*// ±íʾ´Ó×ó±ß¿ªÊ¼É¾³ýµÚÒ»¸ö // ºÅ¼°×ó±ßµÄËùÓÐ×Ö·û
¼´É¾³ý http://
½á¹ûÊÇ £ºwww.hao.com/123.htm
   .
.
¶þ ## ºÅ½ØÈ¡£¬É¾³ý×ó±ß×Ö·û£¬±£ÁôÓÒ±ß×Ö·û¡£
echo ${var##*/}
##*/ ±íʾ´Ó×ó±ß¿ªÊ¼É¾³ý×îºó£¨×îÓұߣ©Ò»¸ö / ºÅ¼°×ó±ßµÄËùÓÐ×Ö·û
¼´É¾³ý http://www.hao.com/          
½á¹ûÊÇ 123.htm
.
.
Èý %ºÅ½ØÈ¡£¬É¾³ýÓÒ±ß×Ö·û£¬±£Áô×ó±ß×Ö·û
echo ${var%/*}
%/* ±íʾ´ÓÓұ߿ªÊ¼£¬É¾³ýµÚÒ»¸ö / ºÅ¼°ÓұߵÄ×Ö·û
½á¹ûÊÇ£ºhttp://www.hao.com
   .
.
ËÄ %% ºÅ½ØÈ¡£¬É¾³ýÓÒ±ß×Ö·û£¬±£Áô×ó±ß×Ö·û
echo ${var%%/*}
%%/* ±íʾ´ÓÓұ߿ªÊ¼£¬É¾³ý×îºó£¨×î×ó±ß£©Ò»¸ö / ºÅ¼°ÓұߵÄ×Ö·û
½á¹ûÊÇ£ºhttp:
.
.
Îå ´Ó×ó±ßµÚ¼¸¸ö×Ö·û¿ªÊ¼£¬¼°×Ö·ûµÄ¸öÊý
echo ${var:0:5}
ÆäÖÐµÄ 0 ±íʾ×ó±ßµÚÒ»¸ö×Ö·û¿ªÊ¼£¬5 ±íʾ×Ö·ûµÄ×ܸöÊý¡£
½á¹ûÊÇ£ºhttp:
.
.
Áù ´Ó×ó±ßµÚ¼¸¸ö×Ö·û¿ªÊ¼£¬Ò»Ö±µ½½áÊø¡£
echo ${var:7}
ÆäÖÐµÄ 7 ±íʾ×ó±ßµÚ8¸ö×Ö·û¿ªÊ¼£¬Ò»Ö±µ½½áÊø¡£
½á¹ûÊÇ £ºwww.hao.com/123.htm
.
.
Æß ´ÓÓұߵڼ¸¸ö×Ö·û¿ªÊ¼£¬¼°×Ö·ûµÄ¸öÊý
echo ${var:0-7:3}
ÆäÖÐµÄ 0-7 ±íʾÓÒ±ßËãÆðµÚÆ߸ö×Ö·û¿ªÊ¼£¬3 ±íʾ×Ö·ûµÄ¸öÊý¡£
½á¹ûÊÇ£º123
.
.
°Ë ´ÓÓұߵڼ¸¸ö×Ö·û¿ªÊ¼£¬Ò»Ö±µ½½áÊø¡£
echo ${var:0-7}
±íʾ´ÓÓұߵÚÆ߸ö×Ö·û¿ªÊ¼£¬Ò»Ö±µ½½áÊø¡£
½á¹ûÊÇ£º123.htm
¡£
¡£
×¢£º£¨×ó±ßµÄµÚÒ»¸ö×Ö·ûÊÇÓà 0 ±íʾ£¬ÓұߵĵÚÒ»¸ö×Ö·ûÓà 0-1 ±íʾ£©


Ïà¹ØÎĵµ£º

Linux iptableÎĵµ

×ÜÀÀ
ÓÃiptables -ADC À´Ö¸¶¨Á´µÄ¹æ
Ôò
£¬-AÌí¼Ó -Dɾ³ý -C ÐÞ¸Ä
iptables - [RI] chain rule num rule-specification[option]
ÓÃiptables - RI ͨ¹ý¹æÔòµÄ˳ÐòÖ¸¶¨
iptables -D chain rule num[option]
ɾ³ýÖ¸¶¨¹æÔò
iptables -[LFZ] [chain][option]
ÓÃiptables -LFZ Á´Ãû [Ñ¡Ïî]
iptables -[NX] chain
ÓÃ -NX ......

linux 2.6.24ÔÚS3C2410ÉϵÄÒÆÖ²(1)(»ùÓÚGEC2410)

1.ÏÂÔØlinux kernelÔ´´úÂë
µ½http://www.kernel.org/ÏÂÔØlinuxÄÚºËÔ´´úÂë,ÕâÀïÎÒÃÇʹÓÃ2.6.24.4µÄÄÚºË.
½âѹlinux-2.6.24.4.tar.bz2
[matt@localhost GEC2410]$ tar -xvjf linux-2.6.24.4.tar.bz2
[matt@localhost GEC2410]$ cd linux-2.6.24.4
2.ÐÞ¸ÄMakefile,ÉèÖý»²æ±àÒëÆ÷
ARCH  ?= arm
CROSS_COMPILE ......

linux ÍøÂç¼üÅÌ£¬Êó±ê

ÒòΪ¹«Ë¾µÄ°å×ÓÉϼüÅ̲»ºÃ°´£¬ËùÒÔд¸öÍøÂç°æµÄ£¬·½±ãµ÷ÊÔ¡£
client .c
#include <string.h>
#include <stdio.h>
#include <stdlib.h>
#include <linux/input.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <fcntl.h>
#include <errno.h>
#inclu ......

linux¸ùÎļþϵͳÓëinitrd£¨×ª£©


1
¸ùÎļþϵͳ
¼òµ¥À´Ëµ£¬£¨¸ùÎļþϵͳ£©¾ÍÊÇϵͳµÚÒ»¸ö
mount
µÄÎļþϵͳ

Filesystem
Handling
Like
every  
traditional  
Unix  
system,  

Linux  
makes  
use  
of  

a  
system ......

LinuxÎļþϵͳµÄ»º´æ»úÖÆ

LinuxÎļþϵͳÉè¼ÆÁËÈýÀàµÄCacheÒÔÓÃÀ´Ö§³Ö¶àÀàÐ͵ÄÎļþϵͳ¡£
Ò»¡¢        VFSË÷Òý½Úµã»º´æ Inode Cache
VFSË÷Òý½ÚµãÊÇÒ»¸öHash±í£¬Ëü²»¶ÏµØ¶ÁÈ¡¡£VFSÌṩµÄË÷Òý½Úµã»º´æ¿ÉÒÔ¼Ó¿ì¶ÔÎļþϵͳµÄ´æÈ¡¡£Ã¿´Î´ÓË÷Òý½Úµã»º´æÖжÁÈ¡Ò»¸öVFSË÷Òý½Úµã£¬ÕâÑùϵͳ¾Í¿ÉÒÔ½ÚÊ¡¶ÁÈ¡ÎïÀíÉ豸µÄ´æÈ¡Ê ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ