I've hit a problem with a clean foreman 1.15 install. I've used the same 
installer settings as a working 1.13 and 1.14 box as this is just a test 
system. 


The system is a current patched CentOS 7.3 host, 


The installer options for the DHCP config are as follows.


--foreman-proxy-dhcp-interface=enp2s0 \

--foreman-proxy-dns-interface=enp2s0 \

--foreman-proxy-dns="true" \

--foreman-proxy-dns-reverse="216.11.10.in-addr.arpa" \

--foreman-proxy-dns-server="10.11.216.8" \

--foreman-proxy-dhcp-gateway="10.11.216.1" \

--foreman-proxy-dhcp-range="10.11.216.30 10.11.216.254" \

--foreman-proxy-dhcp-key-name=jarvis_omapi.key \

--foreman-proxy-dhcp-key-secret="keydata" \

--foreman-proxy-dhcp=true \

--foreman-proxy-dhcp-nameservers=10.11.216.1


This creates a valid dhcpd.conf configuration file, it matches it perfectly 
and I can successfully import this into foreman.


I can successfully add hosts to foreman and it builds them, excellent, no 
problems.


IP management is set to dhcp


Certain host I am unable to add to foreman.


The first problem is caused when foreman tries to suggest an IP address for 
a host, sometimes it suggests an IP address that is already allocated to a 
host. 


the example situation I have at the moment is that foreman is suggesting 
10.11.216.44


However, 10.11.216.44 already has an entry in the lease file


lease 10.11.216.44 {

  starts 0 2017/05/14 14:42:31;

  ends 1 2017/05/15 02:42:31;

  tstp 1 2017/05/15 02:42:31;

  cltt 0 2017/05/14 14:42:31;

  binding state active;

  next binding state free;

  rewind binding state free;


  hardware ethernet 40:8d:5c:56:58:86;




The odd thing is this is for the host I'm trying to add is this mac address 
40:8d:5c:56:58:86 
so it's the same.


I have however (not at this time an example) had problems with this install 
where it allocates an IP address of an existing host NOT the one I'm trying 
to add.


This would however be no problem as I would normally click "suggest new ip" 
and get a new IP, however, it appears to attempt to action this but returns 
with the same IP. (I assume because there is an entry in the lease file for 
this it's got no choice but to return this iP ?)


I see it trying in the proxy log foreman trying to request a new IP, so I 
know it is actually trying.



I, [2017-05-14T16:33:36.345557 ]  INFO -- : 10.11.216.4 - - 
[14/May/2017:16:33:36 +0100] "GET 
/dhcp/10.11.216.0/unused_ip?mac=40:8d:5c:56:58:86&from=10.11.216.30&to=10.11.216.250
 
HTTP/1.1" 200 21 0.0018


The parts I'm not sure around this are 


a.) why is foreman getting IP from the dhcp server that already have hosts 
allocated to them ?

b.) is the suggest new button expected to return the same address only if 
the host already has a lease/ip assigned to it, or should it get a new one 
and update the lease on commit of the host ?


If I try to continue with adding the host in question, the creation of the 
host in foreman fails with the error


Create DHCP Settings for riker.no-dns.co.uk task failed with the following 
error: ERF12-6899 [ProxyAPI::ProxyException]: Unable to set DHCP entry 
([RestClient::Conflict]: 409 Conflict) for proxy 
https://jarvis.no-dns.co.uk:8443/dhcp



which makes sense - as there is already an entry there, but normally this 
offers an option to override, in this case it doesn't


The production log for adding this host shows the conflict and exception 


2017-05-14 16:54:44 ad4bcde6 [app] [I] Started POST 
"/hosts/medium_selected" for 10.11.216.43 at 2017-05-14 16:54:44 +0100

2017-05-14 16:54:44 ad4bcde6 [app] [I] Processing by 
HostsController#medium_selected as */*

2017-05-14 16:54:44 ad4bcde6 [app] [I]   Parameters: 
{"host"=>{"medium_id"=>"1", "operatingsystem_id"=>"1", 
"architecture_id"=>"1", "use_image"=>"false"}}

2017-05-14 16:54:44 ad4bcde6 [app] [I] Current user: admin (administrator)

