欧美bbbwbbbw肥妇,免费乱码人妻系列日韩,一级黄片

Linux文件查找命令總結(上篇)

 更新時間:2023年01月13日 15:20:16   作者:小熊coder  
這篇文章主要介紹了Linux文件查找命令總結(上篇),本文章內容詳細,通過案例可以更好的掌握文件查找的相關命令,本篇為上篇,需要的朋友可以參考下

前文

關于Linux文件查找命令總結我們分別介紹了which命令、whereis命令、locate命令、find命令這四個命令,本篇向大家介紹的是:which命令、whereis命令、locate命令。

which命令語法

我們經(jīng)常在linux要查找某個文件,但不知道放在哪里了,可以使用下面的一些命令來搜索:

  • which 查看可執(zhí)行文件的位置。
  • whereis 查看文件的位置。
  • locate 配合數(shù)據(jù)庫查看文件位置。
  • find 實際搜尋硬盤查詢文件名稱。
  1. which命令的作用是,在PATH變量指定的路徑中,搜索某個系統(tǒng)命令的位置,并且返回第一個搜索結果。
  2. 也就是說,使用which命令,就可以看到某個系統(tǒng)命令是否存在,以及執(zhí)行的到底是哪一個位置的命令。

命令格式

which 可執(zhí)行文件名稱

命令功能

which指令會在PATH變量指定的路徑中,搜索某個系統(tǒng)命令的位置,并且返回第一個搜索結果。

命令參數(shù)

  • -n 指定文件名長度,指定的長度必須大于或等于所有文件中最長的文件名。
  • -p 與-n參數(shù)相同,但此處的包括了文件的路徑。
  • -w 指定輸出時欄位的寬度。
  • -V 顯示版本信息

which命令使用示例

查找文件、顯示命令路徑

命令:

which lsmod

輸出:

[root@localhost ~]# which pwd
/bin/pwd
[root@localhost ~]# which adduser
/usr/sbin/adduser
[root@localhost ~]#

說明:

which 是根據(jù)使用者所配置的 PATH 變量內的目錄去搜尋可運行檔的!

所以,不同的 PATH 配置內容所找到的命令當然不一樣的!

用 which 去找出 which

命令:

which which

輸出:

[root@localhost ~]# which which
alias which='alias | /usr/bin/which --tty-only --read-alias --show-dot --show-tilde'
   /usr/bin/which
[root@localhost ~]#

說明:

竟然會有兩個 which ,其中一個是 alias 這就是所謂的『命令別名』,意思是輸入 which 會等於后面接的那串命令!

找出 cd 這個命令

命令:

which cd

輸出:

img

? 說明:

cd 這個常用的命令竟然找不到?。槭裁茨??

這是因為 cd 是bash 內建的命令! 但是 which 默認是找 PATH 內所規(guī)范的目錄,所以當然一定找不到的!

whereis 命令語法

whereis命令只能用于程序名的搜索,而且只搜索二進制文件(參數(shù)-b)、man說明文件(參數(shù)-m)和源代碼文件(參數(shù)-s)。

如果省略參數(shù),則返回所有信息。

和find相比,whereis查找的速度非??欤@是因為linux系統(tǒng)會將 系統(tǒng)內的所有文件都記錄在一個數(shù)據(jù)庫文件中。

當使用whereis和下面即將介紹的locate時,會從數(shù)據(jù)庫中查找數(shù)據(jù),而不是像find命令那樣,通 過遍歷硬盤來查找,效率自然會很高。

但是該數(shù)據(jù)庫文件并不是實時更新,默認情況下時一星期更新一次。

因此,我們在用whereis和locate 查找文件時,有時會找到已經(jīng)被刪除的數(shù)據(jù),或者剛剛建立文件,卻無法查找到,原因就是因為數(shù)據(jù)庫文件沒有被更新。

命令格式

whereis [-bmsu] [BMS 目錄名 -f ] 文件名

命令功能

whereis命令是定位可執(zhí)行文件、源代碼文件、幫助文件在文件系統(tǒng)中的位置。

這些文件的屬性應屬于原始代碼,二進制文件,或是幫助文件。

whereis 程序還具有搜索源代碼、指定備用搜索路徑和搜索不尋常項的能力。

命令參數(shù)

