Kodekloud Engineer - Jenkins Level 2 - Task 4 is showing me an error that I assume related to the Jenkins version:
Started by user admin Running as SYSTEM Building in workspace /var/lib/jenkins/workspace/database-backup [SSH] script: mysqldump -u kodekloud_roy --password=asdfgdsd kodekloud_db01 > db_$(date +%F).sql SSHPASS=“H@wk3y3” sshpass -p $SSHPASS scp db_$(date +%F).sql [email protected]:/home/clint/db_backups [SSH] executing…
[SSH] Exception:SSH_MSG_DISCONNECT: 2 Too many authentication failures com.jcraft.jsch.JSchSessionDisconnectException: SSH_MSG_DISCONNECT: 2 Too many authentication failures at com.jcraft.jsch.Session.read(Session.java:1317) at com.jcraft.jsch.UserAuthPassword.start(UserAuthPassword.java:88) at com.jcraft.jsch.Session.connect(Session.java:480) at org.jvnet.hudson.plugins.CredentialsSSHSite.createSession(CredentialsSSHSite.java:132) at org.jvnet.hudson.plugins.CredentialsSSHSite.executeCommand(CredentialsSSHSite.java:208) at org.jvnet.hudson.plugins.SSHBuilder.perform(SSHBuilder.java:104) at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:20) at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:818) at hudson.model.Build$BuildExecution.build(Build.java:199) at hudson.model.Build$BuildExecution.doRun(Build.java:164) at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:526) at hudson.model.Run.execute(Run.java:1895) at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:44) at hudson.model.ResourceController.execute(ResourceController.java:101) at hudson.model.Executor.run(Executor.java:442) Build step ‘Execute shell script on remote host using ssh’ marked build as failure
Though I’m able to run the above commands on the host itself without any issues Jenkins job is showing me such an error. Do you have any idea on how to resolve the issue?