Three problems with your command:
- You’re missing the terminating
/. - You can’t use
/as delimiter anyway, because this character occurs in the string you’re trying to replace/substitute. You should use a different character, such as a pipe character, as delimiter. - In the version (BSD) of
sedthat ships with Mac OS X, the-iflag expects a mandatory<extension>argument, which your command is missing. An empty string ("") should follow the-iflag if you want to edit the file in-place with this version ofsed.
In summary, try
sudo sed -i "" "s|#Banner none|Banner /etc/sshd_banner|" /etc/sshd_config