LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices

Reply
 
Search this Thread
Old 02-23-2010, 06:29 PM   #1
throughthegreens
Member
 
Registered: Feb 2010
Location: Asekhshinuv Sacramento,Ca
Distribution: Slackware 13.0
Posts: 35

Rep: Reputation: 16
vim takes long time to start


I'm having trouble with Vim in any terminal emulator I use. I have a link (vi) to vim. Occasionally it will take very long to load, whether I use 'vi' or 'vi file'. Before, if I could I would restart X, and then it would load instantly again, but I waited this time and it did load, after a minute or so. Is this a problem with X or vim?
 
Old 02-23-2010, 06:39 PM   #2
chrism01
Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Centos 6.5, Centos 5.10
Posts: 16,226

Rep: Reputation: 2023Reputation: 2023Reputation: 2023Reputation: 2023Reputation: 2023Reputation: 2023Reputation: 2023Reputation: 2023Reputation: 2023Reputation: 2023Reputation: 2023
Difficult to tell... try leaving 'top' running in another window and check it if it happens again.
 
Old 02-23-2010, 06:56 PM   #3
throughthegreens
Member
 
Registered: Feb 2010
Location: Asekhshinuv Sacramento,Ca
Distribution: Slackware 13.0
Posts: 35

Original Poster
Rep: Reputation: 16
I was able to trigger it by doing, from ~, "vi .fvwm/.fvwm2rc". I am watching top and nothing is coming up related to vim. I counted 168 seconds from ~30sec after I hit enter (with a while loop), and when it finally loaded the text area of vim had nothing in it, but :quit'ing and then pressing up->enter to repeat the command came up with the full file and it loads instantly now, everytime.

Last edited by throughthegreens; 02-23-2010 at 06:58 PM. Reason: possibly misleading information
 
Old 02-23-2010, 07:20 PM   #4
Tinkster
Moderator
 
Registered: Apr 2002
Location: in a fallen world
Distribution: slackware by choice, others too :} ... android.
Posts: 22,965
Blog Entries: 11

Rep: Reputation: 865Reputation: 865Reputation: 865Reputation: 865Reputation: 865Reputation: 865Reputation: 865
Super slow/super busy disk subsystem?
What does IO-stat tell you about the disk?

Next time the problem occurs try tunning vim under strace w/
timing information enabled.
 
Old 02-24-2010, 06:01 PM   #5
throughthegreens
Member
 
Registered: Feb 2010
Location: Asekhshinuv Sacramento,Ca
Distribution: Slackware 13.0
Posts: 35

Original Poster
Rep: Reputation: 16
iostat:
Code:
root - 'MindStation': $ iostat
Linux 2.6.29.6-t40 (MindStation) 	02/24/2010

avg-cpu:  %user   %nice %system %iowait  %steal   %idle
           9.16    0.00    4.20    6.02    0.00   80.62

Device:            tps   Blk_read/s   Blk_wrtn/s   Blk_read   Blk_wrtn
hda              15.28       556.53       117.91     385217      81616
hda1             15.05       550.47       117.91     381026      81616
hda2              0.06         1.59         0.00       1102          0
hda3              0.05         1.79         0.00       1236          0
hda4              0.10         2.54         0.00       1757          0
sorry I can't figure out where to go from here. I think the problem is a bad disk. next time it happens I'm gonna check syslog for buffer i/o errors
 
Old 02-24-2010, 06:40 PM   #6
Tinkster
Moderator
 
Registered: Apr 2002
Location: in a fallen world
Distribution: slackware by choice, others too :} ... android.
Posts: 22,965
Blog Entries: 11

Rep: Reputation: 865Reputation: 865Reputation: 865Reputation: 865Reputation: 865Reputation: 865Reputation: 865
What mount point lives on hda1?
 
Old 02-25-2010, 02:48 AM   #7
throughthegreens
Member
 
Registered: Feb 2010
Location: Asekhshinuv Sacramento,Ca
Distribution: Slackware 13.0
Posts: 35

Original Poster
Rep: Reputation: 16
root,/home,etc. everything. hda1 and hda2 are Slackware, hda3 swap, hda4 storage
 
Old 02-25-2010, 04:05 AM   #8
zhjim
Senior Member
 
Registered: Oct 2004
Distribution: Debian Squeeze x86_64
Posts: 1,436
Blog Entries: 11

Rep: Reputation: 181Reputation: 181
Whats the size of the file your trying to open? If I open up a 1G file with vim it just takes it time copying everything into memory.
 
Old 02-25-2010, 01:08 PM   #9
throughthegreens
Member
 
Registered: Feb 2010
Location: Asekhshinuv Sacramento,Ca
Distribution: Slackware 13.0
Posts: 35

Original Poster
Rep: Reputation: 16
It's only 7.6K
 
Old 03-03-2010, 01:46 PM   #10
throughthegreens
Member
 
Registered: Feb 2010
Location: Asekhshinuv Sacramento,Ca
Distribution: Slackware 13.0
Posts: 35

Original Poster
Rep: Reputation: 16
I finally had it happen again and did strace on it. I only noticed one part,
Code:
rt_sigaction(SIGUSR1, {0x815e1e0, [], 0}, NULL, 8) = 0
rt_sigaction(SIGUSR2, {0x815e1e0, [], 0}, NULL, 8) = 0
ioctl(0, SNDCTL_TMR_TIMEBASE or TCGETS, {B38400 opost isig icanon echo ...}) = 0
write(2, "Vim: Warning: Output is not to a "..., 42Vim: Warning: Output is not to a terminal
) = 42
nanosleep({2, 0}, NULL)                 = 0
ioctl(1, SNDCTL_TMR_TIMEBASE or TCGETS, 0xbff84488) = -1 ENOTTY (Inappropriate ioctl for device)
stat64("/home/matthew/.terminfo", 0xbff84454) = -1 ENOENT (No such file or directory)
which tells me that it's not connecting to the pts.
Eventually it shows up, but my strace doesn't go this far. it is at http://pastebin.ca/1821695
 
  


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
gdm takes a long time nkd Fedora 6 10-17-2008 02:38 PM
GDM takes a *long* time to start first time grumpybuffalo Linux From Scratch 2 09-09-2007 12:17 PM
Login takes a very long time Jensens Linux - Networking 2 03-23-2006 03:24 AM
GKrellM takes a LONG time to start up Oxagast Linux - Software 1 01-26-2006 01:37 AM
login takes long time doorman007 Linux - Software 2 04-25-2005 12:56 AM


All times are GMT -5. The time now is 11:39 PM.

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration