[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: vi saved file message from root



On Thu, Sep 12, 2002 at 09:51:19AM -0600, Bob Proulx wrote:
> You can list files that are available for recover with 'vi -r'.  At
> boot time or perhaps by cron this is being mailed to users.

I tried this, and it didn't list any files.

Thanks for suggesting RTFM, but I had done that and wrote this list
because it didn't seem to help.  I had also typed:
>   vi -r /tmp/vi.7faEP4   
But it didn't help (the screen just flickered and I was returned to the
prompt).  So you lost that bet!

But I didn't know the files were kept in the locations you mention, and
I see that there are a couple of files (with completely different
numbers) in /var/tmp/vi.recover that were created on the date that the
user gets the email message about.  I'm going to delete those, and see
if that helps (one of them has the error message the user receives in
it).  I am guilty of not running any system tmp cleaners that I know of
(basically, this is my first Linux experience and I'm still trying to
learn how to do all of these things).  I guess I'll try to figure out
how to set one of those up. 

Anyway, thanks for the response, and the info about where to look for
the files; that is what I needed (not a suggestion to RTFM).

Ric

> The vi program keeps spill files in /tmp.  When the system crashes it
> and recovers it will save those files to /var/preserve or
> /var/spool/preserve or /var/tmp/vi.recover or some such location.  You
> have that and if you look you will find a file there.  Most systems
> will put a tmp cleaner on that directory and will delete files which
> are older than a week or so.  If the user has not recovered the file
> in a week after a system crash then they don't care and you should
> clean up the crash file.  Some vi programs keep them in
> /var/tmp/vi.recover so that they are naturally cleaned by the system
> tmp cleaners.  You are running one of those, aren't you?
> 
> Let me be critical.  But this is meant to be constructive.  This is
> clearly a case where RTFM would solved your problem.  Let's look at
> 'man vi'
> 
>        -r     Recover the specified files, or, if  no  files  are
>               specified,  list the files that could be recovered.
>               If no  recoverable  files  by  the  specified  name
>               exist,  the  file is edited as if the -r option had
>               not been specified.
> 
> Just do the command it is suggested.  It looks from your mail that you
> never tried that.  You are root on the machine so you can become them
> if you want to try this yourself instead of waiting for them to do it.
> 
>   su root                # become root
>   su - user              # become the user
>   vi -r /tmp/vi.7faEP4   # run the command as the user
> 
> If after running that command as that user if it fails to recover the
> file then you certainly have probably found a problem.  But I bet it
> works.
> 
> Bob




Reply to: