.cshrc History missing

Matthew Seaman m.seaman at infracaninophile.co.uk
Mon Aug 10 06:02:22 UTC 2009

Al Plant wrote:
> Polytropon wrote:
>> Allthough I'm not familiar with the particular problem you
>> described, I observed that the history sometimes (!) does
>> not survive a reboot. It may have to do with a situation
>> where more than one shell is running. Idea: The last shell
>> closed (even forced) saves its history, so the history of
>> the other shells gets lost.
>> I've set those globally in /etc/csh.cshrc:
>>     set history = 100
>>     set savehist = 100
>> Sometimes, history survives, sometimes it doesn't. Very
>> strange...
> Aloha Poly,
> I'm glad to have somebody confirm this. I thought it was funny that this 
> was happening.
> I have earlier CURRENT 8 running on a couple of machines and they never 
> acted this way.
> This is root that is doing this on my test box.
>  set history = 100
>  set savehistory = 100
> are in the .cshrc file.
> I'll look in /etc/csh.cshrc
> Thanks...

Yeah.  The history mechanism in tcsh doesn't cope very well with multiple 
ttys being closed down at once, as you tend to find when logging out of an
X session.  You get the history from just one of those shells. 

It's not a complete cure, but telling the shell to merge it's history with
what's already there:

        set history = 500
        set savehist = (1000 merge)

This helps, but it is not completely reliable when several shells are shutdown
in quick succession.



Dr Matthew J Seaman MA, D.Phil.                   7 Priory Courtyard
                                                  Flat 3
PGP: http://www.infracaninophile.co.uk/pgpkey     Ramsgate
                                                  Kent, CT11 9PW

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 259 bytes
Desc: OpenPGP digital signature
Url : http://lists.freebsd.org/pipermail/freebsd-questions/attachments/20090810/29398809/signature.pgp

More information about the freebsd-questions mailing list