Gabriele Bulfon <gbul...@sonicle.com> wrote: > Wow, looks like I have ignited a long thread! :) > Maybe I should have better stated that it's not about bash, but that the > shells are said to be Bourne-compatible. > Also, maybe I exagerated the number of shells, it's about one hundered at > most... ;)
There are not so many useful shells that are close to the standard. bash huge and slow, not very close to the standard bosh small, fast and close to the standard dash does not support multi-byte and thus can only be used for embedded systems. If multi-byte support was added, it would be slower than bash ksh (ksh88) The master for POSIX definitions but there are several bugs and as a result, it is less POSIX compliant than bosh. ksh93 less POSIX compliant than ksh88, but currently the fastest known shell. This may change when bosh implements a new field splitting algorithm that avoids one expensive multi-byte copy operation. mksh small, nearly as fast as bosh but needs set -o posix to be posix compliant. One of the best selections. zsh far from the standard, but "test" and arithmetic expansion are implemented similar close to the standard as in bosh. > Te be more precise, I'm packaging Corosync/Pacemaker for XStreamOS. > It comes with the older Heartbeat resource agents, mostly shells for > different clustering jobs. > The specific agent I am testing is "IPaddr", a shell beginning with a shebang > at /bin/sh > After changing the shell to output its env during run, I found the KSH > variable set, and then that it was running /bin/sh -i86/ksh93 > The errors I found in the log are about "local" instruction used in included > ocf shells to define local variables. ... > Still I don't understand why they're not working, when you state that ksh is > Bourne-compatible. > Maybe it just not supports the "local" definition? None of the shells listed above is 100% Bourne Shell compatible and "local" is not supported by the Bourne Shell. Bosh (the schily bourne shell) is aprox. 98% bourne compatible and ks88 is aprox. 96% bourne compatible. Most recent shells (including ksh88 and bosh) support "local", but ksh93 does not. The problem with ksh88 is that it is no longer maintained and it is not OpenSource. This is why bosh is a good selection today as it is derived from the Bourne Shell as ksh88 is and thus avoids some deviations seen in other implementations. Jörg -- EMail:jo...@schily.net (home) Jörg Schilling D-13353 Berlin joerg.schill...@fokus.fraunhofer.de (work) Blog: http://schily.blogspot.com/ URL: http://cdrecord.org/private/ http://sourceforge.net/projects/schilytools/files/' ------------------------------------------- illumos-discuss Archives: https://www.listbox.com/member/archive/182180/=now RSS Feed: https://www.listbox.com/member/archive/rss/182180/21175430-2e6923be Modify Your Subscription: https://www.listbox.com/member/?member_id=21175430&id_secret=21175430-6a77cda4 Powered by Listbox: http://www.listbox.com