開啟Vi編輯器出現E325: ATTENTION的解決方案

來源:互聯網
上載者:User

開啟Vi編輯器出現E325: ATTENTION的解決方案

當開啟Vi編輯器時出現以下的提示時不要著急
E325: ATTENTION
Found a swap file by the name "/etc/.profile.swp"
owned by: root  dated: Wed Jul 14 10:01:10 2010
file name: /etc/profile
modified: YES
user name: root  host name: zhaoyang-laptop
process ID: 1934
While opening file "/etc/profile"
dated: Thu Apr 29 20:18:30 2010
(1) Another program may be editing the same file.
If this is the case, be careful not to end up with two
different instances of the same file when making changes.
Quit, or continue with caution.
(2) An edit session for this file crashed.
If this is the case, use ":recover" or "vim -r /etc/profile"
to recover the changes (see ":help recovery").
If you did this already, delete the swap file "/etc/.profile.swp"
to avoid this message.
"/etc/profile" 28 lines, 497 characters
Press ENTER or type command to continue
E325: ATTENTIONFound a swap file by the name "/etc/.profile.swp"          owned by: root  dated: Wed Jul 14 10:01:10 2010        file name: /etc/profile          modified: YES        user name: root  host name: zhaoyang-laptop        process ID: 1934While opening file "/etc/profile"            dated: Thu Apr 29 20:18:30 2010 (1) Another program may be editing the same file.    If this is the case, be careful not to end up with two    different instances of the same file when making changes.    Quit, or continue with caution. (2) An edit session for this file crashed.    If this is the case, use ":recover" or "vim -r /etc/profile"    to recover the changes (see ":help recovery").    If you did this already, delete the swap file "/etc/.profile.swp"    to avoid this message."/etc/profile" 28 lines, 497 charactersPress ENTER or type command to continue 
我們按斷行符號進入vi編輯器輸入:q!退出vi編輯器,在終端輸入rm -f /etc/.profile.swp斷行符號,再一次進入vi編輯器發現以前的提示消失。

===================

總結一下:可以分2部簡單的操作:(1)ls -a 列舉所有的內容 (2)rm對應的.swp檔案。

Linux下Vi替換字元命令操作執行個體

Vi文法高亮設定

Linux下Vi編輯器的使用介紹

Linux下Vi替換字元命令操作執行個體

更多Vi請參考:

相關文章

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在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.