Freebsd – Clear tcsh/csh history in FreeBSD 10.0

command-line-interfacefreebsd

This is a little embarrassing but I'm unable to delete the root user shell history from a FreeBSD 10.0 server. The root user is using the default csh.

I've tried the classic history -c command to clean up the history and it works… until I logout and login on the server again.

Tried to remove the ~/.history file without success too.

Any ideias of what to do?

Best Answer

If you are looking to clear your history (On FreeBSD 10.1 w/ (t)csh).

echo > /root/.history && history -c