Technology Sharing

vim command not found, and yum install vim failed to install vim

2024-07-12

한어Русский языкEnglishFrançaisIndonesianSanskrit日本語DeutschPortuguêsΕλληνικάespañolItalianoSuomalainenLatina

vim command not found, and yum installation of vim failed

insert image description here

1. wget updates yum cloud resources. This update is Huawei cloud image resources.

wget -O /etc/yum.repos.d/CentOS-Base.repo https://mirrors.huaweicloud.com/repository/conf/CentOS-7-anon.repo
  • 1

insert image description here
wget reported that the command was not found, please check the articleLinux wget reported command not found

2. Clean up the yum cache

yum clean all
  • 1

insert image description here

3. Update yum cache

yum makecache
  • 1

insert image description here

4. Install vim using yum

yum install vim
  • 1

insert image description here
5. Test vim statements

vim /etc/profile
  • 1

insert image description here