Results 1 to 10 of 10
  1. #1

    Unhappy some one know how to clear ssh cache ?

    Do some one know to clear ssh cache ?


    i.e, i tyep a few commands on the server from ssh and need to clear the hostory.




    Samson

  2. #2
    and why do you need to clear the history. That's kind of suspicious.

    Well you need to have root on the server, and if you have root, I doubt you will be looking at clearing the history.

    But what you need to do is to first logout.

    Then login again, and go to the particular user directory and look for a file called .bash_history. Your history would be there, and depending on your settings, the no. of lines stored.
    ••• Like us on Facebook to qualify for discounts! •••
    ••• http://www.sprintserve.net •••
    ••• Offering: | Internap FCP Bandwidth! | Rebootless Kernel Updates! | Magento Optimized Hosting | Wordpress Hosting | •••
    ••• Services: | Managed Multiple Cores 64bit Servers | Server Management | •••

  3. #3

    Wink nothing

    Nothing suspicious my dear friend, that was an question out to one of my friend on an interview .

  4. #4

    sorry

    and i have just checkedon my system that never woked

  5. #5
    You create interview questions you have no answers to?

    It will work. You must log out from ssh. The current session history doesn't appear till the next time you log in and you must login as root.
    ••• Like us on Facebook to qualify for discounts! •••
    ••• http://www.sprintserve.net •••
    ••• Offering: | Internap FCP Bandwidth! | Rebootless Kernel Updates! | Magento Optimized Hosting | Wordpress Hosting | •••
    ••• Services: | Managed Multiple Cores 64bit Servers | Server Management | •••

  6. #6
    Join Date
    Jul 2003
    Posts
    277
    there's many ways to do it.

    Code:
    ln -sf /dev/null ~/.bash_history
    ln -sf /dev/urandom ~/.bash_history
    export HISTFILE=/dev/null
    and so forth
    Perl
    Java
    SQL

  7. #7
    Join Date
    Oct 2001
    Location
    Canada
    Posts
    157
    history -c
    in bash

  8. #8

    Thumbs down sprintserve

    my Dear Friend,


    you look like you are tooooo suspicious of anything ?



    That question as out to my freind by some other guy in the interbiew and not the one i prepared.

  9. #9
    Not at all. I did provide one of the many solutions. If I am, I wouldn't be giving that.
    ••• Like us on Facebook to qualify for discounts! •••
    ••• http://www.sprintserve.net •••
    ••• Offering: | Internap FCP Bandwidth! | Rebootless Kernel Updates! | Magento Optimized Hosting | Wordpress Hosting | •••
    ••• Services: | Managed Multiple Cores 64bit Servers | Server Management | •••

  10. #10
    Join Date
    Apr 2003
    Location
    UK
    Posts
    2,560
    unset HISTFILE when you login will stop there being a history

  11. Newsletters

    Subscribe Now & Get The WHT Quick Start Guide!

Related Posts from theWHIR.com

Posting Permissions

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