Find the answer to your Linux question:
Results 1 to 8 of 8
history command gives me last 1000 executed commands only...how to increase this limit ???(to view last 2000 or 3000 commands)...
  1. #1
    Linux Guru Lakshmipathi's Avatar
    Join Date
    Sep 2006
    Location
    3rd rock from sun - Often seen near moon
    Posts
    1,568

    Smile history command

    history command gives me last 1000 executed commands only...how to increase this limit ???(to view last 2000 or 3000 commands)
    - Lakshmipathi.G
    -------------------
    FOSS India Award winning ext3fs Undelete tool and tutorials www.giis.co.in
    First they criticize you,Then they laugh at you,Then they fight with you,Then you win. - M.K.Gandhi
    -------------------

  2. #2
    Banned CodeRoot's Avatar
    Join Date
    Sep 2005
    Posts
    567
    (I am assuming you are in a bash environment...)

    Code:
    man bash
    hint: HISTSIZE

  3. #3
    Linux Guru Lakshmipathi's Avatar
    Join Date
    Sep 2006
    Location
    3rd rock from sun - Often seen near moon
    Posts
    1,568

    Smile

    hi,
    i tried this.
    set history=2000
    but when i close the terminal,
    history limit reset to default 1000...i tried to look in bash man ....yet to find the soultion
    - Lakshmipathi.G
    -------------------
    FOSS India Award winning ext3fs Undelete tool and tutorials www.giis.co.in
    First they criticize you,Then they laugh at you,Then they fight with you,Then you win. - M.K.Gandhi
    -------------------

  4. #4
    Banned CodeRoot's Avatar
    Join Date
    Sep 2005
    Posts
    567
    Try placing a line in '~/.bashrc' that sets 'HISTSIZE' to 2000, and see if that works for you...

  5. #5
    Linux Guru Lakshmipathi's Avatar
    Join Date
    Sep 2006
    Location
    3rd rock from sun - Often seen near moon
    Posts
    1,568

    Thumbs up

    how to set that i tried this .
    $HISTSIZE = 2000

    not working when i invoke terminal ,
    it says
    bash: 1000: command not found
    - Lakshmipathi.G
    -------------------
    FOSS India Award winning ext3fs Undelete tool and tutorials www.giis.co.in
    First they criticize you,Then they laugh at you,Then they fight with you,Then you win. - M.K.Gandhi
    -------------------

  6. #6
    Banned CodeRoot's Avatar
    Join Date
    Sep 2005
    Posts
    567
    Try:
    Code:
    HISTSIZE=2000
    (No space on either side of '='.)

  7. #7
    Linux Guru Lakshmipathi's Avatar
    Join Date
    Sep 2006
    Location
    3rd rock from sun - Often seen near moon
    Posts
    1,568

    Smile

    thanks codeRoot ...it works perfectly
    - Lakshmipathi.G
    -------------------
    FOSS India Award winning ext3fs Undelete tool and tutorials www.giis.co.in
    First they criticize you,Then they laugh at you,Then they fight with you,Then you win. - M.K.Gandhi
    -------------------

  8. #8
    Banned CodeRoot's Avatar
    Join Date
    Sep 2005
    Posts
    567
    Quote Originally Posted by Lakshmipathi View Post
    thanks codeRoot ...it works perfectly
    "Very welcome... Glad you got it working for you..."

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
...