-b 定位可執(zhí)行文件。

-m 定位幫助文件。

-s 定位源代碼文件。

-u 搜索默認路徑下除可執(zhí)行文件、源代碼文件、幫助文件以外的其它文件。

-B 指定搜索可執(zhí)行文件的路徑。

-M 指定搜索幫助文件的路徑。

-S 指定搜索源代碼文件的路徑。

whereis命令使用示例

將和*文件相關的文件都查找出來

命令:

whereis svn

輸出:

[root@localhost ~]# whereis tomcat

tomcat:

[root@localhost ~]# whereis svn

svn: /usr/bin/svn /usr/local/svn /usr/share/man/man1/svn.1.gz

說明:

tomcat沒安裝,找不出來,svn安裝找出了很多相關文件

只將二進制文件 查找出來

命令:

whereis -b svn

輸出:

[root@localhost ~]# whereis -b svn

svn: /usr/bin/svn /usr/local/svn

[root@localhost ~]# whereis -m svn

svn: /usr/share/man/man1/svn.1.gz

[root@localhost ~]# whereis -s svn

svn:

[root@localhost ~]#

說明:

whereis -m svn 查出說明文檔路徑,whereis -s svn 找source源文件。

locate 命令語法

locate 讓使用者可以很快速的搜尋檔案系統(tǒng)內是否有指定的檔案。

其方法是先建立一個包括系統(tǒng)內所有檔案名稱及路徑的數(shù)據(jù)庫,之后當尋找時就只需查詢這個數(shù)據(jù)庫,而不必實際深入檔案系統(tǒng)之中了。

在一般的 distribution 之中,數(shù)據(jù)庫的建立都被放在 crontab 中自動執(zhí)行。

命令格式

Locate [選擇參數(shù)] [樣式]

命令功能

locate命令可以在搜尋數(shù)據(jù)庫時快速找到檔案,數(shù)據(jù)庫由updatedb程序來更新,updatedb是由cron daemon周期性建立的,locate命令在搜尋數(shù)據(jù)庫時比由整個由硬盤資料來搜尋資料來得快,但較差勁的是locate所找到的檔案若是最近才建立或 剛更名的,可能會找不到,在內定值中,updatedb每天會跑一次,可以由修改crontab來更新設定值。(etc/crontab)

locate指定用在搜尋符合條件的檔案,它會去儲存檔案與目錄名稱的數(shù)據(jù)庫內,尋找合乎范本樣式條件的檔案或目錄錄,可以使用特殊字元(如”” 或”?”等)來指定范本樣式,如指定范本為kcpaner, locate會找出所有起始字串為kcpa且結尾為ner的檔案或目錄,如名稱為kcpartner若目錄錄名稱為kcpa_ner則會列出該目錄下包括 子目錄在內的所有檔案。

locate指令和find找尋檔案的功能類似,但locate是透過update程序將硬盤中的所有檔案和目錄資料先建立一個索引數(shù)據(jù)庫,在 執(zhí)行l(wèi)oacte時直接找該索引,查詢速度會較快,索引數(shù)據(jù)庫一般是由操作系統(tǒng)管理,但也可以直接下達update強迫系統(tǒng)立即修改索引數(shù)據(jù)庫。

命令參數(shù)

  • -e 將排除在尋找的范圍之外。
  • -1 如果 是 1.則啟動安全模式。在安全模式下,使用者不會看到權限無法看到 的檔案。這會始速度減慢,因為 locate 必須至實際的檔案系統(tǒng)中取得檔案的 權限資料。
  • -f 將特定的檔案系統(tǒng)排除在外,例如我們沒有到理要把 proc 檔案系統(tǒng)中的檔案 放在資料庫中。
  • -q 安靜模式,不會顯示任何錯誤訊息。
  • -n 至多顯示 n個輸出。
  • -r 使用正規(guī)運算式 做尋找的條件。
  • -o 指定資料庫存的名稱。
  • -d 指定資料庫的路徑
  • -h 顯示輔助訊息
  • -V 顯示程式的版本訊息

locate命令使用示例

查找和pwd****相關的所有文件

命令:

locate pwd

輸出:

peida-VirtualBox ~ # locate pwd

/bin/pwd

/etc/.pwd.lock

/sbin/unix_chkpwd

/usr/bin/pwdx

/usr/include/pwd.h

/usr/lib/python2.7/dist-packages/twisted/python/fakepwd.py

/usr/lib/python2.7/dist-packages/twisted/python/fakepwd.pyc

/usr/lib/python2.7/dist-packages/twisted/python/test/test_fakepwd.py

/usr/lib/python2.7/dist-packages/twisted/python/test/test_fakepwd.pyc

/usr/lib/syslinux/pwd.c32

/usr/share/help/C/empathy/irc-join-pwd.page

/usr/share/help/ca/empathy/irc-join-pwd.page

/usr/share/help/cs/empathy/irc-join-pwd.page

/usr/share/help/de/empathy/irc-join-pwd.page

/usr/share/help/el/empathy/irc-join-pwd.page

 搜索etc目錄下所有以sh開頭的文件

命令:

locate /etc/sh

輸出:

peida-VirtualBox ~ # locate /etc/sh

/etc/shadow

/etc/shadow-

/etc/shells

peida-VirtualBox ~ #

搜索etc目錄下,所有以m開頭的文件

命令:

locate /etc/m

輸出:

peida-VirtualBox ~ # locate /etc/m

/etc/magic

/etc/magic.mime

/etc/mailcap

/etc/mailcap.order

/etc/manpath.config

/etc/mate-settings-daemon

find 命令語法

Linux下find命令在目錄結構中搜索文件,并執(zhí)行指定的操作。

Linux下find命令提供了相當多的查找條件,功能很強大。

由于find具有強大的功能,所以它的選項也很多,其中大部分選項都值得我們花時間來了解一下。

即使系統(tǒng)中含有網(wǎng)絡文件系統(tǒng)( NFS),find命令在該文件系統(tǒng)中同樣有效,只你具有相應的權限。

在運行一個非常消耗資源的find命令時,很多人都傾向于把它放在后臺執(zhí)行,因為遍歷一個大的文件系統(tǒng)可能會花費很長的時間(這里是指30G字節(jié)以上的文件系統(tǒng))。

命令格式

find pathname -options [-print -exec -ok …]

命令功能

用于在文件樹種查找文件,并作出相應的處理

命令參數(shù)

  • pathname: find命令所查找的目錄路徑。例如用.來表示當前目錄,用/來表示系統(tǒng)根目錄。
  • -print: find命令將匹配的文件輸出到標準輸出。
  • -exec: find命令對匹配的文件執(zhí)行該參數(shù)所給出的shell命令。相應命令的形式為’command’ { } ;,注意{ }和\;之間的空格。
  • -ok: 和-exec的作用相同,只不過以一種更為安全的模式來執(zhí)行該參數(shù)所給出的shell命令,在執(zhí)行每一個命令之前,都會給出提示,讓用戶來確定是否執(zhí)行。

命令選項

-name 按照文件名查找文件。

-perm 按照文件權限來查找文件。

-prune 使用這一選項可以使find命令不在當前指定的目錄中查找,如果同時使用-depth選項,那么-prune將被find命令忽略。

-user 按照文件屬主來查找文件。

-group 按照文件所屬的組來查找文件。

-mtime -n +n 按照文件的更改時間來查找文件, - n表示文件更改時間距現(xiàn)在n天以內,+ n表示文件更改時間距現(xiàn)在n天以前。find命令還有-atime和-ctime 選項,但它們都和-m time選項。

-nogroup 查找無有效所屬組的文件,即該文件所屬的組在/etc/groups中不存在。

-nouser 查找無有效屬主的文件,即該文件的屬主在/etc/passwd中不存在。

-newer file1 ! file2 查找更改時間比文件file1新但比文件file2舊的文件。

-type 查找某一類型的文件,諸如:

  • b - 塊設備文件。
  • d - 目錄。
  • c - 字符設備文件。
  • p - 管道文件。
  • l - 符號鏈接文件。
  • f - 普通文件。

-size n:[c] 查找文件長度為n塊的文件,帶有c時表示文件長度以字節(jié)計。-depth:在查找文件時,首先查找當前目錄中的文件,然后再在其子目錄中查找。

-fstype:查找位于某一類型文件系統(tǒng)中的文件,這些文件系統(tǒng)類型通??梢栽谂渲梦募?etc/fstab中找到,該配置文件中包含了本系統(tǒng)中有關文件系統(tǒng)的信息。

