Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement CLI/API feature showing actual hostnames where allocation runs. #2359

Closed
zoza1982 opened this issue Feb 24, 2017 · 4 comments
Closed

Comments

@zoza1982
Copy link

Hi, this is a feature request.

Since killing a specific allocation which is part of the same job with multiple instances is not implemented yet (#2181) it would be good for purposes of chasing down that bad behaving allocation and killing it manually with kill -9 to add ability to both "nomad status " CLI and API to show the actual hostname where allocation runs along with other info like Node ID.

@schmichael
Copy link
Member

In the meantime I took a stab at a curl+jq script to make things a little easier:

#!/bin/bash
set -e

ids=$(curl -s localhost:4646/v1/allocations | jq  -r ".[] | select(.JobID==\"$1\") | .NodeID")
for id in $ids; do
    curl -s localhost:4646/v1/nodes | jq -r ".[] | select(.ID==\"$id\") | .Name"
done

@zoza1982
Copy link
Author

Thanks! That will work in the meantime!

jrasell added a commit to jrasell/nomad that referenced this issue Jul 17, 2018
Currently when operators need to log onto a machine where an alloc
is running they will need to perform both an alloc/job status
call and then a call to discover the node name from the node list.

This updates both the job status and alloc status output to include
the node name within the information to make operator use easier.

Closes hashicorp#2359
Cloess hashicorp#1180
@arshjohar
Copy link
Contributor

We merged a PR that should display Node Name for job status and alloc status commands. Closing this one.

preetapan pushed a commit that referenced this issue Mar 4, 2019
Currently when operators need to log onto a machine where an alloc
is running they will need to perform both an alloc/job status
call and then a call to discover the node name from the node list.

This updates both the job status and alloc status output to include
the node name within the information to make operator use easier.

Closes #2359
Cloess #1180
preetapan pushed a commit that referenced this issue Mar 25, 2019
Currently when operators need to log onto a machine where an alloc
is running they will need to perform both an alloc/job status
call and then a call to discover the node name from the node list.

This updates both the job status and alloc status output to include
the node name within the information to make operator use easier.

Closes #2359
Cloess #1180
preetapan pushed a commit that referenced this issue Apr 10, 2019
Currently when operators need to log onto a machine where an alloc
is running they will need to perform both an alloc/job status
call and then a call to discover the node name from the node list.

This updates both the job status and alloc status output to include
the node name within the information to make operator use easier.

Closes #2359
Cloess #1180
@github-actions
Copy link

I'm going to lock this issue because it has been closed for 120 days ⏳. This helps our maintainers find and focus on the active issues.
If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Nov 26, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants