WEIGEL FORUM
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Login

    Remove key from known_hosts

    Linux
    1
    1
    6
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • DerMeldosD
      DerMeldos
      last edited by

      Remove key from known_hosts file:

      Open the terminal and type the following command:

      For all examples below just replace the value after -R:

      ssh-keygen -R server-name
      ssh-keygen -R server.ip.addre.ss
      ssh-keygen -R 202.54.1.5
      ssh-keygen -R server1.example.com
      

      Example Output:

      root@AWX0708:~# ssh-keygen -R 10.196.0.1
      # Host 10.196.0.1 found: line 8
      # Host 10.196.0.1 found: line 9
      # Host 10.196.0.1 found: line 10
      /root/.ssh/known_hosts updated.
      Original contents retained as /root/.ssh/known_hosts.old
      root@AWX0708:~# ssh ansible@10.196.0.1
      
      1 Reply Last reply Reply Quote 0
      • First post
        Last post
      Powered by NodeBB | Contributors