Words by Gordon Ewasiuk [Wed, Oct 30, 2002 at 06:29:46AM -0500]: > On Wed, 30 Oct 2002, Ramesh Pathak wrote: > > > Good Question .. In fact I wud also love to know how to do this ... > > > > if without logout how to do? > > ----- Original Message ----- > > From: "Emmanuel Seyman" <[EMAIL PROTECTED]> > > To: <[EMAIL PROTECTED]> > > Sent: Wednesday, October 30, 2002 5:41 PM > > Subject: Re: How to delete bash history of root > > > > > > On Wed, Oct 30, 2002 at 05:15:23PM +0800, Roger wrote: > > > > > > My question is the same as the subject, how to delete the bash history of > > > root. any suggestion is appreciated > > > > Logout > > Login and run the command "rm .bash_history" > > Logout > > cat < /dev/null > .bash_history > > will overwrite the file with /dev/null >
Yes, but it will not delete the history items stores in memory, not yet flushed to ~/.bash_history, at logout they will all be writen to that file. If you export the HISTFILE to /dev/null they will be flushed to /dev/null: export HISTFILE=/dev/null rm ~/.bash_history > but this isn't really a redhat specific question... > Indeed. -- Jose Celestino || SysAdmin::SAPO.pt http://www.sapo.pt http://xpto.org/~japc ----------------------------------------------------- "Lately, the only thing keeping me from becoming a serial killer is my distaste for manual labor." -- Dilbert -- redhat-list mailing list unsubscribe mailto:redhat-list-request@;redhat.com?subject=unsubscribe https://listman.redhat.com/mailman/listinfo/redhat-list