You are using wscomsume on 4.0.5? That doesn't come with 4.0.5. Did you install another version of JBoss Web Services? If so, which version? I know that the wsconsume script that comes with 4.2.x and 5.x sets JBOSS_HOME automatically. So I suspect that the wsconsume installed stand-alone requires that you set JBOSS_HOME.