My web has a common template i.e. xhtml file
while contains growl
If a parent of the with the UICommand button is been rendered/updated by an ajax request beforehand, then the first action will always fail. The second and subsequent actions will work. This is caused by a bug in view state handling which is reported as JSF spec issue 790 and fixed in JSF 2.2. For JSF 2.0 and 2.1 you need to explicitly specify the ID of the in the render of the
<f:ajax>
Says BalusC here. So in your case you are doing navigation to another page and stucks into that view state bug, ajax=false
indicates submit the button without AJAX that's why it works.
Also BalusC suggests to use a script which fixes this bug here.