sh is the original UNIX shell. Also known as Bourne shell after its original designer. See also
http://mywiki.wooledge.org/BourneShell.
ksh is the Korn shell, also named after its original designer. It adds numerous features to sh, in particular with regards to interactive use. See
http://mywiki.wooledge.org/KornShell
There is also a POSIX shell which attempts to standardize shell behaviour.
Bash ("bourne-again shell") is the standard Linux shell. It's POSIX-compliant but has many additional features. See
http://mywiki.wooledge.org/BashGuide.
Wikipedia also contains a lot of info about the shell.
For shell scripts, use sh or POSIX shell if you need maximum compatibility, and bash if not. Bash has many features that make it easier to write and read scripts. For example, this original Bourne shell code:
Code:
if [ expr "$a" + "$b" -gt 13 ]
then ....
can be written as follows in bash:
Code:
if (( a+b>13 ))
then ....
On many (most? all?) distros /bin/sh is a symbolic link to /bin/bash; you need to check if the Bourne shell exists at all.
Just checked - the standard Centos 7 repositories don't appear to have the Bourne or Posix shell. ksh is available though.