Mac OS X: Delete SSH Keys Using Terminal Command Line

by on April 18, 2012 · 0 comments· LAST UPDATED November 18, 2013

in , ,

I have aws.sg.pub and ibm.sl.pub file for ssh login. How do I delete ssh key file called ~/.ssh/aws.sg.pub using the terminal on Apple Mac OS X?

You can use rm command to delete the file from your local Mac based system. The syntax is:
Tutorial details
DifficultyEasy (rss)
Root privilegesNo
RequirementsTerminal
Estimated completion time1m

rm fileName

OR

rm $HOME/.ssh/file.pub

OR

rm ~/.ssh/file.pub

In this example, delete a file called ~/.ssh/aws.sg.pub using the rm command

 
rm ~/.ssh/aws.sg.pub
 

See rm(1) command man page for more information.

TwitterFacebookGoogle+PDF versionFound an error/typo on this page? Help us!

{ 0 comments… add one now }

Leave a Comment

Tagged as: ,

Previous Faq:

Next Faq: