Не удается подключиться к SFTP uding apache camel

#apache-camel #sftp #camel-ftp

#apache-camel #sftp #camel-ftp

Вопрос:

Я использую Apache Camel 2.17.0 для выбора файла из местоположения SFTP. Это приложение Springboot. Я вижу, что после вызова SFTP пользователь SFTP автоматически блокируется, и я получаю сообщение об ошибке: не удается подключиться к sftp. Следующая ошибка связана с проблемой блокировки? Пожалуйста, помогите.

 org.apache.camel.component.file.GenericFileOperationFailedException: Cannot connect to sftp://GATEWAY:22/inbox?username=USERNAMEamp;password=#####/"
    at org.apache.camel.component.file.remote.SftpOperations.connect(SftpOperations.java:146) ~[camel-ftp-2.17.0.jar:2.17.0]
    at org.apache.camel.component.file.remote.RemoteFileConsumer.connectIfNecessary(RemoteFileConsumer.java:203) ~[camel-ftp-2.17.0.jar:2.17.0]
    at org.apache.camel.component.file.remote.SftpConsumer.doStart(SftpConsumer.java:52) ~[camel-ftp-2.17.0.jar:2.17.0]
    at org.apache.camel.support.ServiceSupport.start(ServiceSupport.java:61) [camel-core-2.17.0.jar:2.17.0]
    at org.apache.camel.impl.DefaultCamelContext.startService(DefaultCamelContext.java:3269) [camel-core-2.17.0.jar:2.17.0]
    at org.apache.camel.impl.DefaultCamelContext.doStartOrResumeRouteConsumers(DefaultCamelContext.java:3563) [camel-core-2.17.0.jar:2.17.0]
    at org.apache.camel.impl.DefaultCamelContext.doStartRouteConsumers(DefaultCamelContext.java:3499) [camel-core-2.17.0.jar:2.17.0]
    at org.apache.camel.impl.DefaultCamelContext.safelyStartRouteServices(DefaultCamelContext.java:3429) [camel-core-2.17.0.jar:2.17.0]
    at org.apache.camel.impl.DefaultCamelContext.doStartOrResumeRoutes(DefaultCamelContext.java:3197) [camel-core-2.17.0.jar:2.17.0]
    at org.apache.camel.impl.DefaultCamelContext.doStartCamel(DefaultCamelContext.java:3053) [camel-core-2.17.0.jar:2.17.0]
    at org.apache.camel.impl.DefaultCamelContext.access$000(DefaultCamelContext.java:175) [camel-core-2.17.0.jar:2.17.0]
    at org.apache.camel.impl.DefaultCamelContext$2.call(DefaultCamelContext.java:2848) [camel-core-2.17.0.jar:2.17.0]
    at org.apache.camel.impl.DefaultCamelContext$2.call(DefaultCamelContext.java:2844) [camel-core-2.17.0.jar:2.17.0]
    at org.apache.camel.impl.DefaultCamelContext.doWithDefinedClassLoader(DefaultCamelContext.java:2867) [camel-core-2.17.0.jar:2.17.0]
    at org.apache.camel.impl.DefaultCamelContext.doStart(DefaultCamelContext.java:2844) [camel-core-2.17.0.jar:2.17.0]
    at org.apache.camel.support.ServiceSupport.start(ServiceSupport.java:61) [camel-core-2.17.0.jar:2.17.0]
    at org.apache.camel.impl.DefaultCamelContext.start(DefaultCamelContext.java:2813) [camel-core-2.17.0.jar:2.17.0]
    at org.apache.camel.spring.boot.RoutesCollector.onApplicationEvent(RoutesCollector.java:116) [camel-spring-boot-2.17.0.jar:2.17.0]
    at org.apache.camel.spring.boot.RoutesCollector.onApplicationEvent(RoutesCollector.java:41) [camel-spring-boot-2.17.0.jar:2.17.0]
    at org.springframework.context.event.SimpleApplicationEventMulticaster.invokeListener(SimpleApplicationEventMulticaster.java:166) [spring-context-4.2.6.RELEASE.jar:4.2.6.RELEASE]
    at org.springframework.context.event.SimpleApplicationEventMulticaster.multicastEvent(SimpleApplicationEventMulticaster.java:138) [spring-context-4.2.6.RELEASE.jar:4.2.6.RELEASE]
    at org.springframework.context.support.AbstractApplicationContext.publishEvent(AbstractApplicationContext.java:381) [spring-context-4.2.6.RELEASE.jar:4.2.6.RELEASE]
    at org.springframework.context.support.AbstractApplicationContext.publishEvent(AbstractApplicationContext.java:335) [spring-context-4.2.6.RELEASE.jar:4.2.6.RELEASE]
    at org.springframework.context.support.AbstractApplicationContext.finishRefresh(AbstractApplicationContext.java:855) [spring-context-4.2.6.RELEASE.jar:4.2.6.RELEASE]
    at org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.finishRefresh(EmbeddedWebApplicationContext.java:140) [spring-boot-1.3.5.RELEASE.jar:1.3.5.RELEASE]
    at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:541) [spring-context-4.2.6.RELEASE.jar:4.2.6.RELEASE]
    at org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.refresh(EmbeddedWebApplicationContext.java:118) [spring-boot-1.3.5.RELEASE.jar:1.3.5.RELEASE]
    at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:766) [spring-boot-1.3.5.RELEASE.jar:1.3.5.RELEASE]
    at org.springframework.boot.SpringApplication.createAndRefreshContext(SpringApplication.java:361) [spring-boot-1.3.5.RELEASE.jar:1.3.5.RELEASE]
    at org.springframework.boot.SpringApplication.run(SpringApplication.java:307) [spring-boot-1.3.5.RELEASE.jar:1.3.5.RELEASE]
    at org.springframework.boot.SpringApplication.run(SpringApplication.java:1191) [spring-boot-1.3.5.RELEASE.jar:1.3.5.RELEASE]
    at org.springframework.boot.SpringApplication.run(SpringApplication.java:1180) [spring-boot-1.3.5.RELEASE.jar:1.3.5.RELEASE]
    at tripRecommenderPackage.MainApplication.main(MainApplication.java:10) [classes/:na]
Caused by: com.jcraft.jsch.JSchException: SSH_MSG_DISCONNECT: 11 Account is locked 
    at com.jcraft.jsch.Session.read(Session.java:996) ~[jsch-0.1.53.jar:na]
    at com.jcraft.jsch.UserAuthKeyboardInteractive.start(UserAuthKeyboardInteractive.java:77) ~[jsch-0.1.53.jar:na]
    at com.jcraft.jsch.Session.connect(Session.java:463) ~[jsch-0.1.53.jar:na]
    at org.apache.camel.component.file.remote.SftpOperations.connect(SftpOperations.java:118) ~[camel-ftp-2.17.0.jar:2.17.0]
    ... 32 common frames omitted
  

Ответ №1:

Да. Похоже, учетная запись заблокирована. Вы можете выполнить проверку с помощью sftp / ssh на удаленный сервер вручную.