-mount:在查找文件時不跨越文件系統(tǒng)mount點。

-follow:如果find命令遇到符號鏈接文件,就跟蹤至鏈接所指向的文件。

-cpio:對匹配的文件使用cpio命令,將這些文件備份到磁帶設備中。

另外,下面三個的區(qū)別:

  • -amin n 查找系統(tǒng)中最后N分鐘訪問的文件
  • -atime n 查找系統(tǒng)中最后n*24小時訪問的文件
  • -cmin n 查找系統(tǒng)中最后N分鐘被改變文件狀態(tài)的文件
  • -ctime n 查找系統(tǒng)中最后n*24小時被改變文件狀態(tài)的文件
  • -mmin n 查找系統(tǒng)中最后N分鐘被改變文件數(shù)據(jù)的文件
  • -mtime n 查找系統(tǒng)中最后n*24小時被改變文件數(shù)據(jù)的文件

find命令使用示例

查找指定時間內修改過的文件

命令:

find -atime -2

輸出:

[root@peidachang ~]# find -atime -2

.

./logs/monitor

./.bashrc

./.bash_profile

./.bash_history

說明:

超找48小時內修改過的文件

根據(jù)關鍵字查找

命令:

find . -name "*.log"

輸出:

[root@localhost test]# find . -name "*.log" 

./log_link.log

./log2014.log

./test4/log3-2.log

./test4/log3-3.log

./test4/log3-1.log

./log2013.log

./log2012.log

./log.log

./test5/log5-2.log

./test5/log5-3.log

./test5/log.log

./test5/log5-1.log

./test5/test3/log3-2.log

./test5/test3/log3-3.log

./test5/test3/log3-1.log

./test3/log3-2.log

./test3/log3-3.log

./test3/log3-1.log

說明:

在當前目錄查找 以.log結尾的文件。 ". "代表當前目錄

按照目錄或文件的權限來查找文件

命令:

find /opt/soft/test/ -perm 777

輸出:

[root@localhost test]# find /opt/soft/test/ -perm 777

/opt/soft/test/log_link.log

/opt/soft/test/test4

/opt/soft/test/test5/test3

/opt/soft/test/test3

說明:

查找/opt/soft/test/目錄下 權限為 777的文件

按類型查找

命令:

find . -type f -name "*.log"

輸出:

[root@localhost test]# find . -type f -name "*.log"

./log2014.log

./test4/log3-2.log

./test4/log3-3.log

./test4/log3-1.log

./log2013.log

./log2012.log

./log.log

./test5/log5-2.log

./test5/log5-3.log

./test5/log.log

./test5/log5-1.log

./test5/test3/log3-2.log

./test5/test3/log3-3.log

./test5/test3/log3-1.log

./test3/log3-2.log

./test3/log3-3.log

./test3/log3-1.log

[root@localhost test]#

說明:

查找當目錄,以.log結尾的普通文件

查找當前所有目錄并排序

命令:

find . -type d | sort

輸出:

[root@localhost test]# find . -type f -name "*.log"

./log2014.log

./test4/log3-2.log

./test4/log3-3.log

./test4/log3-1.log

./log2013.log

./log2012.log

./log.log

./test5/log5-2.log

./test5/log5-3.log

./test5/log.log

./test5/log5-1.log

./test5/test3/log3-2.log

./test5/test3/log3-3.log

./test5/test3/log3-1.log

./test3/log3-2.log

./test3/log3-3.log

./test3/log3-1.log

[root@localhost test]#

按大小查找文件

命令:

find . -size +1000c -print

輸出:

[root@localhost test]# find . -size +1000c -print

.

./test4

./scf

./scf/lib

./scf/service

./scf/service/deploy

./scf/service/deploy/product

./scf/service/deploy/info

./scf/doc

./scf/bin

./log2012.log

./test5

./test5/test3

./test3

[root@localhost test]#

說明:

查找當前目錄大于1K的文件

find命令之exec使用示例

find是我們很常用的一個Linux命令,但是我們一般查找出來的并不僅僅是看看而已,還會有進一步的操作,這個時候exec的作用就顯現(xiàn)出來了。

exec解釋:

-exec 參數(shù)后面跟的是command命令,它的終止是以;為結束標志的,所以這句命令后面的分號是不可缺少的,考慮到各個系統(tǒng)中分號會有不同的意義,所以前面加反斜杠。

{} 花括號代表前面find查找出來的文件名。

使用find時,只要把想要的操作寫在一個文件里,就可以用exec來配合find查找,很方便的。

在有些操作系統(tǒng)中只允許-exec選項執(zhí)行諸如l s或ls -l這樣的命令。

大多數(shù)用戶使用這一選項是為了查找舊文件并刪除它們。

建議在真正執(zhí)行rm命令刪除文件之前,最好先用ls命令看一下,確認它們是所要刪除的文件。

exec選項后面跟隨著所要執(zhí)行的命令或腳本,然后是一對兒{ },一個空格和一個\,最后是一個分號。為了使用exec選項,必須要同時使用print選項。

如果驗證一下find命令,會發(fā)現(xiàn)該命令只輸出從當前路徑起的相對路徑及文件名。

ls -l命令放在find命令的-exec選項中

命令:

find . -type f -exec ls -l {} \;

輸出:

[root@localhost test]# find . -type f -exec ls -l {} \; 

-rw-r--r-- 1 root root 127 10-28 16:51 ./log2014.log

-rw-r--r-- 1 root root 0 10-28 14:47 ./test4/log3-2.log

-rw-r--r-- 1 root root 0 10-28 14:47 ./test4/log3-3.log

-rw-r--r-- 1 root root 0 10-28 14:47 ./test4/log3-1.log

-rw-r--r-- 1 root root 33 10-28 16:54 ./log2013.log

-rw-r--r-- 1 root root 302108 11-03 06:19 ./log2012.log

-rw-r--r-- 1 root root 25 10-28 17:02 ./log.log

-rw-r--r-- 1 root root 37 10-28 17:07 ./log.txt

-rw-r--r-- 1 root root 0 10-28 14:47 ./test3/log3-2.log

-rw-r--r-- 1 root root 0 10-28 14:47 ./test3/log3-3.log

-rw-r--r-- 1 root root 0 10-28 14:47 ./test3/log3-1.log

[root@localhost test]#

說明:

上面的例子中,find命令匹配到了當前目錄下的所有普通文件,并在-exec選項中使用ls -l命令將它們列出。

在目錄中查找更改時間在n日以前的文件并刪除它們

命令:

find . -type f -mtime +14 -exec rm {} \; 

輸出:

[root@localhost test]# ll

總計 328

-rw-r--r-- 1 root root 302108 11-03 06:19 log2012.log

-rw-r--r-- 1 root root   33 10-28 16:54 log2013.log

-rw-r--r-- 1 root root  127 10-28 16:51 log2014.log

lrwxrwxrwx 1 root root   7 10-28 15:18 log_link.log -> log.log

-rw-r--r-- 1 root root   25 10-28 17:02 log.log

-rw-r--r-- 1 root root   37 10-28 17:07 log.txt

drwxr-xr-x 6 root root  4096 10-27 01:58 scf

drwxrwxrwx 2 root root  4096 10-28 14:47 test3

drwxrwxrwx 2 root root  4096 10-28 14:47 test4

[root@localhost test]# find . -type f -mtime +14 -exec rm {} \;

[root@localhost test]# ll

總計 312

-rw-r--r-- 1 root root 302108 11-03 06:19 log2012.log

lrwxrwxrwx 1 root root   7 10-28 15:18 log_link.log -> log.log

drwxr-xr-x 6 root root  4096 10-27 01:58 scf

drwxrwxrwx 2 root root  4096 11-12 19:32 test3

drwxrwxrwx 2 root root  4096 11-12 19:32 test4

[root@localhost test]# 

說明

在shell中用任何方式刪除文件之前,應當先查看相應的文件,一定要小心!

當使用諸如mv或rm命令時,可以使用-exec選項的安全模式。它將在對每個匹配到的文件進行操作之前提示你。

在目錄中查找更改時間在n日以前的文件并刪除它們**,**在刪除之前先給出提示

命令:

find . -name "*.log" -mtime +5 -ok rm {} \;

輸出:

[root@localhost test]# ll

總計 312

-rw-r--r-- 1 root root 302108 11-03 06:19 log2012.log

lrwxrwxrwx 1 root root   7 10-28 15:18 log_link.log -> log.log

drwxr-xr-x 6 root root  4096 10-27 01:58 scf

drwxrwxrwx 2 root root  4096 11-12 19:32 test3

drwxrwxrwx 2 root root  4096 11-12 19:32 test4

[root@localhost test]# find . -name "*.log" -mtime +5 -ok rm {} \;

< rm ... ./log_link.log > ? y

< rm ... ./log2012.log > ? n

[root@localhost test]# ll

總計 312

-rw-r--r-- 1 root root 302108 11-03 06:19 log2012.log

drwxr-xr-x 6 root root  4096 10-27 01:58 scf

drwxrwxrwx 2 root root  4096 11-12 19:32 test3

drwxrwxrwx 2 root root  4096 11-12 19:32 test4

[root@localhost test]#

說明

在上面的例子中, find命令在當前目錄中查找所有文件名以.log結尾、更改時間在5日以上的文件,并刪除它們,只不過在刪除之前先給出提示。 按y鍵刪除文件,按n鍵不刪除。

-exec中使用grep命令

命令:

find /etc -name "passwd*" -exec grep "root" {} \;

輸出:

[root@localhost test]# find /etc -name "passwd*" -exec grep "root" {} \;

root:x:0:0:root:/root:/bin/bash

root:x:0:0:root:/root:/bin/bash

[root@localhost test]#

說明:

任何形式的命令都可以在-exec選項中使用。 在上面的例子中我們使用grep命令。

find命令首先匹配所有文件名為“ passwd*”的文件,例如passwd、passwd.old、passwd.bak,然后執(zhí)行grep命令看看在這些文件中是否存在一個root用戶。

查找文件移動到指定目錄

命令:

find . -name "*.log" -exec mv {} .. \;

輸出:

[root@localhost test]# ll

總計 12drwxr-xr-x 6 root root 4096 10-27 01:58 scf

drwxrwxr-x 2 root root 4096 11-12 22:49 test3

drwxrwxr-x 2 root root 4096 11-12 19:32 test4

[root@localhost test]# cd test3/

[root@localhost test3]# ll

總計 304

-rw-r--r-- 1 root root 302108 11-03 06:19 log2012.log

-rw-r--r-- 1 root root   61 11-12 22:44 log2013.log

-rw-r--r-- 1 root root   0 11-12 22:25 log2014.log

[root@localhost test3]# find . -name "*.log" -exec mv {} .. \;

[root@localhost test3]# ll

總計 0[root@localhost test3]# cd ..

[root@localhost test]# ll

總計 316

-rw-r--r-- 1 root root 302108 11-03 06:19 log2012.log

-rw-r--r-- 1 root root   61 11-12 22:44 log2013.log

-rw-r--r-- 1 root root   0 11-12 22:25 log2014.log

drwxr-xr-x 6 root root  4096 10-27 01:58 scf

drwxrwxr-x 2 root root  4096 11-12 22:50 test3

drwxrwxr-x 2 root root  4096 11-12 19:32 test4

[root@localhost test]#

用exec選項執(zhí)行cp命令

命令:

find . -name "*.log" -exec cp {} test3 \;

輸出:

[root@localhost test3]# ll

總計 0[root@localhost test3]# cd ..

[root@localhost test]# ll

總計 316

-rw-r--r-- 1 root root 302108 11-03 06:19 log2012.log

-rw-r--r-- 1 root root   61 11-12 22:44 log2013.log

-rw-r--r-- 1 root root   0 11-12 22:25 log2014.log

drwxr-xr-x 6 root root  4096 10-27 01:58 scf

drwxrwxr-x 2 root root  4096 11-12 22:50 test3

drwxrwxr-x 2 root root  4096 11-12 19:32 test4

[root@localhost test]# find . -name "*.log" -exec cp {} test3 \;

cp: “./test3/log2014.log” 及 “test3/log2014.log” 為同一文件

cp: “./test3/log2013.log” 及 “test3/log2013.log” 為同一文件

cp: “./test3/log2012.log” 及 “test3/log2012.log” 為同一文件

[root@localhost test]# cd test3

[root@localhost test3]# ll

總計 304

-rw-r--r-- 1 root root 302108 11-12 22:54 log2012.log

