I'm attempting to create a script to allow my level 1 techs to change user's passwords.

zmprov works if I:

su - zimbra

but if I type:

su - zimbra zmprov sp user@domain.com temppw

I get this output:

/opt/zimbra/bin/zmprov: line 17: /opt/zimbra/zmjava: No such file or directory
/opt/zimbra/bin/zmprov: line 17: exec: /opt/zimbra/zmjava: cannot execute: No such file or directory

Does anyone know what causes this or the fix?

Thanks in advance.