LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 10-31-2015, 01:43 AM   #1
arun natarajan
Member
 
Registered: Jun 2014
Posts: 111

Rep: Reputation: Disabled
not able to install vim


hi,

when i am trying to install vim, its says, its already installed.
when i am trying to uninstall vim, its says, its not installed yet.
Pls clear this confusion to me and help me to work with installed vim.


[root@localhost Server]# rpm -ivh vim*
warning: vim-common-7.0.109-6.el5.x86_64.rpm: Header V3 DSA signature: NOKEY, key ID 37017186
Preparing... ########################################### [100%]
package vim-minimal-7.0.109-6.el5.x86_64 is already installed

[root@localhost Server]# rpm -e vim-minimal-7.0.109-6.el5.x86_64.rpm
error: package vim-minimal-7.0.109-6.el5.x86_64.rpm is not installed

[root@localhost Server]# vim a.txt
-bash: vim: command not found

[root@localhost Server]# /sbin/vim a.txt
-bash: /sbin/vim: No such file or directory

[root@localhost Server]# /bin/vim a.txt
-bash: /bin/vim: No such file or directory
 
Old 10-31-2015, 05:36 AM   #2
berndbausch
LQ Addict
 
Registered: Nov 2013
Location: Tokyo
Distribution: Mostly Ubuntu and Centos
Posts: 6,316

Rep: Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002
Code:
rpm -e vim-minimal-7.0.109-6.el5.x86_64.rpm
There is no such package indeed. The package is named vim-minimal-7.0.109-6.el5.x86_64, not vim-minimal-7.0.109-6.el5.x86_64.rpm.

Lesson: Don't use TABTAB when specifying the names of packages.
Consolation: Happens to me about half of the time.

Now the question is, why can't you run vim. You might want to check your path. Also, dump out the list of files in the vim-minimal package; I am not sure if it actually contains vim, perhaps just vi.
Code:
rpm -ql vim-minimal
Lesson 2: There is usually no need to type the full name of the package, including architecture and version.

Last edited by berndbausch; 10-31-2015 at 05:40 AM.
 
Old 10-31-2015, 06:38 AM   #3
michaelk
Moderator
 
Registered: Aug 2002
Posts: 24,733

Rep: Reputation: 5596Reputation: 5596Reputation: 5596Reputation: 5596Reputation: 5596Reputation: 5596Reputation: 5596Reputation: 5596Reputation: 5596Reputation: 5596Reputation: 5596
vim is located in /usr/bin which should be in all users path environment.

To see what packages are already installed:
rpm -qa | grep vim
 
Old 10-31-2015, 12:54 PM   #4
Doug G
Member
 
Registered: Jul 2013
Posts: 749

Rep: Reputation: Disabled
Assuming you're on a Centos system, it's better to use yum rather than rpm to manipulate packages.
Quote:
yum remove vim-minimal
yum install vim
Also yum list installed vim* will tell you what's already installed
 
Old 10-31-2015, 05:28 PM   #5
jefro
Moderator
 
Registered: Mar 2008
Posts: 21,772

Rep: Reputation: 3599Reputation: 3599Reputation: 3599Reputation: 3599Reputation: 3599Reputation: 3599Reputation: 3599Reputation: 3599Reputation: 3599Reputation: 3599Reputation: 3599
Also ideas

vim might be an alias to other program.

I'd also try find -vim or such.
 
Old 10-31-2015, 07:35 PM   #6
Ztcoracat
LQ Guru
 
Registered: Dec 2011
Distribution: Slackware, MX 18
Posts: 9,484
Blog Entries: 15

Rep: Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176Reputation: 1176
Do a yum package search on vim.
 
Old 11-01-2015, 11:02 PM   #7
John VV
LQ Muse
 
Registered: Aug 2005
Location: A2 area Mi.
Posts: 17,612

Rep: Reputation: 2649Reputation: 2649Reputation: 2649Reputation: 2649Reputation: 2649Reputation: 2649Reputation: 2649Reputation: 2649Reputation: 2649Reputation: 2649Reputation: 2649
that "el5" in the name means this rpm is for a RHEL5 or Cent5 install

rhel5 is the current LEGACY hardware operating system
-- and it is showing it's age , as in it IS "over the hill"

so the version of vi you can install on the current RHEL 5.11 or CentOS 5.11 is going to be a bit OLD
-- up to date for the older os

use yum to install software vi needs a few prerequisites installed
yum will install the needed rpm's
Code:
su -
yum search vi
--------- then from the list -install it-----------
yum install vim
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Fedora shows 'man vim' but when execute 'vim' got "bash: vim: command not found..." ? flash_os Linux - Newbie 19 01-03-2015 11:56 PM
Switching from vim to vim -g from inside vim iDragoon Linux - Software 4 05-15-2009 11:46 AM
Editor comparison: vim VS vim-lite, Cleaning vim Ruler2112 *BSD 4 04-13-2009 04:26 PM
Vim/Gcc How To Install? moridon77 Linux - Software 2 06-27-2004 07:14 AM
vim install error eye Red Hat 1 11-13-2003 04:51 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 12:14 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration