This question already has an answer here:

My shell can't find ping.

$ ping
-bash: ping: command not found
$ uname -r
$ echo $PATH
$ which ping

However, man ping works and displays the manual page for ping.

Is it named something different on OSX? Or is there an alternative I should use?

marked as duplicate by bmike Oct 1 '15 at 14:39

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

  • 2
    You are missing /sbin in your PATH variable. – fd0 Oct 1 '15 at 14:37
  • If you run /usr/libexec/path_helper does the path change? (and is ping found) – bmike Oct 1 '15 at 14:37
  • 1
    I'm going to point this to a canonical "my path variable is messed up" and if you don't find a solution there, let's edit the body of the question to explain which answer was rejected and get some more detail... – bmike Oct 1 '15 at 14:39
  • @bmike yep, that helped, as did fd0's suggstions about /sbin. Shall I delete the question? – hoosierEE Oct 1 '15 at 15:55
  • @hoosierEE No - we actually love "closed questions" since someone searching google might use your words as opposed to the words on the duplicate. Also - if you find an edge case, it's better to reopen this after an edit is made to the post. – bmike Oct 1 '15 at 15:59

Browse other questions tagged .