llinux菜鳥學習

2022-08-27 17:54:12 字數 578 閱讀 8291

1、sudo su - 臨時獲得root許可權,使用的密碼是使用者的密碼,而不是root的密碼

2、/與~:/是根目錄,~是/root(root身份登入)或者/home/name(普通使用者登入)

3、ls -al:看隱藏檔案

5、/etc/profile與$home/.bash_profile:

/etc/profile:為系統的每乙個使用者設定環境資訊,當使用者第一次登入時,該檔案被執行

$home/.bash_profile:每個使用者都可以使用該檔案輸入專用於自己使用的shell資訊,當使用者登入時,該檔案僅僅執行一次。

6、source  ~/.base_profile:

source 在當前bash環境下執行命令(bash——乙個為gun編寫的unix shell,bourne-again shell)

7、linux版本

redhat(紅帽)底下發行版比較多的是ubantu(烏班圖)和cantos(community enterprise operating system 社群企業作業系統)。

8、linux下檢視系統版本:

cat /etc/redhat -release

llinux基礎命令

一 ls 命令 1.root chy ls l 列出檔案的詳細資訊 總用量 4 rw 1 root root 1695 5月 26 03 22 anaconda ks.cfg 第一列是許可權,第二列是有幾個檔案使用了inode 第三列是所有者 第四列是所屬組。第五列是檔案的大小 第六列是檔案建立的時...

llinux 壓縮 解壓

1.zip 1 將資料夾 mydir 壓縮為 mydir.zip zip r mydir.zip mydir 2 將檔案 one two 壓縮到 ot.zip zip r ot.zip one two 3 將 mydir.zip 解壓為 mydir a.unzip mydir.zip d anoth...

llinux學習之find和touch指令

1.a c mtime的意義,如何使用 touch更改 linux的 touch 命令不常用,一般在使 用 make 的時候可能會用到,用來修改 件時間戳,或者新建乙個不存在的檔案。而每個檔案在 linux 下面都會記錄許多時間引數,其實是有三個主要的變動時間。1 a access time ati...