)ubuntu簡單命令

來源:互聯網
上載者:User
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
裝機必備 !!!!   安裝解碼器、flashplayer、java虛擬機器、微可下載字型 :
sudo apt-get install ubuntu-restricted-extras

@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
安裝、卸載軟體:

自動搜尋安裝、卸載軟體 :新立德軟體包管理器    搜尋名稱   安裝、卸載

或者

終端輸入
sudo apt-get install  軟體名稱
=========================
 sudo -sh   
; 切換到 root 帳號:
安裝軟體 apt-get install softname1 softname2 softname3……
卸載軟體 apt-get remove softname1 softname2 softname3……
卸載並清除配置 apt-get remove --purge softname1
更新軟體資訊資料庫 apt-get update
進行系統升級 apt-get upgrade
搜尋軟體包 apt-cache search softname1 softname2 softname3……

安裝deb軟體包 dpkg -i xxx.deb
刪除軟體包 dpkg -r xxx.deb
連同設定檔一起刪除 dpkg -r --purge xxx.deb
查看軟體包資訊 dpkg -info xxx.deb
查看檔案拷貝詳情 dpkg -L xxx.deb
查看系統中已安裝軟體包資訊 dpkg -l
重新設定軟體包 dpkg-reconfigure xxx

在使用完apt後,系統下載的deb包會留存在硬碟裡,我們可以把它們刪除安裝檔案,釋放硬碟空間。
sudo apt-get clean

@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@

 修改系統更新源:
sudo gedit /etc/apt/sources.list

中國國內推薦!!!     常州伺服器     (經我驗證,速度超快)

deb http://ubuntu.cn99.com/ubuntu/ breezy main restricted universe multiverse
deb http://ubuntu.cn99.com/ubuntu/ breezy-updates main restricted universe multiverse
deb http://ubuntu.cn99.com/ubuntu/ breezy-security main restricted universe multiverse
deb http://ubuntu.cn99.com/ubuntu/ breezy-backports main restricted universe multiverse
deb http://ubuntu.cn99.com/ubuntu-cn/ breezy main restricted universe multiverse
deb http://ubuntu.cn99.com/backports/ breezy-extras main restricted universe multiverse

 

@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@

sudo apt-get install rar unrar   ;安裝rar壓縮、解壓工具

@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@

 

@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
sudo gedit /etc/fstab     更改ubuntu啟動時的 檢查分區情況
  對應的 fat&ntfs 分區設定   pass=0 即是不檢查    可提高啟動速度 !!

@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@

顯卡驅動安裝

feisty裡面顯卡驅動的安裝也是相當簡單的事情,進入“系統”->“系統管理”->“受限驅動管理器”
找到你的顯卡,把那個框點成對號,會提示你安裝顯卡驅動,然後按照提示一步一步安裝完畢,重啟即可。

@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@

在bash中提示符是通過一個環境變數$PS1指定的。用export $PS1查看現在的值,比較直觀常用的提示符可以設定為export PS1=“[\u@\h \W]$”。其中\u代表使用者名稱,\h代表主機名稱,\W代表當前工作目錄的最後一層,如果是普通使用者$則顯示$,root使用者顯示#。

@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@

運行更新時提示:
Fetched 5B in 1s (5B/s)
E: Could not get lock /var/lib/dpkg/lock - open (11 Resource temporarily unavailable)
E: Unable to lock the administration directory (/var/lib/dpkg/), is another process using it?
e:無法獲得鎖/var/lib/dpkg/鎖定open(11資源暫時無法獲得E組): 無法鎖定管理目錄(/var/lib/dpkg/),是另一進程使用嗎?

這個意思是 :  如果你在終端使用了apt,或者你開啟了新德立,再運行添加和刪除的話,是打不開的,三者只能運行一個.
is another process using it?  另一個進程在使用嗎?   好像你已經開了三個其中一個了.

This is a major failure of your software management system. Please check for broken packages with synaptic, check the file permissions and correctness of the file '/etc/apt/sources.list' and reload the software information with: 'sudo apt-get update' and 'sudo apt-get install -f'
意思:  
這是一個重大的失敗,你的軟體管理系統. 請檢查損壞的軟體包突觸, 查閱檔案許可權和正確性檔案'/etc/apt/sources.list』及重新整理軟體的資訊: '用sudoapt-getupdate'和'用sudoapt-getinstall-f'

這是一個依賴問題,首先檢查/etc/apt/sources.list裡面的源.請把zh-cn的源前面加個"#"號,表示忽略.
如果你裝某個軟體無法依賴檢查,請你使用命令:用sudo apt-getupdate'和'用sudo apt-getinstall-f

比如這個JAVA是你在官方下載的DEB包,你用dpkg -i安裝時出現錯誤,那你就用sudo apt-getinstall-f解決依賴關係,然後它會自動安裝上JAVA.

建議使用"GDebi軟體包安裝程式,"系統內建的,那樣它自會檢查依賴性,並且可以看到所安裝的檔案路徑

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.