KARAF-2727 - fix script for Solaris
KARAF-2727 - additional fix for script on Solaris