S. Anthony Sequeira wrote:
On Tue, 2006-06-13 at 12:23 -0600, Jason Aeschilman wrote:
Bash history is not saved on shutdown. I have commented out the line
"unset HISTFILE" from /etc/profile so now history is saved for root, but
it only works when I log out of a terminal. If I reboot or shutdown,
the history does not get saved to ~/.bash_history. Does anyone know how
this can be fixed? Shouldn't this be standard on the LFS system? Even
if you keep "unset HISTFILE" for root, regular users should not lose
their bash history on shutdown.
Jason
I believe this is standard. If the terminal session is not logged out
of, history for that session is not saved.
What I do if I reboot/shutdown from a virtual terminal:
reboot ; exit
I have lost history enough times, so I'm careful to logout of any
session I want to save.
Well, this came up because our (very old) Caldera-based system didn't
have this problem. I just now tested this on Fedora and it doesn't have
this problem either. I'm curious what is different on LFS. I wonder
if their reboot command is compiled differently. I suppose one solution
would be to create an alias for reboot (alias reboot='reboot; exit') but
it seems silly to have to do that.
--
http://linuxfromscratch.org/mailman/listinfo/blfs-support
FAQ: http://www.linuxfromscratch.org/blfs/faq.html
Unsubscribe: See the above information page