Share your knowledge at the LQ Wiki.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 05-23-2017, 08:43 PM   #1
LQ Newbie
Registered: May 2017
Posts: 4

Rep: Reputation: Disabled
Pointing /dev/null to .bash_history doesn't work

I saw this code in my google searches on pointing /dev/null to .bash_history. I tried it but it doesn't work. It stills writes to .bash_history. I even removed .bash_history and rerun the code again and still it writes the commands to .bash_history.

ln -sf /dev/null ~/.bash_history
Old 05-23-2017, 09:00 PM   #2
Keith Hedger
Senior Member
Registered: Jun 2010
Location: Wiltshire, UK
Distribution: Linux From Scratch, Slackware64, Partedmagic
Posts: 3,126

Rep: Reputation: 841Reputation: 841Reputation: 841Reputation: 841Reputation: 841Reputation: 841Reputation: 841
if you dont want your bash history recorded just set nohist in your bashrc you shouldnt really be linking a file to a block device
Old 05-23-2017, 09:34 PM   #3
LQ Newbie
Registered: May 2017
Posts: 4

Original Poster
Rep: Reputation: Disabled
Thanks kind sir
Old 06-15-2017, 07:36 AM   #4
LQ Newbie
Registered: Jun 2017
Posts: 16

Rep: Reputation: Disabled


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
dd if=/dev/urandom of=/dev/hda2 bs=1M doesn't work Melsync Linux - General 16 05-19-2014 07:36 PM
[SOLVED] Stopping cron job emails to root, do I use >/dev/null 2>&1 or &> /dev/null anon091 Linux - Newbie 3 11-12-2013 11:21 AM
mount /dev/hdc /dev/cdrom doesn't work ShrikesHarvest Linux - Newbie 10 02-21-2009 08:05 AM
mount /dev/hdc /dev/cdrom doesn't work amandaortega Linux - Hardware 6 12-01-2006 05:48 AM
program >/dev/null dosn't work classic Linux - Software 10 11-21-2006 02:06 AM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 06:07 AM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration