zsh-users
 help / color / mirror / code / Atom feed
From: Dominik Vogt <dominik.vogt@gmx.de>
To: zsh-users@zsh.org
Subject: Re: Bug: Losing .zsh_history
Date: Thu, 6 Oct 2022 00:03:06 +0100	[thread overview]
Message-ID: <Yz4NKi/qsJc49GgX@localhost> (raw)
In-Reply-To: <CAH+w=7bWKAngc4MccOaJ7LSujet4xcNbEzhuU2Sq8Qm6x+vKow@mail.gmail.com>

On Wed, Oct 05, 2022 at 03:31:07PM -0700, Bart Schaefer wrote:
> Somethig like that is the most likely culprit:  The filesystem has
> allocated space for the buffered content to be written out, but
> cutting the power brings the system down before the buffer is flushed
> to disk.  This is most often seen on "soft-mounted" NFS filesystems
> that use delayed writes, but it's certainly possible to happen locally
> on abrupt loss of power.

> If avoiding FS lossage is important enough to you ...

Not at all, I just don't want to lose the shell history.

> If the problem merely seems to be that a shell you can't see has
> started up and is trying to update the history when it shuts down, you
> could add something to .zlogin to make a backup copy of the history
> when the shell starts.

Yes, but that would considerably increase SSD wear (see other mail
thread); so I do it manually once in a while.

> The circumstances you've described are odd,
> though, because I wouldn't expect a shell to have any opportunity to
> begin processing its shutdown when power is cut.  If the same problem
> that causes the blank display has already killed the shell, there may
> be a connection between the failing display and failing disk
> operations.

Actually, what's really strange is that the shell should not be
started at all in this situation:  The display only ever fails
when powering on; once it works it keeps working.  In that
situation I don't log in because I can't see anything.  I'm not
even sure getty starts up at all.  So, why does any zsh run at
all if I can't even log in?

Ciao

Dominik ^_^  ^_^

--

Dominik Vogt


  reply	other threads:[~2022-10-05 23:07 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-10-05 19:55 Dominik Vogt
2022-10-05 20:01 ` Eric Cook
2022-10-05 20:20   ` Dominik Vogt
2022-10-05 21:05     ` Wesley
2022-10-05 21:24       ` Dominik Vogt
2022-10-05 22:31         ` Bart Schaefer
2022-10-05 23:03           ` Dominik Vogt [this message]
2022-10-06  4:34             ` Bart Schaefer
2022-10-06  9:40               ` Peter Stephenson
2022-10-06 10:52                 ` Dominik Vogt
2022-10-06 10:30               ` Dominik Vogt
2022-10-05 20:26 ` Dominik Vogt
2022-10-05 22:16 ` Bart Schaefer
2022-10-05 22:32   ` Dominik Vogt
2022-10-06 10:31   ` Dominik Vogt
2022-10-07 11:45 ` Mikael Magnusson

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=Yz4NKi/qsJc49GgX@localhost \
    --to=dominik.vogt@gmx.de \
    --cc=zsh-users@zsh.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).