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 |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
 |
06-22-2015, 05:49 PM
|
#1
|
Senior Member
Registered: Apr 2007
Location: Buenos Aires.
Distribution: Slackware
Posts: 4,442
Rep:
|
Vi and Vim.
Hi: I have a text file (plain ASCII) of 5MB size. If I open it with vi,
make some modification and save it, 10 seconds at least elapse before
I am given the prompt again. But if I do the same with vim, it takes under 1 second to save the file. What can be the cause of such a notable difference?
|
|
|
06-22-2015, 09:15 PM
|
#2
|
LQ Guru
Registered: Jan 2006
Location: Virginia, USA
Distribution: Slackware, Ubuntu MATE, Mageia, and whatever VMs I happen to be playing with
Posts: 19,765
|
This Stack Exchange thread seems to bear on your question. Apparently it has to do with how the two programs handle the their tmp files prior to and during saving.
A web search for "vi vim large files" turns up a number of other links that seem relevant.
|
|
1 members found this post helpful.
|
06-22-2015, 10:57 PM
|
#3
|
Moderator
Registered: Mar 2008
Posts: 22,270
|
I guess it could do with how the two were compiled. vi version you have may be very very old while the vim quite new. (dunno, wild guessing here) Although vi should be pure C and quite small. It simply may not address modern hardware well on your system.
Open top command and see if you notice anything on this. I'd too agree that swap file and access to various mounts and such could cause an issue.
vim info. http://www.vim.org/6k/features.en.txt
I'd assume that vi on slack is really vi and not a link to vim. Oops.
http://www.slackbook.org/html/vi.html
"
On Slackware Linux, the default version of vi available is elvis. Other versions - including vim and gvim - are available if you've installed the proper packages. gvim is an X Window version of vim that includes toolbars, detachable menus, and dialog boxes."
Last edited by jefro; 06-22-2015 at 11:23 PM.
|
|
|
06-23-2015, 09:56 PM
|
#4
|
LQ Guru
Registered: Jan 2006
Location: Virginia, USA
Distribution: Slackware, Ubuntu MATE, Mageia, and whatever VMs I happen to be playing with
Posts: 19,765
|
Yes, indeedy-do, Slackware includes both vi and vim. They are very definitely two distinct programs. If you dig hard enough in Slackware, you'll probably find a that kitchen sink.
Other distros I've hopped, Mageia for one, aliases vi to vim, so that, when you type "vi," you get "vim."
|
|
|
06-24-2015, 03:30 AM
|
#5
|
LQ Newbie
Registered: Jun 2015
Distribution: CentOS,Debian,Ubuntu
Posts: 19
Rep: 
|
On some distros, you have vi and vim from different source code. But on RedHat, Debian (by default) you have vi from the Vim source code but with a tiny or small build configuration, while vim gives a bigger version.
|
|
|
06-24-2015, 05:01 PM
|
#6
|
Moderator
Registered: Mar 2008
Posts: 22,270
|
http://www.slackbook.org/html/vi.html
"
On Slackware Linux, the default version of vi available is elvis. Other versions - including vim and gvim - are available if you've installed the proper packages. gvim is an X Window version of vim that includes toolbars, detachable menus, and dialog boxes."
|
|
|
All times are GMT -5. The time now is 10:12 PM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|