Whan applying errata I get error: Host did not respond within 20 seconds. The task has been cancelled. Is katello-agent installed and goferd running on the Host?

Problem:
Host did not respond within 20 seconds. The task has been cancelled. Is katello-agent installed and goferd running on the Host?

Distribution and version:
server.mycompany.com Templates, Pulp, TFTP, Puppet, Puppet CA, and Logs 1.20.3

bastion Bastion provides a UI library of AngularJS based components designed to integrate and work with Foreman. Eric D Helms and Walden Raines 6.1.16
foreman-tasks The goal of this plugin is to unify the way of showing task statuses across the Foreman instance. It defines Task model for keeping the information about the tasks and Lock for assigning the tasks to resources. The locking allows dealing with preventing multiple colliding tasks to be run on the same resource. It also optionally provides Dynflow infrastructure for using it for managing the tasks. Ivan Nečas 0.14.3
foreman_docker Provision and manage Docker containers and images from Foreman. Daniel Lobato, Amos Benari 4.1.0
katello Content and Subscription Management plugin for Foreman N/A 3.10.1.1

Did you check that katello-agent is installed and goferd is running on the host? Is there connectivity from the foreman server to the host?
Also keep in mind that 1.20/3.10 are a bit old and unsupported, if this is a bug it may have been fixed in newer releases.

Might be worth noting that the katello-agent/goferd setup is deprecated and will be removed soon from future Katello releases.
You will probably want to migrate your workflows to a remote-execution based setup and the clients to use katello-host-tools.
The Community Templates provides some remote execution job templates to get you started.

Regards

Thank you areyus and tbrisker,

I am going to take tbrisker’s advice and try to upgrade. The only issuer is that all the methods fail. I can’t even get anything higher than 1.2… Please help. I’m by no means a foreman expert. If you need more info, please let me know. I tried the following:
3.6 Upgrade
Upgrading to Foreman 1.3
Preparation

Before updating to 1.3, make sure you have successfully upgraded to 1.2 first.

Upgrading across more than one version is not supported, so it’s required to upgrade to each intermediate version and follow all upgrade instructions for the previous versions.

Please check the upgrade notes for this release, as there may be things to be aware of or additional steps:

Step 1 - Backup

It is recommended that you backup your database and modifications to Foreman files(config/settings.yaml, unattended installations etc). Most upgrades are safe but it never hurts to have a backup just in case.

For more information about how to backup your instance head over to Backuphttps://theforeman.org/manuals/1.3/index.html#5.5.1Backup

Step 2 - Perform the upgrade

Before proceeding, it is necessary to shutdown the Foreman instance.

Now it’s time to perform the actual upgrade. This process if different depending on how you downloaded Foreman. You only need to perform one of the following options.

Option 1 - Upgrading from a package on Fedora or RHEL
Upgrading from 1.2

Important note: Foreign keys on the SQL database level were introduced in the Foreman 1.3. During migration, all orphaned records are deleted automatically. It is strongly recommended to backup database prior proceeding with upgrade.

To upgrade an existing Foreman 1.2 installation, first update with the appropriate foreman-release package from the above list of release packages, e.g. for RHEL6

yum upgrade http://yum.theforeman.org/releases/1.3/el6/x86_64/foreman-release.rpm

cat /etc/yum.repos.d/foreman.repo.rpmnew > /etc/yum.repos.d/foreman.repo

Next upgrade all Foreman packages:

yum upgrade ruby* foreman*

If you wish to install the SELinux policy, also install the foreman-selinux package.

If Foreman doesn’t load due to a Passenger error (particularly referencing bundler_ext), verify the configuration against the description in the Software Collections sectionhttps://theforeman.org/manuals/1.3/index.html#3.3.2SoftwareCollections below.

You can skip to Step 3.

Option 2 - Upgrading from a package on Debian or Ubuntu
Upgrading from 1.2

Upgrading from 1.2 to 1.3 has been tested on both Debian and Ubuntu. Updating the packages will upgrade the application and automatically migrate the database.

apt-get update

apt-get dist-upgrade

You can skip to Step 3.

Option 3 - Downloaded release (tar.bz2)

  • Uncompress the new program archive in a new directory.
  • Copy your database settings-file config/database.yml into the new config directory.
  • If your database is a simple file (e.g. SQLite), don’t forget to make it available in the new directory.

