問題現象
使用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
~
~
~