zoukankan      html  css  js  c++  java
  • 解决vim无法编辑文件的问题

    问题现象

    使用vim编辑文件的时候,无法进入编辑页面

    [root@localhost centos]# vim Dockerfile
    [root@localhost centos]# 

    解决办法:

    1、重新安装vim,并尝试编辑文件

    [root@localhost ~]# yum reinstall vim -y
     
    [root@localhost ~]# vim Dockerfile
    vim: error while loading shared libraries: /lib64/libgpm.so.2: file too short

    2、查看库文件所属的包

    [root@localhost ~]# yum provides libgpm.so.2
    Loaded plugins: fastestmirror
    Loading mirror speeds from cached hostfile
     * base: mirrors.aliyun.com
     * extras: mirrors.aliyun.com
     * updates: mirrors.aliyun.com
    gpm-libs-1.20.7-6.el7.i686 : Dynamic library for for the gpm
    Repo        : base
    Matched from:
    Provides    : libgpm.so.2

    3、重新安装对应的包

    [root@localhost ~]# yum reinstall gpm-libs -y

    4、再次编辑文件依然报错

    [root@localhost ~]# vim Dockerfile
    vim: error while loading shared libraries: /usr/lib64/perl5/CORE/libperl.so: file too short

    5、依然按上面的方法重新安装对应的包

    [root@localhost ~]# yum reinstall perl-libs -y

    6、再次尝试编辑,问题解决

    [root@localhost ~]# vim Dockerfile
    
    ~                                                                                                                                                             
    ~                                                                                                                                                             
    ~                  
  • 相关阅读:
    LeetCode 100. 相同的树(Same Tree) 2
    LeetCode 680. 验证回文字符串 Ⅱ(Valid Palindrome II) 1
    MySQL索引操作
    MySQL数据库的一些方法使用
    Anaconda安装新模块
    源码下载
    mongodb内建角色
    windows server 2008开启共享文件设置
    MySQL配置说明
    MySQL的连接数
  • 原文地址:https://www.cnblogs.com/zh-dream/p/14903705.html
Copyright © 2011-2022 走看看