Hi Eric,
I see log entries like the following.
Aug 13 21:00:00 <servername> pulp: celery.beat:INFO: Scheduler: Sending due task 55a37de54755ea07978d3bd0 (pulp.server.tasks.repository.sync_with_auto_publish)
Aug 13 21:00:00 <servername> pulp: celery.worker.strategy:INFO: Received task: pulp.server.tasks.repository.sync_with_auto_publish[944150bc-8caa-4047-afe8-c1335e5c5156]
Aug 13 21:00:00 <servername> pulp: celery.worker.strategy:INFO: Received task: pulp.server.tasks.repository.sync_with_auto_publish[48f425ca-0b09-48e8-8091-1ef7e2d0f7e3]
Aug 13 21:00:00 <servername> pulp: celery.beat:INFO: Scheduler: Sending due task 559e0a154755ea9c1a06584f (pulp.server.tasks.repository.sync_with_auto_publish)
Aug 13 21:00:00 <servername> pulp: celery.worker.strategy:INFO: Received task: pulp.server.async.tasks._queue_reserved_task[c0f6c700-f982-4bbd-acc2-e0df37ba5d7a]
Aug 13 21:00:00 <servername> pulp: celery.beat:INFO: Scheduler: Sending due task 559e0a1d4755ea9c1a0658da (pulp.server.tasks.repository.sync_with_auto_publish)
Aug 13 21:00:00 <servername> pulp: celery.worker.strategy:INFO: Received task: pulp.server.tasks.repository.sync_with_auto_publish[465ad5fc-e5a5-42ad-8ad0-20842c5d8863]
Aug 13 21:00:00 <servername> pulp: celery.beat:INFO: Scheduler: Sending due task 559e0a1d4755ea9c1a0658dd (pulp.server.tasks.repository.sync_with_auto_publish)
Aug 13 21:00:00 <servername> pulp: celery.worker.strategy:INFO: Received task: pulp.server.tasks.repository.sync_with_auto_publish[f569d4ee-8bd5-46a8-ba81-c06058912262]
Aug 13 21:00:00 <servername> pulp: celery.worker.job:INFO: Task pulp.server.tasks.repository.sync_with_auto_publish[48f425ca-0b09-48e8-8091-1ef7e2d0f7e3] succeeded in 0.0411540729983s: <AsyncResult: fd9fb6bf-1f20-4a5b-ba5f-6947d4ba78dd>
Aug 13 21:00:00 <servername> pulp: celery.worker.strategy:INFO: Received task: pulp.server.async.tasks._queue_reserved_task[0e62d425-04fb-4ed1-b6a0-e4897d67d9e5]
But when I´ve a peek into foreman, foreman tells me that the last repo sync is day ago. Furthermore when I run a repo sync manually a lot of new packages are added and erratas pop up that can be applied to hosts. During the “nightly” sync process this erratas are not sync. Thus I´d say that the sync process is not running correct.
···
Von: foreman-users@googlegroups.com [mailto:foreman-users@googlegroups.com] Im Auftrag von Eric D Helms Gesendet: Freitag, 14. August 2015 15:08 An: foreman-users@googlegroups.com Betreff: Re: [foreman-users] [Katello 2.2] Sync plans don't appear to work (anymore)If you look through /var/log/messages around the time you’d expect the syncs to have occurred do you see any Pulp activity?
On Fri, Aug 14, 2015 at 7:35 AM, <Markus.Moj@mc.ingenico.commailto:Markus.Moj@mc.ingenico.com> wrote:
Hi @all,
to me it looks ok. Here is an example output of foreman rake run.
{“next_run”=>“2015-08-14T19:00:00Z”, “remaining_runs”=>nil, “last_updated”=>1438246052.161148, “first_run”=>“2015-07-07T19:00:00Z”, “total_run_count”=>36, “schedule”=>“2015-07-30T18:45:00Z/PT24H”, “kwargs”=>{“overrides”=>{}}, “args”=>[“Red_Hat_Software_Collections__for_RHEL_Server_-Red_Hat_Software_Collections_Source_RPMs_for_Red_Hat_Enterprise_Linux_7_Server_x86_64_7Server”], “enabled”=>true, “last_run_at”=>“2015-08-13T19:00:01Z”, “task”=>“pulp.server.tasks.repository.sync_with_auto_publish”, “failure_threshold”=>nil, “resource”=>“pulp:importer:Red_Hat_Software_Collections__for_RHEL_Server_-Red_Hat_Software_Collections_Source_RPMs_for_Red_Hat_Enterprise_Linux_7_Server_x86_64_7Server:yum_importer”, “_id”=>“559e0aba4755ea9c1a0663fd”, “consecutive_failures”=>0, “href"=>"/pulp/api/v2/repositories/Red_Hat_Software_Collections__for_RHEL_Server-Red_Hat_Software_Collections_Source_RPMs_for_Red_Hat_Enterprise_Linux_7_Server_x86_64_7Server/importers/yum_importer/schedules/sync/559e0aba4755ea9c1a0663fd/”}
‘Red Hat Software Collections Source RPMs for Red Hat Enterprise Linux 7 Server x86_64 7Server’ in Product ‘Red Hat Software Collections for RHEL Server’ with product ID ‘8’ has 1 sync plans attached to them
But I´d to run the sync of alle repos manualy.
Von: foreman-users@googlegroups.commailto:foreman-users@googlegroups.com [mailto:foreman-users@googlegroups.commailto:foreman-users@googlegroups.com] Im Auftrag von Moj, Markus
Gesendet: Freitag, 14. August 2015 13:24
An: foreman-users@googlegroups.commailto:foreman-users@googlegroups.com
Betreff: AW: [foreman-users] [Katello 2.2] Sync plans don’t appear to work (anymore)
Hi JC,
no I didn´t run the rake code. But I´ll give it a try …
Von: foreman-users@googlegroups.commailto:foreman-users@googlegroups.com [mailto:foreman-users@googlegroups.com] Im Auftrag von Jamie Caldwell
Gesendet: Freitag, 14. August 2015 12:27
An: foreman-users@googlegroups.commailto:foreman-users@googlegroups.com
Betreff: Re: [foreman-users] [Katello 2.2] Sync plans don’t appear to work (anymore)
Have you run Eric’s rake code to check that the plan is really stored? It only confirmed that it was, but it is a first step…
On 14 August 2015 at 11:25, <Markus.Moj@mc.ingenico.commailto:Markus.Moj@mc.ingenico.com> wrote:
Hi JC,
thanks for your replay. I´ve to admit that this is a pity. I´ve created a new sync plan and applied it to all repos but things didn´t change. Well that´s something I need to get fixed before more employees start working with this fantastic tool
Von: foreman-users@googlegroups.commailto:foreman-users@googlegroups.com [mailto:foreman-users@googlegroups.commailto:foreman-users@googlegroups.com] Im Auftrag von Jamie Caldwell
Gesendet: Freitag, 14. August 2015 12:18
An: foreman-users@googlegroups.commailto:foreman-users@googlegroups.com
Betreff: Re: [foreman-users] [Katello 2.2] Sync plans don’t appear to work (anymore)
Marcus - I wish I had a better answer for you. It now works for me, but I have no idea why. It has been a problem for four weeks and I have not performed any updates. It just started working after a weekend. The only thing I have noticed is that when I create a new plan, the time defaults the actual time (which I would expect), where as before it would be one hour forward from the current time. Thus, my theory was that there was some sort of timezone mismatch.
On 14 August 2015 at 10:52, <Markus.Moj@mc.ingenico.commailto:Markus.Moj@mc.ingenico.com> wrote:
Hi @all,
I´m facing the same issue, is there any fix to enable scheduled repo syncs again?
-----Ursprüngliche Nachricht-----
Von: foreman-users@googlegroups.commailto:foreman-users@googlegroups.com [mailto:foreman-users@googlegroups.commailto:foreman-users@googlegroups.com] Im Auftrag von Jamie Caldwell
Gesendet: Mittwoch, 12. August 2015 09:35
An: foreman-users@googlegroups.commailto:foreman-users@googlegroups.com
Betreff: Re: [foreman-users] [Katello 2.2] Sync plans don’t appear to work (anymore)
Yup, it was. Thanks.
On 12 August 2015 at 00:57, Eric D Helms <ericdhelms@gmail.commailto:ericdhelms@gmail.com> wrote:
JC,
Was this the issue we were discussing in Redmine? I just wanted to
clarify on the list if this had been addressed or not.Eric
On Mon, Aug 3, 2015 at 3:46 AM, JC <mr.jamie.caldwell@gmail.commailto:mr.jamie.caldwell@gmail.com> wrote:
I don’t suppose anyone has any further thoughts on this? I’m getting
close to delivering the Katello server into live service and really
need to iron out the last few issues… Thanks.On Friday, 31 July 2015 12:37:32 UTC+1, JC wrote:
A couple of screen grabs…
On Friday, 31 July 2015 12:32:44 UTC+1, JC wrote:
Thanks. Bingo.
foreman-rake list_active_sync_schedules ‘EPEL’ in Product
‘CentOS5’ with product ID ‘3’ has 1 sync plans attached to them
‘KatelloAgent’ in Product ‘CentOS5’ with product ID ‘3’ has 1 sync
plans attached to them ‘OS’ in Product ‘CentOS5’ with product ID
‘3’ has 1 sync plans attached to them ‘SubscriptionAgent’ in
Product ‘CentOS5’ with product ID ‘3’ has 1 sync plans attached to
them ‘Updates’ in Product ‘CentOS5’ with product ID ‘3’ has 1 sync
plans attached to themThis tallys with my action. I created a plan and assigned it to
the
CentOS5 product.On 31 July 2015 at 12:24, Eric D Helms <ericdhelms@gmail.commailto:ericdhelms@gmail.com> wrote:
Try adding the code in the rake tasks directly to
/use/share/foreman/RakefileOn Jul 31, 2015 4:58 AM, “JC” <mr.jamie.caldwell@gmail.commailto:mr.jamie.caldwell@gmail.com> wrote:
Eric/All - I’ve since rebuilt, but still have the same problem.
Worse, I can’t even get you script to run. Can you help?cd /var/log
grep -Ri Daily8am *
foreman/production.log:2015-07-31 07:44:35 [I] Parameters:
{“interval”=>“hourly”, “startDate”=>“2015-07-31T06:44:22.013Z”,
“name”=>“Daily8am”, “startTime”=>“2015-07-31T07:00:22.128Z”,
“sync_date”=>“Fri Jul 31 2015 08:00:00 GMT+0100 (GMT Daylight
Time)”, “api_version”=>“v2”, “organization_id”=>“1”,
“sync_plan”=>{“name”=>“Daily8am”, “sync_date”=>“Fri Jul 31 2015
08:00:00
GMT+0100 (GMT Daylight Time)”, “interval”=>“hourly”}}
foreman/production.log:2015-07-31 07:45:37 [I] Parameters:
{“id”=>“2”, “organization_id”=>“1”, “name”=>“Daily8am”,
“description”=>nil, “sync_date”=>“2015-07-31T07:00:00Z”,
“interval”=>“daily”, “next_sync”=>“2015-07-31T07:00:00Z”,
“created_at”=>“2015-07-31T06:44:35Z”,
“updated_at”=>“2015-07-31T06:44:35Z”, “enabled”=>true,
“products”=>[{“id”=>3, “cp_id”=>“1438165438810”,
“name”=>“CentOS5”, “label”=>“CentOS5”, “description”=>nil,
“sync_state”=>“finished”,
“last_sync”=>“2015-07-30 07:35:26 UTC”, “last_sync_words”=>“about
23 hours”, “repository_count”=>5}],
“permissions”=>{“view_sync_plans”=>true,
“edit_sync_plans”=>true, “destroy_sync_plans”=>true},
“api_version”=>“v2”, “sync_plan”=>{“id”=>“2”, “name”=>“Daily8am”,
“description”=>nil, “sync_date”=>“2015-07-31T07:00:00Z”,
“interval”=>“daily”, “organization_id”=>“1”,
“created_at”=>“2015-07-31T06:44:35Z”,
“updated_at”=>“2015-07-31T06:44:35Z”, “enabled”=>true}}ll
total 52
-rw-r–r–. 1 root root 3970 Jun 15 13:20 core_extensions.rb
drwxr-xr-x. 3 root root 4096 Jul 28 15:25 foreman -rw-r–r–. 1
root root 639 Jun 15 13:20 foreman.rb drwxr-xr-x. 2 root root
4096 Jul 28 15:25 middleware drwxr-xr-x. 4 root root 4096 Jul 28
15:25 net -rw-r–r–. 1 root root 875 Jun 15 13:20 net.rb
drwxr-xr-x. 2 root root 4096 Jul 28 15:25 proxy_api
-rw-r–r–. 1 root root 72 Jun 15 13:20 proxy_api.rb
-rw-r–r–. 1 root root 427 Jun 15 13:20 regexp_extensions.rb
-rwxr-xr-x. 1 root root 982 Jul 31 09:54
sync_schedule_tasks.rake drwxr-xr-x. 2 root root 4096 Jul 28
15:25 tasks -rw-r–r–. 1 root root 1211 Jun 15 13:20
timed_cached_store.rb -rw-r–r–. 1 root root 2098 Jun 15 13:20
ws_proxy.rb # grep list_active_sync_schedules
sync_schedule_tasks.rake task :list_active_sync_schedules =>
:environment do # foreman-rake list_active_sync_schedules --trace
rake aborted!
Don’t know how to build task ‘list_active_sync_schedules’
/opt/rh/ruby193/root/usr/share/ruby/rake/task_manager.rb:49:in[]' /opt/rh/ruby193/root/usr/share/ruby/rake/application.rb:115:in
invoke_task’
/opt/rh/ruby193/root/usr/share/ruby/rake/application.rb:94:in
block (2 levels) in top_level' /opt/rh/ruby193/root/usr/share/ruby/rake/application.rb:94:in
each’
/opt/rh/ruby193/root/usr/share/ruby/rake/application.rb:94:in
block in top_level' /opt/rh/ruby193/root/usr/share/ruby/rake/application.rb:133:in
standard_exception_handling’
/opt/rh/ruby193/root/usr/share/ruby/rake/application.rb:88:in
top_level' /opt/rh/ruby193/root/usr/share/ruby/rake/application.rb:66:in
block in run’