Hello, this may be a “Noob question”, but I’m new to Linux/Ubuntu…
I’m trying to run the following command(s) via CFEXECUTE to copy a file with scp from A to B (works fine via SSH/command line):
Version 1:
<cfexecute name="scp" arguments="/var/www/filetocopy.csv root@10.10.10.10:/var/lib/mysql-files/" outputfile="outfile" timeOut="30" />
Result:
java.io.IOException: Cannot run program “scp”: error=2, No such file or directory
Version 2:
Execution of copy.sh with the following content:
scp /var/www/filetocopy.csv root@10.10.10.10:/var/lib/mysql-files/
<cfexecute name="/var/www/copy.sh" outputfile="outfile" timeOut="30" />
Result:
lucee.commons.cli.CommandException: /var/www/copy.sh: 1: scp: not found
Version 3:
After copying scp to /var/www:
<cfexecute name="scp" arguments="/var/www/filetocopy.csv root@10.10.10.10:/var/lib/mysql-files/" outputfile="outfile" timeOut="30" />
Result:
lucee.commons.cli.CommandException: /var/www/scp: /usr/lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.38’ not found (required by /var/www/scp)
I’m quite sure this is only a path issue or something similiar trivial, but I’m thankful for any hint!
Regards,
RG
Don’t forget to tell us about your stack!
OS: Ubuntu 24.04.1 LTS
Java Version: OpenJDK 11.0.24+8
Tomcat Version: 9.0.96
Lucee Version: 6.1.1.118