歡迎來到Linux教程網
Linux教程網
Linux教程網
Linux教程網
Linux教程網 >> Linux基礎 >> Linux教程 >> 20個最受歡迎的Linux命令,你同意麼?

20個最受歡迎的Linux命令,你同意麼?

日期:2017/2/28 14:31:13   编辑:Linux教程

本文根據commandlinefu網站的歷史排名,篩選出了前20個得票最高的Linux命令。看看你都能熟練使用了嗎?

1. 以 root 帳戶執行上一條命令

  1. sudo !!

2. 利用 Python 搭建一個簡單的 Web 服務器

可通過 http://$HOSTNAME:8000訪問

  1. python -m SimpleHTTPServer

3. 切換到上一次訪問的目錄

  1. cd -

4. 將上一條命令中的 foo 替換為 bar,並執行

  1. ^foo^bar

5. traceroute + ping

  1. mtr google.com

6. 快速調用一個編輯器來編寫一個命令

  1. ctrl-x e

7. 執行一個命令,但不保存在命令歷史記錄中

  1. <space>command

8. 重新初始化終端

  1. reset

9. 調出上次命令使用的參數

  1. 'ALT+.'or'<ESC> .'

10. 以更加清晰的方式顯示當前系統掛載的文件系統

  1. mount | column -t

11. 在給定的時間執行命令

  1. echo "ls -l"| at midnight

12. 通過DNS控制台查詢維基百科

  1. dig +short txt <keyword>.wp.dg.cx

13. 從80端口向你本地的2001端口開啟隧道

  1. ssh -N -L2001:localhost:80 somemachine

14. 快速訪問ASCII表

  1. man ascii

15. 獲取你的外部IP地址

  1. curl ifconfig.me

16. !! 表示重復執行上一條命令,並用 :gs/foo/bar 進行替換操作

  1. !!:gs/foo/bar

17. 輸出你的麥克風到遠程機器的揚聲器

  1. dd if=/dev/dsp | ssh -c arcfour -C username@host dd of=/dev/dsp

18. 掛載一個臨時的內存分區

  1. mount -t tmpfs tmpfs /mnt -o size=1024m

19. 以SSH方式掛載目錄/文件系統

  1. sshfs name@server:/path/to/folder /path/to/mount/point

20. 通過curl更新Twitter

  1. curl -u user:pass-d status="Tweeting from the shell"<a href="http://twitter.com/statuses/update.xml">http://twitter.com/statuses/update.xml</a>

via : http://code.csdn.net/news/2819566

Linux命令之cd http://www.linuxidc.com/Linux/2013-05/83948.htm

Linux命令之cat http://www.linuxidc.com/Linux/2013-05/83947.htm

Linux命令之alias/unalias http://www.linuxidc.com/Linux/2013-05/83946.htm

Linux命令解析:su root和su -root http://www.linuxidc.com/Linux/2013-04/82564.htm

Linux命令之 交互式輸入read http://www.linuxidc.com/Linux/2013-03/81594.htm

Copyright © Linux教程網 All Rights Reserved