From 99b3354777ea5e932a5518582a98ae07e0f3028e Mon Sep 17 00:00:00 2001 From: Rob Thijssen Date: Fri, 13 Aug 2021 13:05:37 +0300 Subject: [PATCH 1/9] example for self-hosted runners in the wild there are probably no examples of self-hosted runners whose service name is `actions.runner.octo-org-octo-repo.runner01.service` outside of octo-org. this change includes a command example that works in the wild. --- .../monitoring-and-troubleshooting-self-hosted-runners.md | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/content/actions/hosting-your-own-runners/monitoring-and-troubleshooting-self-hosted-runners.md b/content/actions/hosting-your-own-runners/monitoring-and-troubleshooting-self-hosted-runners.md index aabf76df00fa..1c6df96aa1c6 100644 --- a/content/actions/hosting-your-own-runners/monitoring-and-troubleshooting-self-hosted-runners.md +++ b/content/actions/hosting-your-own-runners/monitoring-and-troubleshooting-self-hosted-runners.md @@ -194,8 +194,13 @@ dial unix /var/run/docker.sock: connect: permission denied Check that the self-hosted runner's service account has permission to use the Docker service. You can identify this account by checking the configuration of the self-hosted runner in systemd. For example: ```shell +# if the service name is known: $ sudo systemctl show -p User actions.runner.octo-org-octo-repo.runner01.service User=runner-user + +# if the service name is not known (look for a service name starting with "actions.runner"): +$ sudo systemctl show -p User $(systemctl --type=service | grep actions.runner | grep -o "[^ ]*" | head -n 1) +User=runner-user ``` {% endlinux %} From a78e3aea47c1d96670faf18cdacfe702d54b64e0 Mon Sep 17 00:00:00 2001 From: Rob Thijssen Date: Fri, 13 Aug 2021 13:40:52 +0300 Subject: [PATCH 2/9] fixed more references --- ...itoring-and-troubleshooting-self-hosted-runners.md | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/content/actions/hosting-your-own-runners/monitoring-and-troubleshooting-self-hosted-runners.md b/content/actions/hosting-your-own-runners/monitoring-and-troubleshooting-self-hosted-runners.md index 1c6df96aa1c6..09af38537435 100644 --- a/content/actions/hosting-your-own-runners/monitoring-and-troubleshooting-self-hosted-runners.md +++ b/content/actions/hosting-your-own-runners/monitoring-and-troubleshooting-self-hosted-runners.md @@ -57,10 +57,21 @@ $ cat ~/actions-runner/.service actions.runner.octo-org-octo-repo.runner01.service ``` +If that fails due to the service being installed elsewhere, the service name can be obtained from the list of running services. For example: + +```shell +$ systemctl --type=service | grep actions.runner + actions.runner.org-repo.hostname.service loaded active running GitHub Actions Runner (org-repo.hostname) +``` + You can use `journalctl` to monitor the real-time activity of the self-hosted runner: ```shell +# if the service name is known: $ sudo journalctl -u actions.runner.octo-org-octo-repo.runner01.service -f + +# if the service name is not known: +$ sudo journalctl -u $(systemctl --type=service | grep actions.runner | grep -o "[^ ]*" | head -n 1) -f ``` In this example output, you can see `runner01` start, receive a job named `testAction`, and then display the resulting status: From 604b2d19a0222d77f5d297be605e25198ee82b22 Mon Sep 17 00:00:00 2001 From: Rob Thijssen Date: Fri, 13 Aug 2021 13:43:48 +0300 Subject: [PATCH 3/9] fixed more references --- .../monitoring-and-troubleshooting-self-hosted-runners.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/content/actions/hosting-your-own-runners/monitoring-and-troubleshooting-self-hosted-runners.md b/content/actions/hosting-your-own-runners/monitoring-and-troubleshooting-self-hosted-runners.md index 09af38537435..63e07292fe42 100644 --- a/content/actions/hosting-your-own-runners/monitoring-and-troubleshooting-self-hosted-runners.md +++ b/content/actions/hosting-your-own-runners/monitoring-and-troubleshooting-self-hosted-runners.md @@ -70,7 +70,7 @@ You can use `journalctl` to monitor the real-time activity of the self-hosted ru # if the service name is known: $ sudo journalctl -u actions.runner.octo-org-octo-repo.runner01.service -f -# if the service name is not known: +# if the service name is not known (look for a service name starting with "actions.runner"): $ sudo journalctl -u $(systemctl --type=service | grep actions.runner | grep -o "[^ ]*" | head -n 1) -f ``` From 99598b274cf100e203bce1126635212b81c6bde8 Mon Sep 17 00:00:00 2001 From: hubwriter Date: Tue, 14 Dec 2021 09:27:36 +0000 Subject: [PATCH 4/9] Update content/actions/hosting-your-own-runners/monitoring-and-troubleshooting-self-hosted-runners.md --- .../monitoring-and-troubleshooting-self-hosted-runners.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/content/actions/hosting-your-own-runners/monitoring-and-troubleshooting-self-hosted-runners.md b/content/actions/hosting-your-own-runners/monitoring-and-troubleshooting-self-hosted-runners.md index 63e07292fe42..33dd0babc255 100644 --- a/content/actions/hosting-your-own-runners/monitoring-and-troubleshooting-self-hosted-runners.md +++ b/content/actions/hosting-your-own-runners/monitoring-and-troubleshooting-self-hosted-runners.md @@ -57,7 +57,7 @@ $ cat ~/actions-runner/.service actions.runner.octo-org-octo-repo.runner01.service ``` -If that fails due to the service being installed elsewhere, the service name can be obtained from the list of running services. For example: +If this fails due to the service being installed elsewhere, you can find the service name in the list of running services. For example, on most Linux systems you can use the `systemctl` command: ```shell $ systemctl --type=service | grep actions.runner From 4cf3a11a97443a3b5a8f4314441370056880c7e9 Mon Sep 17 00:00:00 2001 From: hubwriter Date: Tue, 14 Dec 2021 09:27:45 +0000 Subject: [PATCH 5/9] Update content/actions/hosting-your-own-runners/monitoring-and-troubleshooting-self-hosted-runners.md --- .../monitoring-and-troubleshooting-self-hosted-runners.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/content/actions/hosting-your-own-runners/monitoring-and-troubleshooting-self-hosted-runners.md b/content/actions/hosting-your-own-runners/monitoring-and-troubleshooting-self-hosted-runners.md index 33dd0babc255..f4b18a220651 100644 --- a/content/actions/hosting-your-own-runners/monitoring-and-troubleshooting-self-hosted-runners.md +++ b/content/actions/hosting-your-own-runners/monitoring-and-troubleshooting-self-hosted-runners.md @@ -61,7 +61,7 @@ If this fails due to the service being installed elsewhere, you can find the ser ```shell $ systemctl --type=service | grep actions.runner - actions.runner.org-repo.hostname.service loaded active running GitHub Actions Runner (org-repo.hostname) +actions.runner.octo-org-octo-repo.hostname.service loaded active running GitHub Actions Runner (octo-org-octo-repo.hostname) ``` You can use `journalctl` to monitor the real-time activity of the self-hosted runner: From ca3fcefeec41e3f6973799d8be9e11184adadfe9 Mon Sep 17 00:00:00 2001 From: hubwriter Date: Tue, 14 Dec 2021 09:30:37 +0000 Subject: [PATCH 6/9] Update content/actions/hosting-your-own-runners/monitoring-and-troubleshooting-self-hosted-runners.md --- .../monitoring-and-troubleshooting-self-hosted-runners.md | 1 - 1 file changed, 1 deletion(-) diff --git a/content/actions/hosting-your-own-runners/monitoring-and-troubleshooting-self-hosted-runners.md b/content/actions/hosting-your-own-runners/monitoring-and-troubleshooting-self-hosted-runners.md index f4b18a220651..76c1cdf12d7a 100644 --- a/content/actions/hosting-your-own-runners/monitoring-and-troubleshooting-self-hosted-runners.md +++ b/content/actions/hosting-your-own-runners/monitoring-and-troubleshooting-self-hosted-runners.md @@ -67,7 +67,6 @@ actions.runner.octo-org-octo-repo.hostname.service loaded active running GitHub You can use `journalctl` to monitor the real-time activity of the self-hosted runner: ```shell -# if the service name is known: $ sudo journalctl -u actions.runner.octo-org-octo-repo.runner01.service -f # if the service name is not known (look for a service name starting with "actions.runner"): From d5912f303663271442ed6592859fbf76b3067ca7 Mon Sep 17 00:00:00 2001 From: hubwriter Date: Tue, 14 Dec 2021 09:30:43 +0000 Subject: [PATCH 7/9] Update content/actions/hosting-your-own-runners/monitoring-and-troubleshooting-self-hosted-runners.md --- .../monitoring-and-troubleshooting-self-hosted-runners.md | 3 --- 1 file changed, 3 deletions(-) diff --git a/content/actions/hosting-your-own-runners/monitoring-and-troubleshooting-self-hosted-runners.md b/content/actions/hosting-your-own-runners/monitoring-and-troubleshooting-self-hosted-runners.md index 76c1cdf12d7a..6d2362e7d9ba 100644 --- a/content/actions/hosting-your-own-runners/monitoring-and-troubleshooting-self-hosted-runners.md +++ b/content/actions/hosting-your-own-runners/monitoring-and-troubleshooting-self-hosted-runners.md @@ -68,9 +68,6 @@ You can use `journalctl` to monitor the real-time activity of the self-hosted ru ```shell $ sudo journalctl -u actions.runner.octo-org-octo-repo.runner01.service -f - -# if the service name is not known (look for a service name starting with "actions.runner"): -$ sudo journalctl -u $(systemctl --type=service | grep actions.runner | grep -o "[^ ]*" | head -n 1) -f ``` In this example output, you can see `runner01` start, receive a job named `testAction`, and then display the resulting status: From 5326477e49c44ee422545e914486ae93304562a7 Mon Sep 17 00:00:00 2001 From: hubwriter Date: Tue, 14 Dec 2021 09:30:49 +0000 Subject: [PATCH 8/9] Update content/actions/hosting-your-own-runners/monitoring-and-troubleshooting-self-hosted-runners.md --- .../monitoring-and-troubleshooting-self-hosted-runners.md | 1 - 1 file changed, 1 deletion(-) diff --git a/content/actions/hosting-your-own-runners/monitoring-and-troubleshooting-self-hosted-runners.md b/content/actions/hosting-your-own-runners/monitoring-and-troubleshooting-self-hosted-runners.md index 6d2362e7d9ba..24a36b927604 100644 --- a/content/actions/hosting-your-own-runners/monitoring-and-troubleshooting-self-hosted-runners.md +++ b/content/actions/hosting-your-own-runners/monitoring-and-troubleshooting-self-hosted-runners.md @@ -201,7 +201,6 @@ dial unix /var/run/docker.sock: connect: permission denied Check that the self-hosted runner's service account has permission to use the Docker service. You can identify this account by checking the configuration of the self-hosted runner in systemd. For example: ```shell -# if the service name is known: $ sudo systemctl show -p User actions.runner.octo-org-octo-repo.runner01.service User=runner-user From a52791b0f5f4ebe15bd1359acc109b1994833c3d Mon Sep 17 00:00:00 2001 From: hubwriter Date: Tue, 14 Dec 2021 09:30:56 +0000 Subject: [PATCH 9/9] Update content/actions/hosting-your-own-runners/monitoring-and-troubleshooting-self-hosted-runners.md --- .../monitoring-and-troubleshooting-self-hosted-runners.md | 4 ---- 1 file changed, 4 deletions(-) diff --git a/content/actions/hosting-your-own-runners/monitoring-and-troubleshooting-self-hosted-runners.md b/content/actions/hosting-your-own-runners/monitoring-and-troubleshooting-self-hosted-runners.md index 24a36b927604..8eb576a6b811 100644 --- a/content/actions/hosting-your-own-runners/monitoring-and-troubleshooting-self-hosted-runners.md +++ b/content/actions/hosting-your-own-runners/monitoring-and-troubleshooting-self-hosted-runners.md @@ -203,10 +203,6 @@ Check that the self-hosted runner's service account has permission to use the Do ```shell $ sudo systemctl show -p User actions.runner.octo-org-octo-repo.runner01.service User=runner-user - -# if the service name is not known (look for a service name starting with "actions.runner"): -$ sudo systemctl show -p User $(systemctl --type=service | grep actions.runner | grep -o "[^ ]*" | head -n 1) -User=runner-user ``` {% endlinux %}