When editing a file with VIM, exit the terminal in time out, or close the terminal directly without quitting, resulting in an abnormal exit scenario. The following error will be reported when editing again:
E325: ATTENTION
Found a swap file by the name “.test.txt. SWP “
owned by: root dated: Thu Jun 27 14:38:06 2019
file name: ~root/test.txt
modified: YES
user name: root host name: VMcentos
process ID: 20994
While opening file “test.txt”
dated: Thu Jun 27 13:42:52 2019
(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,
(2) An edit session for this file comedown.
If this is the case,
to recover (see “:help recovery”).
If you did this already, delete the swap file “.test.txp “
to avoid this message.
Swap file “.test.txt.swp” already exists!
[O]pen Read-Only, (E)dit anyway, (R)ecover, (D)elete it, (Q)uit, (A)bort:
Use LL-A command to check, there is indeed a hidden file, originally when editing the file, the system will copy a temporary file. Test.txt.swap, also will edit this file, the temporary file will be written to the official file when executing: W, the temporary file will be deleted when executing: Q.
Solutions:
Delete the file.test.txt.swap, rm.test.txt.swap
E325: ATTENTION
Found a swap file by the name “.test.txt. SWP “
owned by: root dated: Thu Jun 27 14:38:06 2019
file name: ~root/test.txt
modified: YES
user name: root host name: VMcentos
process ID: 20994
While opening file “test.txt”
dated: Thu Jun 27 13:42:52 2019
(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,
(2) An edit session for this file comedown.
If this is the case,
to recover (see “:help recovery”).
If you did this already, delete the swap file “.test.txp “
to avoid this message.
Swap file “.test.txt.swp” already exists!
[O]pen Read-Only, (E)dit anyway, (R)ecover, (D)elete it, (Q)uit, (A)bort:
Use LL-A command to check, there is indeed a hidden file, originally when editing the file, the system will copy a temporary file. Test.txt.swap, also will edit this file, the temporary file will be written to the official file when executing: W, the temporary file will be deleted when executing: Q.
Solutions:
Delete the file.test.txt.swap, rm.test.txt.swap
Read More:
- After editing a file with the VIM command in xshell, the ESC key cannot be output,,,
- [Linux] e297: write error in swap file solution
- Save file and exit command of vim
- write error in swap file problem solving
- [solution] install youcompleteme through VIM plug-in manager VIM plug, including ycmd server shutdown solution
- Ubuntu 64 prompts bash: no such file or directory file exists
- Fileexistserror: [winerror 183] cannot create a file when it already exists. File rename code attached
- Failed to extend swap file from 0 kb to xxx kb.
- VIM setting file encoding format
- Error: eexist: file already exists
- Differences between VI and VIM in Linux
- Fatal: unable to create ‘project_ path/.git/ index.lock ‘: File exists.
- Swap off failed: cannot allocate memory
- Fileexistserror: [winerror 183] cannot create a file when it already exists. : ‘D:/tjn/tra
- ln: failed to create symbolic link ‘/usr/bin/pip’: File exists
- Multi-object editing not supported error resolution
- Java – read all the files and folders in a certain directory and three methods to get the file name from the file path
- AS3.5 Error gradle project sync failed.Basic functionality(e.g.editing,debugging) will not work
- EXSI6.0 virtual machine swap error causes it to fail to start
- Hot Swap failed:add method not implemented