Hello Vinod K,
Welcome to the MS Q&A platform.
Since you were able to run the command manually, it could be an issue with credentials when running through scripts.
Can you please ensure the credentials(username and password) you are using to access the ADLS account are correct and it has the necessary permissions to access the target directory?
and can you try adding the "-v" flag to the "hadoop fs" command to increase the verbosity level and get more information about the error?