2017-05-14 16:54:44 ad4bcde6 [app] [I]   Rendered 
common/os_selection/_image_details.html.erb (4.6ms)

2017-05-14 16:54:44 ad4bcde6 [app] [I] Completed 200 OK in 22ms (Views: 
7.3ms | ActiveRecord: 0.5ms)

2017-05-14 16:54:46 01276ad6 [app] [I] Started GET 
"/notification_recipients" for 10.11.216.43 at 2017-05-14 16:54:46 +0100

2017-05-14 16:54:46 01276ad6 [app] [I] Processing by 
NotificationRecipientsController#index as JSON

2017-05-14 16:54:46 01276ad6 [app] [I] Current user: admin (administrator)

2017-05-14 16:54:46 01276ad6 [app] [I] Completed 200 OK in 5ms (Views: 
0.2ms | ActiveRecord: 0.5ms)

2017-05-14 16:55:26 4335f5d9 [app] [I] Started POST "/hosts" for 
10.11.216.43 at 2017-05-14 16:55:26 +0100

2017-05-14 16:55:26 4335f5d9 [app] [I] Processing by HostsController#create 
as */*

2017-05-14 16:55:26 4335f5d9 [app] [I]   Parameters: {"utf8"=>"✓", 
"authenticity_token"=>"ggjQWxy8Umjc5Oxj+Mx7gw0NshrUhI6AE0iKBHFbSOtjXDGDtdJZaISRnk+7GJ6VZZ/X7cIFizk8eLCAW6kcbQ==",
 
"host"=>{"name"=>"riker", "hostgroup_id"=>"1", "compute_resource_id"=>"", 
"ansible_role_ids"=>[""], "puppetclass_ids"=>[""], "managed"=>"true", 
"progress_report_id"=>"[FILTERED]", "type"=>"Host::Managed", 
"interfaces_attributes"=>{"0"=>{"_destroy"=>"0", "type"=>"Nic::Managed", 
"mac"=>"40:8d:5c:56:58:86", "identifier"=>"enp0s31f6", "name"=>"riker", 
"domain_id"=>"1", "subnet_id"=>"1", "ip"=>"10.11.216.44", "ip6"=>"", 
"managed"=>"1", "primary"=>"1", "provision"=>"1", "execution"=>"1", 
"virtual"=>"0", "tag"=>"", "attached_to"=>""}}, "architecture_id"=>"1", 
"operatingsystem_id"=>"1", "provision_method"=>"build", "build"=>"1", 
"medium_id"=>"1", "ptable_id"=>"101", "pxe_loader"=>"PXELinux BIOS", 
"disk"=>"", "root_pass"=>"[FILTERED]", "is_owned_by"=>"3-Users", 
"enabled"=>"1", "model_id"=>"", "comment"=>"", "overwrite"=>"false"}, 
"bare_metal_capabilities"=>"build"}

2017-05-14 16:55:26 4335f5d9 [app] [I] Current user: admin (administrator)

2017-05-14 16:55:26 4335f5d9 [app] [I] Create DHCP reservation 
riker.no-dns.co.uk for riker.no-dns.co.uk-40:8d:5c:56:58:86/10.11.216.44

2017-05-14 16:55:27 4335f5d9 [app] [W] Create DHCP Settings for 
riker.no-dns.co.uk task failed with the following error: ERF12-6899 
[ProxyAPI::ProxyException]: Unable to set DHCP entry 
([RestClient::Conflict]: 409 Conflict) for proxy 
https://jarvis.no-dns.co.uk:8443/dhcp

 | ProxyAPI::ProxyException: ERF12-6899 [ProxyAPI::ProxyException]: Unable 
to set DHCP entry ([RestClient::Conflict]: 409 Conflict) for proxy 
https://jarvis.no-dns.co.uk:8443/dhcp

 | /usr/share/foreman/lib/proxy_api/dhcp.rb:86:in `rescue in set'

 | /usr/share/foreman/lib/proxy_api/dhcp.rb:82:in `set'

 | /usr/share/foreman/lib/net/dhcp/record.rb:30:in `create'

 | /usr/share/foreman/app/models/concerns/orchestration/dhcp.rb:57:in 
`block in set_dhcp'

 | /usr/share/foreman/app/models/concerns/orchestration/dhcp.rb:57:in `each'

 | /usr/share/foreman/app/models/concerns/orchestration/dhcp.rb:57:in `all?'

 | /usr/share/foreman/app/models/concerns/orchestration/dhcp.rb:57:in 
`set_dhcp'

 | /usr/share/foreman/app/models/concerns/orchestration.rb:216:in `execute'

 | /usr/share/foreman/app/models/concerns/orchestration.rb:144:in `block in 
process'

 | /usr/share/foreman/app/models/concerns/orchestration.rb:136:in `each'

 | /usr/share/foreman/app/models/concerns/orchestration.rb:136:in `process'

 | /usr/share/foreman/app/models/concerns/orchestration.rb:44:in 
`around_save_orchestration'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:432:in
 
`block in make_lambda'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:312:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:312:in
 
`block in halting'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:497:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:497:in
 
`block in around'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:505:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:505:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:92:in
 
`__run_callbacks__'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:778:in
 
`_run_save_callbacks'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activerecord-4.2.5.1/lib/active_record/callbacks.rb:302:in
 
`create_or_update'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activerecord-4.2.5.1/lib/active_record/persistence.rb:120:in
 
`save'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activerecord-4.2.5.1/lib/active_record/validations.rb:37:in
 
`save'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activerecord-4.2.5.1/lib/active_record/attribute_methods/dirty.rb:21:in
 
`save'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activerecord-4.2.5.1/lib/active_record/transactions.rb:286:in
 
`block (2 levels) in save'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activerecord-4.2.5.1/lib/active_record/transactions.rb:351:in
 
`block in with_transaction_returning_status'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activerecord-4.2.5.1/lib/active_record/connection_adapters/abstract/database_statements.rb:213:in
 
`block in transaction'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activerecord-4.2.5.1/lib/active_record/connection_adapters/abstract/transaction.rb:184:in
 
`within_new_transaction'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activerecord-4.2.5.1/lib/active_record/connection_adapters/abstract/database_statements.rb:213:in
 
`transaction'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activerecord-4.2.5.1/lib/active_record/transactions.rb:220:in
 
`transaction'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activerecord-4.2.5.1/lib/active_record/transactions.rb:348:in
 
`with_transaction_returning_status'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activerecord-4.2.5.1/lib/active_record/transactions.rb:286:in
 
`block in save'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activerecord-4.2.5.1/lib/active_record/transactions.rb:301:in
 
`rollback_active_record_state!'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activerecord-4.2.5.1/lib/active_record/transactions.rb:285:in
 
`save'

 | /usr/share/foreman/app/models/concerns/foreman/sti.rb:29:in 
`save_with_type'

 | /usr/share/foreman/app/controllers/hosts_controller.rb:104:in `create'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_controller/metal/implicit_render.rb:4:in
 
`send_action'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/abstract_controller/base.rb:198:in
 
`process_action'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_controller/metal/rendering.rb:10:in
 
`process_action'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/abstract_controller/callbacks.rb:20:in
 
`block in process_action'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:117:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:117:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:555:in
 
`block (2 levels) in compile'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:505:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:505:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:498:in
 
`block (2 levels) in around'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:313:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:313:in
 
`block (2 levels) in halting'

 | /usr/share/foreman/app/controllers/concerns/application_shared.rb:15:in 
`set_timezone'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:432:in
 
`block in make_lambda'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:312:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:312:in
 
`block in halting'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:497:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:497:in
 
`block in around'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:505:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:505:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:498:in
 
`block (2 levels) in around'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:313:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:313:in
 
`block (2 levels) in halting'

 | /usr/share/foreman/app/models/concerns/foreman/thread_session.rb:32:in 
`clear_thread'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:432:in
 
`block in make_lambda'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:312:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:312:in
 
`block in halting'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:497:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:497:in
 
`block in around'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:505:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:505:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:498:in
 
`block (2 levels) in around'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:313:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:313:in
 
`block (2 levels) in halting'

 | 
/usr/share/foreman/app/controllers/concerns/foreman/controller/topbar_sweeper.rb:12:in
 
`set_topbar_sweeper_controller'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:432:in
 
`block in make_lambda'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:312:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:312:in
 
`block in halting'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:497:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:497:in
 
`block in around'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:505:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:505:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:498:in
 
`block (2 levels) in around'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:313:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:313:in
 
`block (2 levels) in halting'

 | 
/opt/theforeman/tfm/root/usr/share/gems/gems/audited-4.4.1/lib/audited/sweeper.rb:14:in
 
`around'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:455:in
 
`public_send'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:455:in
 
`block in make_lambda'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:312:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:312:in
 
`block in halting'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:497:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:497:in
 
`block in around'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:505:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:505:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:92:in
 
`__run_callbacks__'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:778:in
 
`_run_process_action_callbacks'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:81:in
 
`run_callbacks'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/abstract_controller/callbacks.rb:19:in
 
`process_action'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_controller/metal/rescue.rb:29:in
 
`process_action'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_controller/metal/instrumentation.rb:32:in
 
`block in process_action'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/notifications.rb:164:in
 
`block in instrument'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/notifications/instrumenter.rb:20:in
 
`instrument'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/notifications.rb:164:in
 
`instrument'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_controller/metal/instrumentation.rb:30:in
 
`process_action'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_controller/metal/params_wrapper.rb:250:in
 
`process_action'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activerecord-4.2.5.1/lib/active_record/railties/controller_runtime.rb:18:in
 
`process_action'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/abstract_controller/base.rb:137:in
 
`process'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionview-4.2.5.1/lib/action_view/rendering.rb:30:in
 
`process'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_controller/metal.rb:196:in
 
`dispatch'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_controller/metal/rack_delegation.rb:13:in
 
`dispatch'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_controller/metal.rb:237:in
 
`block in action'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_dispatch/routing/route_set.rb:74:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_dispatch/routing/route_set.rb:74:in
 
`dispatch'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_dispatch/routing/route_set.rb:43:in
 
`serve'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_dispatch/journey/router.rb:43:in
 
`block in serve'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_dispatch/journey/router.rb:30:in
 
`each'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_dispatch/journey/router.rb:30:in
 
`serve'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_dispatch/routing/route_set.rb:815:in
 
`call'

 | 
/opt/theforeman/tfm/root/usr/share/gems/gems/apipie-rails-0.4.0/lib/apipie/static_dispatcher.rb:65:in
 
`call'

 | 
/opt/theforeman/tfm/root/usr/share/gems/gems/apipie-rails-0.4.0/lib/apipie/extractor/recorder.rb:132:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_dispatch/middleware/static.rb:116:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_dispatch/middleware/static.rb:116:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_dispatch/middleware/static.rb:116:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_dispatch/middleware/static.rb:116:in
 
`call'

 | 
/opt/theforeman/tfm/root/usr/share/gems/gems/apipie-rails-0.4.0/lib/apipie/middleware/checksum_in_headers.rb:27:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/rack-1.6.2/lib/rack/etag.rb:24:in 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/rack-1.6.2/lib/rack/conditionalget.rb:38:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/rack-1.6.2/lib/rack/head.rb:13:in 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_dispatch/middleware/params_parser.rb:27:in
 
`call'

 | /usr/share/foreman/lib/middleware/catch_json_parse_errors.rb:8:in `call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_dispatch/middleware/flash.rb:260:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/rack-1.6.2/lib/rack/session/abstract/id.rb:225:in
 
`context'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/rack-1.6.2/lib/rack/session/abstract/id.rb:220:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_dispatch/middleware/cookies.rb:560:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activerecord-4.2.5.1/lib/active_record/query_cache.rb:36:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activerecord-4.2.5.1/lib/active_record/connection_adapters/abstract/connection_pool.rb:653:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_dispatch/middleware/callbacks.rb:29:in
 
`block in call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:88:in
 
`__run_callbacks__'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:778:in
 
`_run_call_callbacks'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:81:in
 
`run_callbacks'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_dispatch/middleware/callbacks.rb:27:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_dispatch/middleware/remote_ip.rb:78:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_dispatch/middleware/debug_exceptions.rb:17:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_dispatch/middleware/show_exceptions.rb:30:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/railties-4.2.5.1/lib/rails/rack/logger.rb:38:in
 
`call_app'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/railties-4.2.5.1/lib/rails/rack/logger.rb:22:in
 
`call'

 | /usr/share/foreman/lib/middleware/tagged_logging.rb:18:in `call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_dispatch/middleware/request_id.rb:21:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/rack-1.6.2/lib/rack/methodoverride.rb:22:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/rack-1.6.2/lib/rack/runtime.rb:18:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/cache/strategy/local_cache_middleware.rb:28:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_dispatch/middleware/static.rb:116:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/rack-1.6.2/lib/rack/sendfile.rb:113:in
 
`call'

 | 
/opt/theforeman/tfm/root/usr/share/gems/gems/secure_headers-3.4.1/lib/secure_headers/middleware.rb:12:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/railties-4.2.5.1/lib/rails/engine.rb:518:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/railties-4.2.5.1/lib/rails/application.rb:165:in
 
`call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/railties-4.2.5.1/lib/rails/railtie.rb:194:in
 
`public_send'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/railties-4.2.5.1/lib/rails/railtie.rb:194:in
 
`method_missing'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/rack-1.6.2/lib/rack/urlmap.rb:66:in 
`block in call'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/rack-1.6.2/lib/rack/urlmap.rb:50:in 
`each'

 | 
/opt/rh/sclo-ror42/root/usr/share/gems/gems/rack-1.6.2/lib/rack/urlmap.rb:50:in 
`call'

 | 
/usr/share/passenger/phusion_passenger/rack/thread_handler_extension.rb:74:in 
`process_request'

 | 
/usr/share/passenger/phusion_passenger/request_handler/thread_handler.rb:141:in 
`accept_and_process_next_request'

 | 
/usr/share/passenger/phusion_passenger/request_handler/thread_handler.rb:109:in 
`main_loop'

 | /usr/share/passenger/phusion_passenger/request_handler.rb:455:in `block 
(3 levels) in start_threads'

 | 
/opt/theforeman/tfm/root/usr/share/gems/gems/logging-1.8.2/lib/logging/diagnostic_context.rb:323:in
 
`call'

 | 
/opt/theforeman/tfm/root/usr/share/gems/gems/logging-1.8.2/lib/logging/diagnostic_context.rb:323:in
 
`block in create_with_logging_context'

2017-05-14 16:55:27 4335f5d9 [app] [I] Failed to save: Create DHCP Settings 
for riker.no-dns.co.uk task failed with the following error: ERF12-6899 
[ProxyAPI::ProxyException]: Unable to set DHCP entry 
([RestClient::Conflict]: 409 Conflict) for proxy 
https://jarvis.no-dns.co.uk:8443/dhcp

2017-05-14 16:55:27 4335f5d9 [app] [I] Deface: [WARNING] No :original 
defined for 'ansible_roles_tab', you should change its definition to 
include:

 |  :original => 'f234dfccee67a10906661b649c8cf0ee976e3c58' 

2017-05-14 16:55:27 4335f5d9 [app] [I] Deface: [WARNING] No :original 
defined for 'ansible_roles_tab_content', you should change its definition 
to include:

 |  :original => '0ae5bea2647fca8e5a2e6f67acb510e0a36c00b3' 

2017-05-14 16:55:27 4335f5d9 [app] [I] Deface: [WARNING] No :original 
defined for 'add_execution_interface_js', you should change its definition 
to include:

 |  :original => '0ae5bea2647fca8e5a2e6f67acb510e0a36c00b3' 

2017-05-14 16:55:27 4335f5d9 [app] [I]   Rendered hosts/_progress.html.erb 
(0.9ms)

2017-05-14 16:55:27 4335f5d9 [app] [I]   Rendered 
hosts/puppet/_main_tab_fields.html.erb (3.4ms)

2017-05-14 16:55:27 4335f5d9 [app] [I]   Rendered 
puppetclasses/_selectedClasses.html.erb (0.0ms)

2017-05-14 16:55:27 4335f5d9 [app] [I]   Rendered 
puppetclasses/_classes_in_groups.html.erb (0.0ms)

2017-05-14 16:55:27 4335f5d9 [app] [I]   Rendered 
puppetclasses/_classes.html.erb (4.1ms)

2017-05-14 16:55:27 4335f5d9 [app] [I]   Rendered 
puppetclasses/_class_selection.html.erb (40.3ms)

2017-05-14 16:55:27 4335f5d9 [app] [I]   Rendered 
hosts/puppet/_puppet_classes_tab.html.erb (42.7ms)

2017-05-14 16:55:27 4335f5d9 [app] [I] Deface: [WARNING] No :original 
defined for 'add_execution_interface', you should change its definition to 
include:

 |  :original => 'c914babc38015fdebf1049da540a2fac14c0673e' 

2017-05-14 16:55:27 4335f5d9 [app] [I]   Rendered nic/_base_form.html.erb 
(33.1ms)

2017-05-14 16:55:27 4335f5d9 [app] [I]   Rendered 
nic/_virtual_form.html.erb (3.6ms)

2017-05-14 16:55:27 4335f5d9 [app] [I]   Rendered 
nic/_provider_specific_form.html.erb (0.9ms)

2017-05-14 16:55:27 4335f5d9 [app] [I]   Rendered 
nic/manageds/_managed.html.erb (61.2ms)

2017-05-14 16:55:27 4335f5d9 [app] [I]   Rendered nic/_base_form.html.erb 
(21.2ms)

2017-05-14 16:55:27 4335f5d9 [app] [I]   Rendered 
nic/_virtual_form.html.erb (2.0ms)

2017-05-14 16:55:27 4335f5d9 [app] [I]   Rendered 
nic/_provider_specific_form.html.erb (0.2ms)

2017-05-14 16:55:27 4335f5d9 [app] [I]   Rendered 
nic/manageds/_managed.html.erb (29.4ms)

2017-05-14 16:55:27 4335f5d9 [app] [I]   Rendered 
hosts/_interfaces.html.erb (99.3ms)

2017-05-14 16:55:27 4335f5d9 [app] [I]   Rendered 
common/os_selection/_architecture.html.erb (15.3ms)

2017-05-14 16:55:27 4335f5d9 [app] [I]   Rendered 
common/os_selection/_pxe_loader.html.erb (1.8ms)

2017-05-14 16:55:27 4335f5d9 [app] [I]   Rendered 
common/os_selection/_operatingsystem.html.erb (11.5ms)

2017-05-14 16:55:27 4335f5d9 [app] [I]   Rendered 
hosts/provision_method/build/_form.html.erb (14.8ms)

2017-05-14 16:55:27 4335f5d9 [app] [I]   Rendered 
hosts/provision_method/image/_form.html.erb (0.7ms)

2017-05-14 16:55:27 4335f5d9 [app] [I]   Rendered 
hosts/_operating_system.html.erb (45.7ms)

2017-05-14 16:55:27 4335f5d9 [app] [I]   Rendered 
hosts/_unattended.html.erb (48.2ms)

2017-05-14 16:55:27 4335f5d9 [app] [I]   Rendered 
puppetclasses/_class_parameters.html.erb (0.0ms)

2017-05-14 16:55:27 4335f5d9 [app] [I]   Rendered 
puppetclasses/_classes_parameters.html.erb (8.7ms)

2017-05-14 16:55:27 4335f5d9 [app] [I]   Rendered 
common_parameters/_inherited_parameters.html.erb (16.3ms)

2017-05-14 16:55:27 4335f5d9 [app] [I]   Rendered 
common_parameters/_parameter.html.erb (4.5ms)

2017-05-14 16:55:27 4335f5d9 [app] [I]   Rendered 
common_parameters/_parameters.html.erb (16.9ms)

2017-05-14 16:55:27 4335f5d9 [app] [I]   Rendered hosts/_form.html.erb 
(345.2ms)

2017-05-14 16:55:27 4335f5d9 [app] [I]   Rendered hosts/new.html.erb within 
layouts/application (594.0ms)

2017-05-14 16:55:27 4335f5d9 [app] [I]   Rendered 
layouts/_application_content.html.erb (0.9ms)

2017-05-14 16:55:27 4335f5d9 [app] [I]   Rendered 
home/_user_dropdown.html.erb (18.3ms)

2017-05-14 16:55:27 4335f5d9 [app] [I] Read fragment 
views/tabs_and_title_records-3 (0.1ms)

2017-05-14 16:55:27 4335f5d9 [app] [I]   Rendered 
home/_org_switcher.html.erb (0.5ms)

2017-05-14 16:55:27 4335f5d9 [app] [I]   Rendered home/_submenu.html.erb 
(4.5ms)

2017-05-14 16:55:27 4335f5d9 [app] [I]   Rendered home/_submenu.html.erb 
(1.2ms)

2017-05-14 16:55:27 4335f5d9 [app] [I]   Rendered home/_submenu.html.erb 
(3.3ms)

2017-05-14 16:55:27 4335f5d9 [app] [I]   Rendered home/_submenu.html.erb 
(2.9ms)

2017-05-14 16:55:27 4335f5d9 [app] [I]   Rendered home/_submenu.html.erb 
(2.3ms)

2017-05-14 16:55:27 4335f5d9 [app] [I]   Rendered home/_submenu.html.erb 
(2.9ms)

2017-05-14 16:55:27 4335f5d9 [app] [I] Write fragment 
views/tabs_and_title_records-3 (0.6ms)

2017-05-14 16:55:27 4335f5d9 [app] [I]   Rendered home/_topbar.html.erb 
(147.3ms)

2017-05-14 16:55:27 4335f5d9 [app] [I]   Rendered layouts/base.html.erb 
(152.5ms)

2017-05-14 16:55:27 4335f5d9 [app] [I] Completed 200 OK in 1218ms (Views: 
744.0ms | ActiveRecord: 25.7ms)

2017-05-14 16:55:28 963db64e [app] [I] Started GET 
"/tasks/056348eb-43db-4be8-b725-392d717b3897" for 10.11.216.43 at 
2017-05-14 16:55:28 +0100

2017-05-14 16:55:28 963db64e [app] [I] Processing by TasksController#show 
as */*

