Дженкинс раб не может установить java через ням - PullRequest
0 голосов
/ 12 февраля 2020

Я следую этому руководству и застрял при настройке моего ведомого устройства Jenkins с использованием только что созданной конфигурации Cloud.

Я использую общедоступный c Amazon AMI (ami- 062f7200baf2fa504) для ведомого.

После нажатия на Provision via <cloud-name> я раскручиваю нового ведомого, а затем журналы выглядят следующим образом:

INFO: Connected via SSH.
Feb 12, 2020 8:34:00 AM hudson.plugins.ec2.EC2Cloud
INFO: connect fresh as root
Feb 12, 2020 8:34:00 AM hudson.plugins.ec2.EC2Cloud
INFO: Connecting to 172.31.86.97 on port 22, with timeout 10000.
Feb 12, 2020 8:34:00 AM hudson.plugins.ec2.EC2Cloud
INFO: Connected via SSH.
Feb 12, 2020 8:34:00 AM hudson.plugins.ec2.EC2Cloud
INFO: Creating tmp directory (/tmp) if it does not exist
Feb 12, 2020 8:34:00 AM hudson.plugins.ec2.EC2Cloud
INFO: Verifying: java -fullversion
bash: java: command not found
Feb 12, 2020 8:34:00 AM hudson.plugins.ec2.EC2Cloud
INFO: Installing: sudo yum install -y java-1.8.0-openjdk.x86_64
Loaded plugins: extras_suggestions, langpacks, priorities, update-motd
Existing lock /var/run/yum.pid: another copy is running as pid 3381.
Another app is currently holding the yum lock; waiting for it to exit...
  The other application is: yum
    Memory :  34 M RSS (325 MB VSZ)
    Started: Wed Feb 12 08:33:58 2020 - 00:09 ago
    State  : Sleeping, pid: 3381
...
Another app is currently holding the yum lock; waiting for it to exit...
  The other application is: yum
    Memory :  34 M RSS (325 MB VSZ)
    Started: Wed Feb 12 08:33:58 2020 - 00:35 ago
    State  : Sleeping, pid: 3381

 One of the configured repositories failed (Unknown),
 and yum doesn't have enough cached data to continue. At this point the only
 safe thing yum can do is fail. There are a few ways to work "fix" this:

     1. Contact the upstream for the repository and get them to fix the problem.

     2. Reconfigure the baseurl/etc. for the repository, to point to a working
        upstream. This is most often useful if you are using a newer
        distribution release than is supported by the repository (and the
        packages for the previous distribution release still work).

     3. Run the command with the repository temporarily disabled
            yum --disablerepo=<repoid> ...

     4. Disable the repository permanently, so yum won't use it by default. Yum
        will then just ignore the repository until you permanently enable it
        again or use --enablerepo for temporary usage:

            yum-config-manager --disable <repoid>
        or
            subscription-manager repos --disable=<repoid>

     5. Configure the failing repository to be skipped, if it is unavailable.
        Note that yum will try to contact the repo. when it runs most commands,
        so will have to try and fail each time (and thus. yum will be be much
        slower). If it is a very temporary problem though, this is often a nice
        compromise:

            yum-config-manager --save --setopt=<repoid>.skip_if_unavailable=true

Cannot find a valid baseurl for repo: amzn2-core/2/x86_64
Could not retrieve mirrorlist http://amazonlinux.us-east-1.amazonaws.com/2/core/latest/x86_64/mirror.list error was
12: Timeout on http://amazonlinux.us-east-1.amazonaws.com/2/core/latest/x86_64/mirror.list: (28, 'Connection timed out after 5000 milliseconds')
Feb 12, 2020 8:35:10 AM hudson.plugins.ec2.EC2Cloud
WARNING: Failed to install: sudo yum install -y java-1.8.0-openjdk.x86_64
Feb 12, 2020 8:35:10 AM hudson.plugins.ec2.EC2Cloud
INFO: Verifying: which scp
/usr/bin/scp
Feb 12, 2020 8:35:10 AM hudson.plugins.ec2.EC2Cloud
INFO: Copying remoting.jar to: /tmp

Кажется, что мой подчиненный Дженкинс невозможно установить java с помощью yum? Это почему? Я отлично установил java на своем главном экземпляре Jenkins ... И ведущий, и ведомые устройства используют одну и ту же группу безопасности AWS с исходящим доступом куда угодно.

Переход на http://amazonlinux.us-east-1.amazonaws.com/2/core/latest/x86_64/mirror.list на Chrome работает просто Хорошо, загрузка начинается автоматически ... Любая подсказка, почему эта ошибка произошла!

Добро пожаловать на сайт PullRequest, где вы можете задавать вопросы и получать ответы от других членов сообщества.
...