From owner-freebsd-questions@FreeBSD.ORG Sun Jun 3 08:42:16 2007 Return-Path: X-Original-To: freebsd-questions@freebsd.org Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 1252C16A421 for ; Sun, 3 Jun 2007 08:42:16 +0000 (UTC) (envelope-from maanjee@gmail.com) Received: from wa-out-1112.google.com (wa-out-1112.google.com [209.85.146.178]) by mx1.freebsd.org (Postfix) with ESMTP id DE6E613C455 for ; Sun, 3 Jun 2007 08:42:15 +0000 (UTC) (envelope-from maanjee@gmail.com) Received: by wa-out-1112.google.com with SMTP id m33so1393951wag for ; Sun, 03 Jun 2007 01:42:15 -0700 (PDT) DKIM-Signature: a=rsa-sha1; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:references; b=dJefKeSo/cJ4CCzyDzG0z6ojkGxiG/Sr33BM++Ayl4oLe0Hj6XCu1QkbRlzAdVJewjLHHfpOUXXRZlaQgegyMTZeOQ0QiICK55LDuLf30BGc4h/OfWXYHtWNxdI/jAFjkGpGekCSYLLpG77hoZH8g8ArliUmiCEB1GDsFjdepHU= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:references; b=JgFJ1+6UQ5PfHBoU9hnEpP13wJgRG31OWfHJhnUHkwvK4XNBIcO5rpgLlEgWLoQh/lwqx/EwBbCACUJNUB2uPGtDh8M0JOD1lCqsDJC/F3KiNKTIQmd7n9p1TeFP8vzrflXa2NRDuvH4WeK2ZMKEGvbKzP66VAsO5iW5K1GpBFM= Received: by 10.115.58.1 with SMTP id l1mr3589698wak.1180860135099; Sun, 03 Jun 2007 01:42:15 -0700 (PDT) Received: by 10.115.95.7 with HTTP; Sun, 3 Jun 2007 01:42:15 -0700 (PDT) Message-ID: <2cd0a0da0706030142l1fd30d74yc443e132337daf37@mail.gmail.com> Date: Sun, 3 Jun 2007 10:42:15 +0200 From: VeeJay To: "Kevin Hunter" In-Reply-To: <4661B6E0.803@earlham.edu> MIME-Version: 1.0 References: <2cd0a0da0706020638g48b7ac7fn946c6e3caddc0663@mail.gmail.com> <466199E5.3040005@vindaloo.com> <4661B6E0.803@earlham.edu> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Cc: sac , FreeBSD-Questions Subject: Re: How to disable command prompt history? X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 03 Jun 2007 08:42:16 -0000 Thank you guys, Actually, it was for the security reason that if somebody breaks in the server then he/she doesn't see what commands are being executed, etc, etc.... and I am using /bin/sh any more comments? thanks, VJ On 6/2/07, Kevin Hunter wrote: > > At 1:56p -0400 on 02 Jun 2007, sac wrote: > > On 6/2/07, Christopher Hilton wrote: > >> VeeJay wrote: > >>> Could someone would like to describe that how we can disable to show > >>> last executed commands by pressing Up Arrow? > >>> > >> > >> That would depend on which shell you are running. Can you run the > >> following command and post the results here? > >> > >> echo $SHELL > > > > By default most of the shells like bash, zsh, ksh have history option. > > But you can avoid writing the history of the current session to the > > history file by unsetting the HISTFILE environment variable. > > So next time when you login the history of the previous session will > > not be shown. > > I'd be curious as to the underlying "why?". Having a history of what > you've done is generally a Good Thing. The only reason that I > personally have ever come across to necessitate not storing my actions > is when I'm playing a prank on one of my friends. Other than that, > having the ability to go see what commands I was executing three years > ago comes in awful handy. I /could/ recreate that arcane command > sequence for that one-off job I needed 1,237 days ago, or I could do a > > history | grep 'substring I remember in command' | less > > And, if you're worried about the space it takes to store the history, > don't. It's extremely negligible. > > Kevin > -- Thanks! BR / vj