当前位置:网站首页>VIM, another program may be editing the same file If this is the solution of the case
VIM, another program may be editing the same file If this is the solution of the case
2022-07-04 12:36:00 【Menon research monk】
The problem is shown in
adopt vim perhaps vi When editing the file, the following appears: :
The terminal displays as follows :
Found a swap file by the name "/mydata/mysql/conf/.my.conf.swp"
owned by: root dated: Sat Jul 02 12:52:53 2022
file name: /mydata/mysql/conf/my.conf
modified: YES
user name: root host name: xx
process ID: xx
While opening file "/mydata/mysql/conf/my.conf"
CANNOT BE FOUND
(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 /mydata/mysql/conf/my.conf"
to recover the changes (see ":help recovery").
If you did this already, delete the swap file "/mydata/mysql/conf/.my.conf.swp"
to avoid this message.
Swap file "/mydata/mysql/conf/.my.conf.swp" already exists!
[O]pen Read-Only, (E)dit anyway, (R)ecover, (D)elete it, (Q)uit, (A)bort:
The screenshot is as follows :
2. Principle analysis
stay linux In order to ensure security , If the document is inconsistent
For example, multiple people edit this file, resulting in different files 、 Last edit did not exit normally
Will generate a file suffix swp File format ( Temporary exchange file , Main backup buffer contents )
The way of saving or writing files is correct , commonly swp Format files will be automatically deleted , If there is an error in writing , Temporary files will always exist , When you edit it again, you will always point to changing the file
Delete it and re edit it or restore it and re edit it
3. resolvent
adopt ls -al When viewing all the files
You can see swp Format ( Hide temporary files , Temporary buffer )
vim Edit the prompt that appears :
Solve it according to the following tips
If the file is not important , direct q sign out ,rm -rf Delete it and try again
边栏推荐
- Introduction to random and threadlocalrandom analysis
- Possible to restore a backup of SQL Server 2014 on SQL Server 2012?
- netstat
- nn. Exploration and experiment of batchnorm2d principle
- Flet教程之 按钮控件 ElevatedButton入门(教程含源码)
- Iterm tab switching order
- DDS-YYDS
- Tableau makes data summary after linking the database, and summary exceptions occasionally occur.
- Star leap plan | new projects are continuously being recruited! MSR Asia MSR Redmond joint research program invites you to apply!
- Practice of retro SOAP Protocol
猜你喜欢
The database connection code determines whether the account password is correct, but the correct account password always jumps to the failure page with wrong account password
SAP ui5 date type sap ui. model. type. Analysis of the display format of date
22 API design practices
Bottom Logic -- Mind Map
昨天的事情想说一下
Introduction to random and threadlocalrandom analysis
[Yunju entrepreneurial foundation notes] Chapter II entrepreneur test 7
[the way of programmer training] - 2 Perfect number calculation
DC-5靶机
Communication tutorial | overview of the first, second and third generation can bus
随机推荐
Introduction to random and threadlocalrandom analysis
MySQL performance optimization index
When synchronized encounters this thing, there is a big hole, pay attention!
World document to picture
[Yunju entrepreneurial foundation notes] Chapter II entrepreneur test 20
[Yunju entrepreneurial foundation notes] Chapter II entrepreneur test 24
Global and Chinese markets of NOx analyzers 2022-2028: Research Report on technology, participants, trends, market size and share
Awk getting started to proficient series - awk quick start
Communication tutorial | overview of the first, second and third generation can bus
vim 出现 Another program may be editing the same file. If this is the case 的解决方法
[ES6] template string: `string`, a new symbol in es2015
Btrace tells you how to debug online without restarting the JVM
The solution of permission denied
Global and Chinese markets for environmental disinfection robots 2022-2028: Research Report on technology, participants, trends, market size and share
Method of setting default items in C # ComboBox control code
MySQL advanced review
Enter the smart Park, and change begins here
Decrypt the advantages of low code and unlock efficient application development
Abnormal mode of ARM processor
Uva536 binary tree reconstruction tree recovery