dolphinscheduler icon indicating copy to clipboard operation
dolphinscheduler copied to clipboard

[Bug] [seatunnel ] Seatunnel job use resource script executed failed

Open cYfaris opened this issue 1 year ago • 1 comments

Search before asking

  • [x] I had searched in the issues and found no similar issues.

What happened

I try to use seatunnel to submit job from resource(minio) rather than writing a script . Results: Error message when running : Caused by: org.apache.seatunnel.common.exception.SeaTunnelRuntimeException: ErrorCode:[COMMON-22], ErrorDescription:[SeaTunnel read file 'dolphinscheduler/dataTeam/resources/scripts/v2.streaming.conf' failed, because it not existed.]


The following is the complete error message:


[LOG-PATH]: /opt/dolphinscheduler/apache-dolphinscheduler-3.2.2-bin/worker-server/logs/20250718/146751318608800/12/49/68.log, [HOST]:  xxx
[INFO] 2025-07-18 09:12:56.153 +0800 - 
***********************************************************************************************
[INFO] 2025-07-18 09:12:56.155 +0800 - *********************************  Initialize task context  ***********************************
[INFO] 2025-07-18 09:12:56.155 +0800 - ***********************************************************************************************
[INFO] 2025-07-18 09:12:56.155 +0800 - Begin to initialize task
[INFO] 2025-07-18 09:12:56.156 +0800 - Set task startTime: 1752801176156
[INFO] 2025-07-18 09:12:56.156 +0800 - Set task appId: 49_68
[INFO] 2025-07-18 09:12:56.157 +0800 - End initialize task {
  "taskInstanceId" : 68,
  "taskName" : "task",
  "firstSubmitTime" : 1752801176006,
  "startTime" : 1752801176156,
  "taskType" : "SEATUNNEL",
  "workflowInstanceHost" : "xxx",
  "host" : "xxx",
  "logPath" : "/opt/dolphinscheduler/apache-dolphinscheduler-3.2.2-bin/worker-server/logs/20250718/146751318608800/12/49/68.log",
  "processId" : 0,
  "processDefineCode" : 146751318608800,
  "processDefineVersion" : 12,
  "processInstanceId" : 49,
  "scheduleTime" : 0,
  "executorId" : 2,
  "cmdTypeIfComplement" : 0,
  "tenantCode" : "dataTeam",
  "processDefineId" : 0,
  "projectId" : 0,
  "projectCode" : 146215285386720,
  "taskParams" : "{\"localParams\":[],\"rawScript\":\"${SEATUNNEL_HOME}/bin/seatunnel.sh -c ${resource:scripts/v2.streaming.conf} -m cluster\\n\",\"resourceList\":[{\"id\":null,\"resourceName\":\"dolphinscheduler/dataTeam/resources/scripts/v2.streaming.conf\",\"res\":null}],\"startupScript\":\"seatunnel.sh\",\"useCustom\":false,\"deployMode\":\"cluster\",\"others\":\"\"}",
  "prepareParamsMap" : {
    "system.task.definition.name" : {
      "prop" : "system.task.definition.name",
      "direct" : "IN",
      "type" : "VARCHAR",
      "value" : "task"
    },
    "system.project.name" : {
      "prop" : "system.project.name",
      "direct" : "IN",
      "type" : "VARCHAR",
      "value" : null
    },
    "system.project.code" : {
      "prop" : "system.project.code",
      "direct" : "IN",
      "type" : "VARCHAR",
      "value" : "146215285386720"
    },
    "system.workflow.instance.id" : {
      "prop" : "system.workflow.instance.id",
      "direct" : "IN",
      "type" : "VARCHAR",
      "value" : "49"
    },
    "system.biz.curdate" : {
      "prop" : "system.biz.curdate",
      "direct" : "IN",
      "type" : "VARCHAR",
      "value" : "20250718"
    },
    "system.biz.date" : {
      "prop" : "system.biz.date",
      "direct" : "IN",
      "type" : "VARCHAR",
      "value" : "20250717"
    },
    "system.task.instance.id" : {
      "prop" : "system.task.instance.id",
      "direct" : "IN",
      "type" : "VARCHAR",
      "value" : "68"
    },
    "system.workflow.definition.name" : {
      "prop" : "system.workflow.definition.name",
      "direct" : "IN",
      "type" : "VARCHAR",
      "value" : "stream-job"
    },
    "system.task.definition.code" : {
      "prop" : "system.task.definition.code",
      "direct" : "IN",
      "type" : "VARCHAR",
      "value" : "146751137775520"
    },
    "system.workflow.definition.code" : {
      "prop" : "system.workflow.definition.code",
      "direct" : "IN",
      "type" : "VARCHAR",
      "value" : "146751318608800"
    },
    "system.datetime" : {
      "prop" : "system.datetime",
      "direct" : "IN",
      "type" : "VARCHAR",
      "value" : "20250718091256"
    }
  },
  "taskAppId" : "49_68",
  "taskTimeout" : 2147483647,
  "workerGroup" : "345",
  "delayTime" : 0,
  "currentExecutionStatus" : "SUBMITTED_SUCCESS",
  "endTime" : 0,
  "dryRun" : 0,
  "paramsMap" : { },
  "cpuQuota" : -1,
  "memoryMax" : -1,
  "testFlag" : 0,
  "logBufferEnable" : false,
  "dispatchFailTimes" : 0
}
[INFO] 2025-07-18 09:12:56.157 +0800 - 
***********************************************************************************************
[INFO] 2025-07-18 09:12:56.158 +0800 - *********************************  Load task instance plugin  *********************************
[INFO] 2025-07-18 09:12:56.158 +0800 - ***********************************************************************************************
[INFO] 2025-07-18 09:12:56.177 +0800 - Send task status RUNNING_EXECUTION master:  xxx
[INFO] 2025-07-18 09:12:56.178 +0800 - TenantCode: dataTeam check successfully
[INFO] 2025-07-18 09:12:56.178 +0800 - WorkflowInstanceExecDir: /tmp/dolphinscheduler/exec/process/dataTeam/146215285386720/146751318608800_12/49/68 check successfully
[INFO] 2025-07-18 09:12:56.179 +0800 - Create TaskChannel: org.apache.dolphinscheduler.plugin.task.seatunnel.SeatunnelTaskChannel successfully
[INFO] 2025-07-18 09:12:56.189 +0800 - Download resources successfully: 
ResourceContext(resourceItemMap={dolphinscheduler/dataTeam/resources/scripts/v2.streaming.conf=ResourceContext.ResourceItem(resourceAbsolutePathInStorage=dolphinscheduler/dataTeam/resources/scripts/v2.streaming.conf, resourceAbsolutePathInLocal=/tmp/dolphinscheduler/exec/process/dataTeam/146215285386720/146751318608800_12/49/68/scripts/v2.streaming.conf)})
[INFO] 2025-07-18 09:12:56.190 +0800 - Download upstream files: [] successfully
[INFO] 2025-07-18 09:12:56.191 +0800 - Task plugin instance: SEATUNNEL create successfully
[INFO] 2025-07-18 09:12:56.195 +0800 - Intialize SeaTunnel task params {
  "localParams" : [ ],
  "varPool" : [ ],
  "startupScript" : "seatunnel.sh",
  "useCustom" : false,
  "rawScript" : "${SEATUNNEL_HOME}/bin/seatunnel.sh -c ${resource:scripts/v2.streaming.conf} -m cluster\n",
  "resourceList" : [ {
    "id" : null,
    "resourceName" : "dolphinscheduler/dataTeam/resources/scripts/v2.streaming.conf",
    "res" : null
  } ],
  "deployMode" : "cluster",
  "others" : ""
}
[INFO] 2025-07-18 09:12:56.196 +0800 - Success initialized task plugin instance successfully
[INFO] 2025-07-18 09:12:56.196 +0800 - Set taskVarPool: null successfully
[INFO] 2025-07-18 09:12:56.196 +0800 - 
***********************************************************************************************
[INFO] 2025-07-18 09:12:56.196 +0800 - *********************************  Execute task instance  *************************************
[INFO] 2025-07-18 09:12:56.196 +0800 - ***********************************************************************************************
[INFO] 2025-07-18 09:12:56.197 +0800 - SeaTunnel task command: ${SEATUNNEL_HOME}/bin/seatunnel.sh --config dolphinscheduler/dataTeam/resources/scripts/v2.streaming.conf --deploy-mode cluster
[INFO] 2025-07-18 09:12:56.197 +0800 - Final Shell file is: 
[INFO] 2025-07-18 09:12:56.198 +0800 - ****************************** Script Content *****************************************************************
[INFO] 2025-07-18 09:12:56.198 +0800 - #!/bin/bash
BASEDIR=$(cd `dirname $0`; pwd)
cd $BASEDIR
${SEATUNNEL_HOME}/bin/seatunnel.sh --config dolphinscheduler/dataTeam/resources/scripts/v2.streaming.conf --deploy-mode cluster
[INFO] 2025-07-18 09:12:56.198 +0800 - ****************************** Script Content *****************************************************************
[INFO] 2025-07-18 09:12:56.198 +0800 - Executing shell command : sudo -u dataTeam -i /tmp/dolphinscheduler/exec/process/dataTeam/146215285386720/146751318608800_12/49/68/49_68.sh
[INFO] 2025-07-18 09:12:56.200 +0800 - process start, process id is: 23957
[INFO] 2025-07-18 09:12:57.200 +0800 -  -> 
	2025-07-18 09:12:56,632 WARN  [ommandArgs$MasterTypeValidator] [main] - 
	******************************************************************************************
	-e and --deploy-mode deprecated in 2.3.1, please use -m and --master instead of it
	******************************************************************************************
	2025-07-18 09:12:56,657 INFO  [c.h.i.c.AbstractConfigLocator ] [main] - Loading configuration '/opt/seatunal/apache-seatunnel-2.3.11/config/seatunnel.yaml' from System property 'seatunnel.config'
	2025-07-18 09:12:56,657 INFO  [c.h.i.c.AbstractConfigLocator ] [main] - Using configuration file at /opt/seatunal/apache-seatunnel-2.3.11/config/seatunnel.yaml
	2025-07-18 09:12:56,659 INFO  [o.a.s.e.c.c.SeaTunnelConfig   ] [main] - seatunnel.home is /tmp/dolphinscheduler/exec/process/dataTeam/146215285386720/146751318608800_12/49/68
	2025-07-18 09:12:56,736 INFO  [c.h.i.c.AbstractConfigLocator ] [main] - Loading configuration '/opt/seatunal/apache-seatunnel-2.3.11/config/hazelcast.yaml' from System property 'hazelcast.config'
	2025-07-18 09:12:56,737 INFO  [c.h.i.c.AbstractConfigLocator ] [main] - Using configuration file at /opt/seatunal/apache-seatunnel-2.3.11/config/hazelcast.yaml
	2025-07-18 09:12:57,000 INFO  [c.h.i.c.AbstractConfigLocator ] [main] - Loading configuration '/opt/seatunal/apache-seatunnel-2.3.11/config/hazelcast-client.yaml' from System property 'hazelcast.client.config'
	2025-07-18 09:12:57,000 INFO  [c.h.i.c.AbstractConfigLocator ] [main] - Using configuration file at /opt/seatunal/apache-seatunnel-2.3.11/config/hazelcast-client.yaml
