1

Command route -n of BSD return nothing

$ route -n
usage: route [-dnqtv] command [[modifiers] args]

It's output of GNU version

enter image description here

What's the equivalent in BSD?

3

You can use netstat -rn for this purpose.

See the FreeBSD man page on netstat for more details.

Incidentally, that also works in Linux, so in a way it's a more portable command than route -n to inspect the routing tables.

3
route -n show

You forgot to mention the task that you wanted route to do: show. This is also hinted at in the error message that you get.

The Linux route command and the BSD route commands are quite different in their semantics, and the BSD command does not default to showing the routes.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.