Gitlab.comàProjectàLab01àSettingàCI/CD
CI/CD-->Runner à Create Project Manager
Create project runner
Tag -- Staging
Runner Description--Running Staging environment
Click create runner
Platform: Linux
[root@localhost ~]# [root@localhost ~]# gitlab-runner register --url https://gitlab.com --token glrt-QF42iv26n-J6NGzx1xg1OWM6MQpvOjEKcDoxZGV1ZXoKdDozCnU6bjQ4NGIc.01.1o0ok5mrp
-bash: [root@localhost: command not found
problem: gitlab command is not inserted
Solution:
click on How do I install GitLab Runner?
In Server
[root@localhost ~]# sudo chmod +x /usr/local/bin/gitlab-runner
[root@localhost ~]# sudo useradd --comment 'GitLab Runner' --create-home gitlab-runner --shell /bin/bash
[root@localhost ~]# # Install and run as a service
[root@localhost ~]# sudo gitlab-runner install --user=gitlab-runner --working-directory=/home/gitlab-runner
[root@localhost ~]# sudo gitlab-runner start
sudo: gitlab-runner: command not found
Problem:
[root@localhost ~]# gitlab-runner start
Segmentation fault
[root@localhost ~]# gitlab-runner register --url https://gitlab.com --token glrt-QF42iv26n-J6NGzx1xg1OWM6MQpvOjEKcDoxZGV1ZXoKdDozCnU6bjQ4NGIc.01.1o0ok5mrp
Segmentation fault
Solution:
# Remove existing
rm -f /usr/local/bin/gitlab-runner
# Re-download (replace amd64 with arm64/arm if needed)
curl -L --output /usr/local/bin/gitlab-runner \ "https://gitlab-runner-downloads.s3.amazonaws.com/latest/binaries/gitlab-runner-linux-amd64"
[root@localhost ~]# chmod +x /usr/local/bin/gitlab-runner
[root@localhost ~]# gitlab-runner --version
Version: 19.0.1
Git revision: c2831b75
Git branch: 19-0-stable
GO version: go1.26.3
Built: 2026-05-29T16:20:59Z
OS/Arch: linux/amd64
Another Solution
[root@localhost ~]# sudo gitlab-runner install --user=gitlab-runner --working-directory=/home/gitlab-runner
sudo: gitlab-runner: command not found
[root@localhost ~]# sudo gitlab-runner start
sudo: gitlab-runner: command not found
[root@localhost ~]# gitlab-runner register --url https://gitlab.com --token glrt-td8PAysWFg0BO0zlqpuhW2M6MQpvOjEKcDoxZGV1ZXoKdDozCnU6bjQ4NGIc.01.1o021wx9q
Runtime platform arch=amd64 os=linux pid=29544 revision=c2831b75 version=19.0.1
Running in system-mode.
Enter the GitLab instance URL (for example, https://gitlab.com/):
[https://gitlab.com]: <enter only>
Verifying runner... is valid correlation_id=a0cb1d59cfd87674-KTM runner=6lD4JwZjY runner_name=localhost.localdomain
Enter a name for the runner. This is stored only in the local config.toml file:
[localhost.localdomain]: staging <name of the runner>
Enter an executor: ssh, parallels, virtualbox, shell, docker, docker-windows, docker-autoscaler, docker+machine, custom, instance, kubernetes:
SHELL
ERROR: Invalid executor specified
Enter an executor: ssh, parallels, virtualbox, shell, docker, docker-windows, docker-autoscaler, docker+machine, custom, instance, kubernetes:
[SHELL]: shell <IN SMALL Letter>
Runner registered successfully. Feel free to start it, but if it's running already the config should be automatically reloaded!
Configuration (with the authentication token) was saved in "/etc/gitlab-runner/config.toml"
[root@localhost
~]# gitlab-runner run
Runtime
platform
arch=amd64 os=linux pid=12523 revision=c2831b75 version=19.0.1
Starting
multi-runner from /etc/gitlab-runner/config.toml... builds=0 max_builds=0
Running in
system-mode.
Usage logger
disabled
builds=0 max_builds=1
Configuration
loaded
builds=0 max_builds=1
WARNING:
CONFIGURATION: Long polling issues detected.
Issues found:
- Request bottleneck: 1 runners have
request_concurrency=1, causing job delays during long polling
This can cause
job delays matching your GitLab instance's long polling timeout.
Recommended
solutions:
1. Increase 'request_concurrency' to 2-4 for
1 runners currently using request_concurrency=1
Note: The
'FF_USE_ADAPTIVE_REQUEST_CONCURRENCY' feature flag can help automatically
adjust request_concurrency based on workload.
This message
will be printed each time the configuration is reloaded if the issues persist.
See
documentation:
https://docs.gitlab.com/runner/configuration/advanced-configuration.html#long-polling-issues builds=0 max_builds=1
listen_address
not defined, metrics & debug endpoints disabled builds=0 max_builds=1
[session_server].listen_address
not defined, session endpoints disabled
builds=0 max_builds=1
Initializing
executor providers
builds=0 max_builds=1
WARNING:
Checking for jobs... failed
correlation_id=f71ea12f8336464385dc947cef66e79b runner=74H2SChOP
runner_name=gitlab-runner register --url
https://gitlab.com --token
glrt-74H2SChOPxVUWl49xORjfWM6MQpvOjEKcDoxZGxtZGoKdDozCnU6bjQ4NGIc.01.1o0us0d7e
status=execute JSON request: execute request: couldn't execute POST against
https://gitlab.com/api/v4/jobs/request: Post "https://gitlab.com/api/v4/jobs/request":
read tcp 192.168.184.131:37030->172.65.251.78:443: read: connection reset by
peer
WARNING:
[runWait] received stop signal
builds=0 max_builds=1 stop-signal=interrupt
WARNING:
Graceful shutdown not finished properly. To gracefully clean up running plugins
please use SIGQUIT (ctrl-\) instead of SIGINT (ctrl-c) builds=0 error=received stop signal:
interrupt max_builds=1
WARNING:
Starting forceful shutdown
StopSignal=interrupt builds=0 max_builds=1 shutdown-timeout=30s
WARNING:
Checking for jobs... failed
correlation_id=c690d90e9e7741c59a088c10e19113db runner=74H2SChOP
runner_name=gitlab-runner register --url
https://gitlab.com --token
glrt-74H2SChOPxVUWl49xORjfWM6MQpvOjEKcDoxZGxtZGoKdDozCnU6bjQ4NGIc.01.1o0us0d7e
status=execute JSON request: execute request: couldn't execute POST against
https://gitlab.com/api/v4/jobs/request: Post "https://gitlab.com/api/v4/jobs/request":
context canceled
All workers
stopped.
builds=0 max_builds=1
Shutting down
executor providers
builds=0 max_builds=1 shutdown-timeout=30s
Shutting down
docker+machine executor provider
executor=docker+machine
No shutdown
drain config, skipping machine pool drain
executor=docker+machine
All executor
providers shut down.
builds=0 max_builds=1
Can exit
now!
builds=0 max_builds=1
No comments:
Post a Comment