No subnet detected

Problem:
Even though I create a subnet (10.137.0.0/16) in Infrastructure/Subnets (associated with a domain and a smart proxy), when I try to create a host with an IP on that subnet I get a “No Subnet detected for: 10.137.0.0”

Expected outcome:
Being able to manage DHCP entries

Foreman and Proxy versions:
3.10.0

Foreman and Proxy plugin versions:
/

Distribution and version:
AlmaLinux 8.9

Other relevant data:

Full Error

Error details for No Subnet detected for: 10.137.0.0: <Proxy::DHCP::Error>: No Subnet detected for: 10.137.0.0#012/usr/share/foreman-proxy/modules/dhcp_common/server.rb:144:in `add_record'#012/usr/share/foreman-proxy/modules/dhcp_common/isc/omapi_provider.rb:35:in `add_record'#012/usr/share/foreman-proxy/modules/dhcp/dhcp_api.rb:81:in `block in <class:DhcpApi>'#012/usr/share/gems/gems/sinatra-2.2.4/lib/sinatra/base.rb:1697:in `call'#012/usr/share/gems/gems/sinatra-2.2.4/lib/sinatra/base.rb:1697:in `block in compile!'#012/usr/share/gems/gems/sinatra-2.2.4/lib/sinatra/base.rb:1030:in `block (3 levels) in route!'#012/usr/share/gems/gems/sinatra-2.2.4/lib/sinatra/base.rb:1049:in `route_eval'#012/usr/share/gems/gems/sinatra-2.2.4/lib/sinatra/base.rb:1030:in `block (2 levels) in route!'#012/usr/share/gems/gems/sinatra-2.2.4/lib/sinatra/base.rb:1078:in `block in process_route'#012/usr/share/gems/gems/sinatra-2.2.4/lib/sinatra/base.rb:1076:in `catch'#012/usr/share/gems/gems/sinatra-2.2.4/lib/sinatra/base.rb:1076:in `process_route'#012/usr/share/gems/gems/sinatra-2.2.4/lib/sinatra/base.rb:1028:in `block in route!'#012/usr/share/gems/gems/sinatra-2.2.4/lib/sinatra/base.rb:1025:in `each'#012/usr/share/gems/gems/sinatra-2.2.4/lib/sinatra/base.rb:1025:in `route!'#012/usr/share/gems/gems/sinatra-2.2.4/lib/sinatra/base.rb:1147:in `block in dispatch!'#012/usr/share/gems/gems/sinatra-2.2.4/lib/sinatra/base.rb:1119:in `block in invoke'#012/usr/share/gems/gems/sinatra-2.2.4/lib/sinatra/base.rb:1119:in `catch'#012/usr/share/gems/gems/sinatra-2.2.4/lib/sinatra/base.rb:1119:in `invoke'#012/usr/share/gems/gems/sinatra-2.2.4/lib/sinatra/base.rb:1142:in `dispatch!'#012/usr/share/gems/gems/sinatra-2.2.4/lib/sinatra/base.rb:956:in `block in call!'#012/usr/share/gems/gems/sinatra-2.2.4/lib/sinatra/base.rb:1119:in `block in invoke'#012/usr/share/gems/gems/sinatra-2.2.4/lib/sinatra/base.rb:1119:in `catch'#012/usr/share/gems/gems/sinatra-2.2.4/lib/sinatra/base.rb:1119:in `invoke'#012/usr/share/gems/gems/sinatra-2.2.4/lib/sinatra/base.rb:956:in `call!'#012/usr/share/gems/gems/sinatra-2.2.4/lib/sinatra/base.rb:945:in `call'#012/usr/share/gems/gems/rack-2.2.8/lib/rack/method_override.rb:24:in `call'#012/usr/share/foreman-proxy/lib/proxy/log.rb:101:in `call'#012/usr/share/foreman-proxy/lib/proxy/request_id_middleware.rb:11:in `call'#012/usr/share/gems/gems/rack-protection-2.2.4/lib/rack/protection/xss_header.rb:18:in `call'#012/usr/share/gems/gems/rack-protection-2.2.4/lib/rack/protection/path_traversal.rb:16:in `call'#012/usr/share/gems/gems/rack-protection-2.2.4/lib/rack/protection/json_csrf.rb:26:in `call'#012/usr/share/gems/gems/rack-protection-2.2.4/lib/rack/protection/base.rb:50:in `call'#012/usr/share/gems/gems/rack-protection-2.2.4/lib/rack/protection/base.rb:50:in `call'#012/usr/share/gems/gems/rack-protection-2.2.4/lib/rack/protection/frame_options.rb:31:in `call'#012/usr/share/gems/gems/rack-2.2.8/lib/rack/null_logger.rb:11:in `call'#012/usr/share/gems/gems/rack-2.2.8/lib/rack/head.rb:12:in `call'#012/usr/share/gems/gems/sinatra-2.2.4/lib/sinatra/show_exceptions.rb:22:in `call'#012/usr/share/gems/gems/sinatra-2.2.4/lib/sinatra/base.rb:218:in `call'#012/usr/share/gems/gems/sinatra-2.2.4/lib/sinatra/base.rb:2004:in `call'#012/usr/share/gems/gems/sinatra-2.2.4/lib/sinatra/base.rb:1564:in `block in call'#012/usr/share/gems/gems/sinatra-2.2.4/lib/sinatra/base.rb:1780:in `synchronize'#012/usr/share/gems/gems/sinatra-2.2.4/lib/sinatra/base.rb:1564:in `call'#012/usr/share/gems/gems/rack-2.2.8/lib/rack/urlmap.rb:74:in `block in call'#012/usr/share/gems/gems/rack-2.2.8/lib/rack/urlmap.rb:58:in `each'#012/usr/share/gems/gems/rack-2.2.8/lib/rack/urlmap.rb:58:in `call'#012/usr/share/gems/gems/rack-2.2.8/lib/rack/builder.rb:244:in `call'#012/usr/share/gems/gems/rack-2.2.8/lib/rack/handler/webrick.rb:95:in `service'#012/usr/share/gems/gems/webrick-1.8.1/lib/webrick/httpserver.rb:140:in `service'#012/usr/share/gems/gems/webrick-1.8.1/lib/webrick/httpserver.rb:96:in `run'#012/usr/share/gems/gems/webrick-1.8.1/lib/webrick/server.rb:310:in `block in start_thread'#012/usr/share/gems/gems/logging-2.3.1/lib/logging/diagnostic_context.rb:474:in `block in create_with_logging_context'

I’ll answer my own question… Foreman-installer manages one subnet at a time, multiple subnets must be declared in /etc/foreman-installer/custom-hiera.yaml at install time

1 Like