2017-05-14 16:55:28 963db64e [app] [I]   Parameters: 
{"id"=>"056348eb-43db-4be8-b725-392d717b3897"}

2017-05-14 16:55:28 963db64e [app] [I] Current user: admin (administrator)

2017-05-14 16:55:28 963db64e [app] [I]   Rendered tasks/_list.html.erb 
(0.7ms)

2017-05-14 16:55:28 963db64e [app] [I] Completed 200 OK in 12ms (Views: 
6.7ms | ActiveRecord: 0.8ms)

2017-05-14 16:55:33 745b809b [app] [I] Started GET 
"/notification_recipients" for 10.11.216.43 at 2017-05-14 16:55:33 +0100

2017-05-14 16:55:33 745b809b [app] [I] Processing by 
NotificationRecipientsController#index as JSON

2017-05-14 16:55:33 745b809b [app] [I] Current user: admin (administrator)


2017-05-14 16:55:33 745b809b [app] [I] Completed 200 OK in 3ms (Views: 
0.1ms | ActiveRecord: 0.2ms)



The proxy log also shows this


W, [2017-05-14T16:55:27.024991 ]  WARN -- : Request to create a conflicting 
DHCP record

E, [2017-05-14T16:55:27.025271 ] ERROR -- : Record 10.11.216.0/10.11.216.44 
already exists


I, [2017-05-14T16:55:27.025558 ]  INFO -- : 10.11.216.4 - - 
[14/May/2017:16:55:27 +0100] "POST /dhcp/10.11.216.0 HTTP/1.1" 409 46 0.0010


so why isn't this being overwritten or not even a problem as it's the same 
host with the same mac and the same IP - so it shouldn't need to write 
anything new because it knows its already got an entry ?


Getting a clarficiation on the expected behaviour would be helpful to 
working this through.


I'm reasonably confident that this is not actually a foreman bug but more 
likley something to do with the 1.15 install on my env, but because this is 
using my standard test env and deployment setup, that works fine with 1.13 
and 1.14 (and earlier but I don't have those installers any more) I'm not 
sure why this doesn't work at this stage.


-- 
You received this message because you are subscribed to the Google Groups 
"Foreman users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/foreman-users.
For more options, visit https://groups.google.com/d/optout.

Reply via email to