Showing results for 
Search instead for 
Did you mean: 

korn shell

Gene Kenny
Regular Advisor

korn shell

On linux can I temporaily convert from the bash shell to the korn shell. If so how can root convert to the korn shell

John Poff
Honored Contributor

Re: korn shell


You can temporarily use the Korn shell by doing a 'exec /usr/bin/ksh'. I don't know if root can use ksh in Linux, but I'd be very careful trying it in Linux as bash is a superset of ksh and there is no telling what might break if you did that.

Steven E. Protter
Exalted Contributor

Re: korn shell

There are almost no functional differences between the bash shell and the korn shell.

You can get a korn shell for Linux. Those that have tried have found the benefits are far outwieghed by the problems.

If there is a specific benefit of the korn shell you are looking for I or others can probably tell you how to get that benefit from the bash shell.

Steven E Protter
Owner of ISN Corporation
Ross Minkov
Esteemed Contributor

Re: korn shell

1. Get the list of available shells on that Linux system using "chsh -l"

# chsh -l

2. If ksh is listed go ahead and type "/bin/ksh" or just "ksh" (I'm pretty sure that you have /bin in your PATH)


If you want to change your login shell (listed in /etc/passwd) then use:

chsh -s /bin/ksh

I wouldn't recommend changing the login shell to anything other than /bin/bash for root on a Linux system. There are lots of little diferences between ksh and bash...


Re: korn shell

Korn shell provides a number of benefits over bash. We use the improved array features most heavily and have begun using double precision arithmetic, too.

Ksh 93 is available as open source from

Guru Dutta
Frequent Advisor

Re: korn shell

I think using exec /usr/bin/ksh would be a good approach.