[ubuntu-uk] Saving history in the terminal

Mark Einon mark.einon at gmail.com
Sun Oct 21 17:32:13 UTC 2012

On 21 October 2012 18:25, scoundrel50agmail <scoundrel50a at gmail.com> wrote:
> How can I get the history to save in the terminal. Everytime I use it, it
> keeps the history of that window, but when I close it, its gone.

I think you need to be more specific in order for me to understand your problem.

The default behaviour of the bash terminal is to save the history of
the last closed terminal, and any new terminal will start with this
history, which is saved in the file ~/.bash_history.

This means that if you have two or three terminals open, and close
them, only the history of the final closed terminal is kept. Is this
what you are experiencing?

Another issue could be that the file ~/.bash_history is not writeable
by you (e.g. it's owned by root instead).



More information about the ubuntu-uk mailing list