VERY IMPORTANT: do NOT overwrite config/settings.yml with the old one.

Option 4 - Upgrading from git

Please note now that the development branch has moved to Rails 3, you MUST take care to select a branch and make sure you get the correct one.

  1. Go to the Foreman root directory and run the following command:

For staying on the stable branch:

  • git checkout 1.3-stable
  • git pull

The following step is the one that could change the contents of your database. Go to your new Foreman directory (or the git dir), then migrate your database:

foreman-rake db:migrate

You should compile i18n strings and precompile assets now:

foreman-rake locale:pack

foreman-rake assets:precompile

Step 3 - Cleanup

Database should be migrated already, but you can make sure by executing the migration script again, it should produce no errors or output:

foreman-rake db:migrate

You should clear the cache and the existing sessions:

foreman-rake tmp:cache:clear

foreman-rake tmp:sessions:clear

Step 4 - Restart

Restart the application server (e.g. mongrel, thin, passenger)

Common issues

Thank you,
Mark S. Stone
Sr. Systems Engineer
IT Infrastructure Engineering
O 484.595.6310 M 267.768.0980
Mark.Stone@vertexinc.commailto:Mark.Stone@vertexinc.com
Vertex Inc.
2301 Renaissance Blvd.,
King of Prussia, PA 19406
www.vertexinc.comhttp://www.vertexinc.com/

[/uploads/default/original/2X/4/4e726411070b987f40762a5ec8b6b31e16768645.png]
LinkedInhttps://www.linkedin.com/company/vertex-inc./ | Facebookhttps://www.facebook.com/vertexinc1/ | Twitterhttps://twitter.com/vertexinc| Instagramhttps://www.instagram.com/lifeatvertex/?hl=en

Those look like the upgrade instructions for Foreman 1.3.
What you want to be following are the upgrade instructions for Katello - start with 3.11 and continue one release at a time

Thank you tbrisker,

My issue at this point is when I run upgrade-check, It complains about a running task, but I can’t stop them from the monitor>tasks window. Is there a cli way to do this.
[/uploads/default/original/2X/f/f4be876f0b17a983bc8bd822637afd56c1e6b52e.png]

Thanks so much in advance!

Thank you,
Mark S. Stone
Sr. Systems Engineer
IT Infrastructure Engineering
O 484.595.6310 M 267.768.0980
Mark.Stone@vertexinc.commailto:Mark.Stone@vertexinc.com
Vertex Inc.
2301 Renaissance Blvd.,
King of Prussia, PA 19406
www.vertexinc.comhttp://www.vertexinc.com/

[/uploads/default/original/2X/4/4e726411070b987f40762a5ec8b6b31e16768645.png]
LinkedInhttps://www.linkedin.com/company/vertex-inc./ | Facebookhttps://www.facebook.com/vertexinc1/ | Twitterhttps://twitter.com/vertexinc| Instagramhttps://www.instagram.com/lifeatvertex/?hl=en

