some commands for search

1. locate (only search file by file name in mlocate database)

        /var/lib/mlocate

        /etc/updatedb.conf

        PRUNE_BIND_MOUNTS="yes"  ->  open search limit

        PRUNEFS  ->  not search the file system

        PRUNENAMES  ->  not search the file type

        PRUNEPATHS  ->  not search the path

2.  updatedb

        u need update the mlocate database immediately that u can use the locate command to search new file.

3. whereis (only search the system commands, path and help file)

        -b   only search excutable file

        -m  only search help file

4. which (search the system commands, path and alias)

5. find [range] [condition]

        wildcard -> * / ? / [ ] 

        -name (full matching)

        -iname (case insensitive)

        -user (according to the owner)

        -nouser (no owner's file)

        -mtime (the time to modify file contents)

        -atime (the time to access file)

        -ctime (the time to change file attributes)

                -time  ->  modify file within the specified time(day)

                time    ->  specified time for the day to modify the file(day)

                +time  ->   to modify the file before the specified time(day)

        -size (file size)

                -size  ->  less than size

                size   ->  be equal to size

                +size -> more than size

        -inum (i node)

        -a (and)

        -o (or)

        -exec (the command behind exec excute the result which excuted by the command in front of exec)

                {} \;  ->  the end symbol

6.grep (search string)

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值