Skip to content
This repository has been archived by the owner on Jun 6, 2024. It is now read-only.

Commit

Permalink
add error spec for port conflict
Browse files Browse the repository at this point in the history
  • Loading branch information
Binyang2014 committed Sep 11, 2019
1 parent 4de08c4 commit c8198a1
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 2 deletions.
17 changes: 16 additions & 1 deletion src/k8s-job-exit-spec/config/k8s-job-exit-spec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -565,7 +565,7 @@ spec:
reaction: RETRY_TO_MAX
reason: "Failed to start docker container due to unknown error"
repro:
- "Submit a Pod with unknown capability specified in its SecurityContext"
- "Submit a Pod with unknown capability specified in its SecurityContext"
solution:
- "Check diagnostics and find root cause"
- "Wait result from next retry"
Expand Down Expand Up @@ -884,6 +884,21 @@ spec:
solution:
- "Contact PAI Dev to fix the PAI Runtime bug"

- code: 253
phrase: PortConflictCheckFailed
issuer: PAI_RUNTIME
causer: PAI_RUNTIME
type: PLATFORM_FAILURE
stage: LAUNCHING
behavior: TRANSIENT
reaction: ALWAYS_RETRY
reason: "Can not alloc request ports due to ports is occupied"
repro:
- "Run task in a host which most of ports are occupied"
solution:
- "Wait result from next retry"
- "Decrease per task ports request"

- code: 255
phrase: PAIRuntimeUnknownFailed
issuer: PAI_RUNTIME
Expand Down
2 changes: 1 addition & 1 deletion src/kube-runtime/src/init.d/port.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
def check_port(portno):
"""Check whether the port is in use.
Exit with code 200 if the port is already in use.
Exit with code 10 if the port is already in use.
Args:
portno: Port number to check.
Expand Down

0 comments on commit c8198a1

Please sign in to comment.