The task Plugin offers a way to clean stuck tasks (https://github.com/theforeman/foreman-tasks#tasks-cleanup).

In essence, you want to do something like this:
foreman-rake foreman_tasks:cleanup TASK_SEARCH='id = <taskid>' for each of the stuck tasks. You can get the task id from the UI (on the details page of the task, switch to the “Raw” tab, there you can find the id).

Thanks areyus!

That worked and I’m starting the upgrade now. I ran into another snag. The yum update -y foreman-release-scl is not finding the foreman-release-scl. All repo’s seem to be there and enabled.

Sorry to be a pain.

Thank you,
Mark S. Stone
Sr. Systems Engineer
IT Infrastructure Engineering
O 484.595.6310 M 267.768.0980
Mark.Stone@vertexinc.commailto:Mark.Stone@vertexinc.com
Vertex Inc.
2301 Renaissance Blvd.,
King of Prussia, PA 19406
www.vertexinc.comhttp://www.vertexinc.com/

[/uploads/default/original/2X/4/4e726411070b987f40762a5ec8b6b31e16768645.png]
LinkedInhttps://www.linkedin.com/company/vertex-inc./ | Facebookhttps://www.facebook.com/vertexinc1/ | Twitterhttps://twitter.com/vertexinc| Instagramhttps://www.instagram.com/lifeatvertex/?hl=en

Hm I just looked it up in the repo and it seems to be there.
Please doublecheck your yum config files and/or try a yum reinstall foreman-release. A yum repolist -v might also have some usefull information. You should have several foreman--1.21 and katello- repos there. I don’t have the full list at hand right now, though.

If the repo itself seems to work and you just can not find the package there, you can just install it manually via yum install https://yum.theforeman.org/releases/1.21/el7/x86_64/foreman-release-scl-7-2.el7.noarch.rpm

Regards

Thanks again areyus,

That did it. I completed the install successfully. I am still unable to register a centos 7 server, but I was able to add the repo for centos7 and install from it. The problem is that when I go to the forman gui, It tells me that the server is not registered. I used the following syntax to register it :
subscription-manager register --org=“Vertex” --activationkey=“centos7”
I don’t get errors, but foreman thinks it’s not registered:
[/uploads/default/original/2X/1/11226ed19a5080f1281ade4d14dbea8293a75ca8.jpeg]
Can’t figure out what I’m doing wrong. Any ideas would be wonderful.

Thank you,
Mark S. Stone
Sr. Systems Engineer
IT Infrastructure Engineering
O 484.595.6310 M 267.768.0980
Mark.Stone@vertexinc.commailto:Mark.Stone@vertexinc.com
Vertex Inc.
2301 Renaissance Blvd.,
King of Prussia, PA 19406
www.vertexinc.comhttp://www.vertexinc.com/

[/uploads/default/original/2X/4/4e726411070b987f40762a5ec8b6b31e16768645.png]
LinkedInhttps://www.linkedin.com/company/vertex-inc./ | Facebookhttps://www.facebook.com/vertexinc1/ | Twitterhttps://twitter.com/vertexinc| Instagramhttps://www.instagram.com/lifeatvertex/?hl=en

Interesting situation, I have not seen that yet.
The subscription-manager command should be alright. Can you check if it created another content host (maybe with a different name or something like that)? Go to Hosts -> Content Hosts and check for unexpected systems.
If the system registers with a wrong name, I would asume it’s hostname is somehow set to something different than the name of the primary interface within Foreman.
You could check for something like this with subscription-manager identity. If so (and the hostname differs for a reason), you could try setting the name explicitly during the kickstart/registration progress by adding the --name=<Foreman expected FQDN> to the subscription-manager register command.
Also, raising the debug level for the registration process might give you some insight on what is happening.

Aryus,

The system was created, but when I click it I get the
Content Hosts:
[/uploads/default/original/2X/1/127d158db4ea46800b9d9aafc14777dedec233a2.jpeg]
When I click on the server I get the following:
[A screenshot of a cell phone Description automatically generated]
Can’t figure it out.

Thank you,
Mark S. Stone
Sr. Systems Engineer
IT Infrastructure Engineering
O 484.595.6310 M 267.768.0980
Mark.Stone@vertexinc.commailto:Mark.Stone@vertexinc.com
Vertex Inc.
2301 Renaissance Blvd.,
King of Prussia, PA 19406
www.vertexinc.comhttp://www.vertexinc.com/

[/uploads/default/original/2X/4/4e726411070b987f40762a5ec8b6b31e16768645.png]
LinkedInhttps://www.linkedin.com/company/vertex-inc./ | Facebookhttps://www.facebook.com/vertexinc1/ | Twitterhttps://twitter.com/vertexinc| Instagramhttps://www.instagram.com/lifeatvertex/?hl=en

image007.jpg

Hm, I’m running out of ideas. Could you provide the messages from /var/log/foreman/production.log while trying to register the system?
You can mask any sensitive Information in there like IP Adresses and Hostnames (e.g. by replacing with host.example.com and foreman.example.com), but please don’t remove things completely from the log.

Aryus,

I’m up and running. Your pointer to the logs did the trick.

Mark

Oh yeah,
Sorry about the lag.

Mark

Hi,

glad to hear you managed to solve the problem.
Would you be so kind and share what the solution was, so others might benefit from it in the future?
Also, please mark the thread as solved :slight_smile: You can mark a post as solution using the checkbox icon on the post that describes the solution.

Regards

Hi, I reapplied the katello agent and restarted everything and it worked.