����Linux�Ż�
Linux����

FreeBSD �ļ���Ŀ¼����

����ʱ��:2006-08-15 10:49:35��Դ:��������:samblue
0. ǰ��

������Ѱ������һ����ϵͳ��˵������û�кܴ����;��
���Ƕ���һ����ϵͳ���������ļ�Խ��Խ�࣬ ��ʱ�ͱ���Ҫ����Ѱ����Ѱ�����ˡ�

1.which

ָ�� : which �� locate a program file in the user's path ��
�﷨ : which program
��; : ��ʹ���ߵ�ִ��·����Ѱ��ִ���ļ���
ʵ�� : ��Ѱ cd ��λ�á�

2.whereis ָ�� : whereis �� locate programs ��

�﷨ : whereis [ -bms ] program
��; : Ѱ��ԭʼ�������ݼ� (source directory), �����Ƴ��� (binary). ʹ���ֲ� (manuals)
���� : -b ��Ѱ�����Ƴ��� �� -m ��Ѱʹ�����ֲ� �� -s ��Ѱԭʼ��������ݼ�
ʵ�� :
(1) ��Ѱ cd ʹ�����ֲ��λ�á�
( 2) ��Ѱ cd ִ���ļ���λ�á�
˵�� : �������κβ��������ʾ -bms ���С� ʵ���г��־���ѶϢ����������δ��װ X-window �Ĺ�ϵ��
3.find

ָ�� : find �� walk a file hierarchy ��
�﷨ : find ��ʼĿ¼ -name ���ҵ��ļ��� -print
��; : �ڵ���ϵͳ�ܹ�����Ѱ��
ʵ�� : ��ĿǰĿ¼�У���Ѱ��Ϊ test �ĵ�����

4.grep ָ�� : grep �� print lines matching a pattern ��

�﷨ : grep pattern file_name
��; : ��Ѱ���������к��� pattern ���С�
ʵ�� : ��Ѱ���� test �У����� panda ���С�
����ʾ�������ݣ�


5.locate

ָ�� : locate �� find filenames quickly ��
�﷨ : locate program/file
��; : ��ϵͳ���������ݿ�����Ѱ���������ݼС�
ʵ�� : �����ݿ�����Ѱ test ������
�� : /var/db/locate.database Ԥ��� locate ���ݿ⣺ /usr/libexec/locate.updatedb
���� locate ���ݿ�� script ������ /etc/periodic/weekly/310.locate ��ʱ�����ؽ� locate ���ݿ�� script ������

���� : �� locate Ԥ��ÿһ�����ڲŸ���һ�����ݿ⣬�����½����ĵ���������֡� ��������������ʾ���������

�ٺ٣�����һƪ�õ��������£�����ͼƬ��ԭ�������µ������Ѿ����ˡ�
ֻ�ܴջ��߿��ˡ�
��������

���� 0 ������