-rw-r--r-- 1 root root   61 11-12 22:54 log2013.log

-rw-r--r-- 1 root root   0 11-12 22:54 log2014.log

[root@localhost test3]#

到此這篇關于Linux文件查找命令總結(上篇)的文章就介紹到這了,下篇的內容請搜索腳本之家以前的文章或繼續(xù)瀏覽下面的相關文章希望大家以后多多支持腳本之家!

相關文章

  • linux中文件權限的使用以及修改方式

    linux中文件權限的使用以及修改方式

    這篇文章主要介紹了linux中文件權限的使用以及修改方式,具有很好的參考價值,希望對大家有所幫助。如有錯誤或未考慮完全的地方,望不吝賜教
    2023-07-07
  • 11個有用的Linux命令

    11個有用的Linux命令

    Linux命令行吸引了大多數(shù)Linux愛好者。一個正常的Linux用戶一般掌握大約50-60個命令來處理每日的任務。今天為你解釋下面幾個命令:sudo、python、mtr、Ctrl+x+e、nl、shuf、shuf、last。
    2013-10-10
  • Linux 下載安裝VSCode 使用編程輸出當前時間的方法

    Linux 下載安裝VSCode 使用編程輸出當前時間的方法

    這篇文章主要介紹了Linux 下載安裝VSCode 使用編程輸出當前時間,本文通過圖文并茂的形式給大家介紹的非常詳細,對大家的學習或工作具有一定的參考借鑒價值,需要的朋友可以參考下
    2020-06-06
  • linux更改目錄顯示顏色實例詳解

    linux更改目錄顯示顏色實例詳解

    這篇文章主要介紹了linux更改目錄顯示顏色實例詳解的相關資料,需要的朋友可以參考下
    2017-04-04
  • Yum安裝中出現(xiàn)錯誤mirrorlist.txt的解決方法

    Yum安裝中出現(xiàn)錯誤mirrorlist.txt的解決方法

    前幾天在使用Yum install命令安裝軟件的時候一直提示一個mirrorlist.txt錯誤,通過查找相關的資料現(xiàn)在找到了解決的方法,所以這篇文章就整理出來和大家分享一下,有同樣遇到這個問題的朋友們可以參考借鑒下。
    2016-10-10
  • Linux中selinux基礎配置教程詳解

    Linux中selinux基礎配置教程詳解

    SELinux(Security-Enhanced Linux)的簡單配置,涉及SELinux的工作模式、配置文件修改、查看和修改上下文信息,以及恢復文件或目錄的上下文信息。這篇文章主要介紹了Linux中selinux基礎配置,需要的朋友可以參考下
    2018-11-11
  • 詳解Ubuntu下配置samba實現(xiàn)文件夾共享

    詳解Ubuntu下配置samba實現(xiàn)文件夾共享

    這篇文章主要介紹了詳解Ubuntu下配置samba實現(xiàn)文件夾共享的相關資料,需要的朋友可以參考下
    2017-03-03
  • Ubuntu 20.04 CUDA&cuDNN安裝方法(圖文教程)

    Ubuntu 20.04 CUDA&cuDNN安裝方法(圖文教程)

    這篇文章主要介紹了Ubuntu 20.04 CUDA&cuDNN安裝方法(圖文教程),文中通過圖文代碼介紹的非常詳細,對大家的學習或者工作具有一定的參考學習價值,需要的朋友們下面隨著小編來一起學習學習吧
    2020-07-07
  • CentOS7 systemd添加自定義系統(tǒng)服務的方法

    CentOS7 systemd添加自定義系統(tǒng)服務的方法

    這篇文章主要介紹了CentOS7 systemd添加自定義系統(tǒng)服務,小編覺得挺不錯的,現(xiàn)在分享給大家,也給大家做個參考。一起跟隨小編過來看看吧
    2019-03-03
  • Linux通過設備號找到設備的方法

    Linux通過設備號找到設備的方法

    所有的Linux設備文件均位于/dev目錄下,是根(/)文件系統(tǒng)的一個組成部分,因為這些設備文件在操作系統(tǒng)啟動過程中必須可以使用。接下來通過本文給大家介紹Linux通過設備號找到設備的方法,感興趣的朋友一起看看吧
    2018-07-07

最新評論