[INFO] 2025-07-18 09:12:58.202 +0800 -  -> 
	2025-07-18 09:12:57,204 INFO  [.c.i.s.ClientInvocationService] [main] - hz.client_1 [seatunnel] [5.1] Running with 2 response threads, dynamic=true
	2025-07-18 09:12:57,247 INFO  [c.h.c.LifecycleService        ] [main] - hz.client_1 [seatunnel] [5.1] HazelcastClient 5.1 (20220228 - 21f20e7) is STARTING
	2025-07-18 09:12:57,248 INFO  [c.h.c.LifecycleService        ] [main] - hz.client_1 [seatunnel] [5.1] HazelcastClient 5.1 (20220228 - 21f20e7) is STARTED
	2025-07-18 09:12:57,264 INFO  [.c.i.c.ClientConnectionManager] [main] - hz.client_1 [seatunnel] [5.1] Trying to connect to cluster: seatunnel
	2025-07-18 09:12:57,266 INFO  [.c.i.c.ClientConnectionManager] [main] - hz.client_1 [seatunnel] [5.1] Trying to connect to [node1]:5801
	2025-07-18 09:12:57,291 INFO  [c.h.c.LifecycleService        ] [main] - hz.client_1 [seatunnel] [5.1] HazelcastClient 5.1 (20220228 - 21f20e7) is CLIENT_CONNECTED
	2025-07-18 09:12:57,291 INFO  [.c.i.c.ClientConnectionManager] [main] - hz.client_1 [seatunnel] [5.1] Authenticated with server [node1]:5801:485edcbb-375e-46d4-9480-e7226ea3cbbd, server version: 5.1, local address: /xxx:36367
	2025-07-18 09:12:57,292 INFO  [c.h.i.d.Diagnostics           ] [main] - hz.client_1 [seatunnel] [5.1] Diagnostics disabled. To enable add -Dhazelcast.diagnostics.enabled=true to the JVM arguments.
	2025-07-18 09:12:57,299 INFO  [c.h.c.i.s.ClientClusterService] [hz.client_1.event-4] - hz.client_1 [seatunnel] [5.1] 
	
	Members [5] {
		Member [node1]:5801 - 485edcbb-375e-46d4-9480-e7226ea3cbbd [master node]
		Member [node2]:5802 - 58e4c693-0278-494f-8598-154ed381c838 [worker node]
		Member [node3]:5802 - a2ca359b-a26c-44da-aff7-bba6864111c2 [worker node]
		Member [node5]:5802 - f0c9211c-663c-4258-a7db-e976442ef6cf [worker node]
		Member [node4]:5802 - 9700535f-6aa8-4cc0-8820-364479736ada [worker node]
	}
	
	2025-07-18 09:12:57,304 INFO  [.c.i.c.ClientConnectionManager] [main] - hz.client_1 [seatunnel] [5.1] Authenticated with server [node2]:5802:58e4c693-0278-494f-8598-154ed381c838, server version: 5.1, local address: /xxx:34775
	2025-07-18 09:12:57,306 INFO  [.c.i.c.ClientConnectionManager] [main] - hz.client_1 [seatunnel] [5.1] Authenticated with server [node3]:5802:a2ca359b-a26c-44da-aff7-bba6864111c2, server version: 5.1, local address: /xxx:54456
	2025-07-18 09:12:57,308 INFO  [.c.i.c.ClientConnectionManager] [main] - hz.client_1 [seatunnel] [5.1] Authenticated with server [node5]:5802:f0c9211c-663c-4258-a7db-e976442ef6cf, server version: 5.1, local address: /xxx:57978
	2025-07-18 09:12:57,311 INFO  [.c.i.c.ClientConnectionManager] [main] - hz.client_1 [seatunnel] [5.1] Authenticated with server [node4]:5802:9700535f-6aa8-4cc0-8820-364479736ada, server version: 5.1, local address: /xxx:49704
	2025-07-18 09:12:57,334 INFO  [.c.i.s.ClientStatisticsService] [main] - Client statistics is enabled with period 5 seconds.
	2025-07-18 09:12:57,435 INFO  [c.h.c.LifecycleService        ] [main] - hz.client_1 [seatunnel] [5.1] HazelcastClient 5.1 (20220228 - 21f20e7) is SHUTTING_DOWN
	2025-07-18 09:12:57,438 INFO  [.c.i.c.ClientConnectionManager] [main] - hz.client_1 [seatunnel] [5.1] Removed connection to endpoint: [node1]:5801:485edcbb-375e-46d4-9480-e7226ea3cbbd, connection: ClientConnection{alive=false, connectionId=1, channel=NioChannel{/xxx:36367->node1/xxx:5801}, remoteAddress=[node1]:5801, lastReadTime=2025-07-18 09:12:57.323, lastWriteTime=2025-07-18 09:12:57.323, closedTime=2025-07-18 09:12:57.436, connected server version=5.1}
	2025-07-18 09:12:57,439 INFO  [.c.i.c.ClientConnectionManager] [main] - hz.client_1 [seatunnel] [5.1] Removed connection to endpoint: [node3]:5802:a2ca359b-a26c-44da-aff7-bba6864111c2, connection: ClientConnection{alive=false, connectionId=3, channel=NioChannel{/xxx:54456->node3/xxx:5802}, remoteAddress=[node3]:5802, lastReadTime=2025-07-18 09:12:57.371, lastWriteTime=2025-07-18 09:12:57.371, closedTime=2025-07-18 09:12:57.438, connected server version=5.1}
	2025-07-18 09:12:57,441 INFO  [.c.i.c.ClientConnectionManager] [main] - hz.client_1 [seatunnel] [5.1] Removed connection to endpoint: [node4]:5802:9700535f-6aa8-4cc0-8820-364479736ada, connection: ClientConnection{alive=false, connectionId=5, channel=NioChannel{/xxx:49704->node4/xxx:5802}, remoteAddress=[node4]:5802, lastReadTime=2025-07-18 09:12:57.326, lastWriteTime=2025-07-18 09:12:57.325, closedTime=2025-07-18 09:12:57.440, connected server version=5.1}
	2025-07-18 09:12:57,442 INFO  [.c.i.c.ClientConnectionManager] [main] - hz.client_1 [seatunnel] [5.1] Removed connection to endpoint: [node5]:5802:f0c9211c-663c-4258-a7db-e976442ef6cf, connection: ClientConnection{alive=false, connectionId=4, channel=NioChannel{/xxx:57978->node5/xxx:5802}, remoteAddress=[node5]:5802, lastReadTime=2025-07-18 09:12:57.326, lastWriteTime=2025-07-18 09:12:57.326, closedTime=2025-07-18 09:12:57.441, connected server version=5.1}
	2025-07-18 09:12:57,443 INFO  [.c.i.c.ClientConnectionManager] [main] - hz.client_1 [seatunnel] [5.1] Removed connection to endpoint: [node2]:5802:58e4c693-0278-494f-8598-154ed381c838, connection: ClientConnection{alive=false, connectionId=2, channel=NioChannel{/xxx:34775->node2/xxx:5802}, remoteAddress=[node2]:5802, lastReadTime=2025-07-18 09:12:57.327, lastWriteTime=2025-07-18 09:12:57.326, closedTime=2025-07-18 09:12:57.442, connected server version=5.1}
	2025-07-18 09:12:57,443 INFO  [c.h.c.LifecycleService        ] [main] - hz.client_1 [seatunnel] [5.1] HazelcastClient 5.1 (20220228 - 21f20e7) is CLIENT_DISCONNECTED
	2025-07-18 09:12:57,445 INFO  [c.h.c.LifecycleService        ] [main] - hz.client_1 [seatunnel] [5.1] HazelcastClient 5.1 (20220228 - 21f20e7) is SHUTDOWN
	2025-07-18 09:12:57,445 INFO  [s.c.s.s.c.ClientExecuteCommand] [main] - Closed SeaTunnel client......
	2025-07-18 09:12:57,445 ERROR [o.a.s.c.s.SeaTunnel           ] [main] - 
	
	===============================================================================
	
	
	2025-07-18 09:12:57,445 ERROR [o.a.s.c.s.SeaTunnel           ] [main] - Fatal Error, 
	
	2025-07-18 09:12:57,445 ERROR [o.a.s.c.s.SeaTunnel           ] [main] - Please submit bug report in https://github.com/apache/seatunnel/issues
	
	2025-07-18 09:12:57,447 ERROR [o.a.s.c.s.SeaTunnel           ] [main] - Reason:SeaTunnel job executed failed 
	
	2025-07-18 09:12:57,448 ERROR [o.a.s.c.s.SeaTunnel           ] [main] - Exception StackTrace:org.apache.seatunnel.core.starter.exception.CommandExecuteException: SeaTunnel job executed failed
		at org.apache.seatunnel.core.starter.seatunnel.command.ClientExecuteCommand.execute(ClientExecuteCommand.java:228)
		at org.apache.seatunnel.core.starter.SeaTunnel.run(SeaTunnel.java:40)
		at org.apache.seatunnel.core.starter.seatunnel.SeaTunnelClient.main(SeaTunnelClient.java:40)
	Caused by: org.apache.seatunnel.common.exception.SeaTunnelRuntimeException: ErrorCode:[COMMON-22], ErrorDescription:[SeaTunnel read file 'dolphinscheduler/dataTeam/resources/scripts/v2.streaming.conf' failed, because it not existed.]
		at org.apache.seatunnel.common.exception.CommonError.fileNotExistFailed(CommonError.java:89)
		at org.apache.seatunnel.core.starter.utils.FileUtils.checkConfigExist(FileUtils.java:66)
		at org.apache.seatunnel.core.starter.seatunnel.command.ClientExecuteCommand.execute(ClientExecuteCommand.java:138)
		... 2 more
	 
	2025-07-18 09:12:57,448 ERROR [o.a.s.c.s.SeaTunnel           ] [main] - 
	===============================================================================
	
	
	
	Exception in thread "main" org.apache.seatunnel.core.starter.exception.CommandExecuteException: SeaTunnel job executed failed
		at org.apache.seatunnel.core.starter.seatunnel.command.ClientExecuteCommand.execute(ClientExecuteCommand.java:228)
		at org.apache.seatunnel.core.starter.SeaTunnel.run(SeaTunnel.java:40)
		at org.apache.seatunnel.core.starter.seatunnel.SeaTunnelClient.main(SeaTunnelClient.java:40)
	Caused by: org.apache.seatunnel.common.exception.SeaTunnelRuntimeException: ErrorCode:[COMMON-22], ErrorDescription:[SeaTunnel read file 'dolphinscheduler/dataTeam/resources/scripts/v2.streaming.conf' failed, because it not existed.]
		at org.apache.seatunnel.common.exception.CommonError.fileNotExistFailed(CommonError.java:89)
		at org.apache.seatunnel.core.starter.utils.FileUtils.checkConfigExist(FileUtils.java:66)
		at org.apache.seatunnel.core.starter.seatunnel.command.ClientExecuteCommand.execute(ClientExecuteCommand.java:138)
		... 2 more
[INFO] 2025-07-18 09:12:58.205 +0800 - process has exited. execute path:/tmp/dolphinscheduler/exec/process/dataTeam/146215285386720/146751318608800_12/49/68, processId:23957 ,exitStatusCode:1 ,processWaitForStatus:true ,processExitValue:1
[INFO] 2025-07-18 09:12:58.205 +0800 - 
***********************************************************************************************
[INFO] 2025-07-18 09:12:58.205 +0800 - *********************************  Finalize task instance  ************************************
[INFO] 2025-07-18 09:12:58.205 +0800 - ***********************************************************************************************
[INFO] 2025-07-18 09:12:58.206 +0800 - Upload output files: [] successfully
[INFO] 2025-07-18 09:12:58.212 +0800 - Send task execute status: FAILURE to master : xxx:1234
[INFO] 2025-07-18 09:12:58.213 +0800 - Remove the current task execute context from worker cache
[INFO] 2025-07-18 09:12:58.213 +0800 - The current execute mode isn't develop mode, will clear the task execute file: /tmp/dolphinscheduler/exec/process/dataTeam/146215285386720/146751318608800_12/49/68
[INFO] 2025-07-18 09:12:58.213 +0800 - Success clear the task execute file: /tmp/dolphinscheduler/exec/process/dataTeam/146215285386720/146751318608800_12/49/68
[INFO] 2025-07-18 09:12:58.213 +0800 - FINALIZE_SESSION



use version: dolphin : 3.2.2
seatunnel-2.3.11


seatunnel task:

Image

What you expected to happen

...

How to reproduce

create an seatunnel task, using resource center seatunnel script file

Anything else

No response

Version

3.2.x

Are you willing to submit PR?

  • [x] Yes I am willing to submit a PR!

Code of Conduct

cYfaris avatar Jul 18 '25 02:07 cYfaris

Fixed in 3.3.0

SbloodyS avatar Jul 18 '25 05:07 SbloodyS