> Is there a reason why Foreman/Smart-proxy only uses iPXE by chaining
> through PXElinux and not natively? Is it hard to add at least on
> smart-proxy side?
>
>
The actual change is very simple:
]# pwd
/usr/share/foreman-proxy/modules/tftp
# diff tftp_api.rb-orig tftp_api.rb
11c11
< VARIANTS = ["Syslinux", "Pxegrub", "Pxegrub2", "Ztp", "Poap"].freeze
---
> VARIANTS = ["Syslinux", "Pxegrub", "Pxegrub2", "Ztp", "Poap",
"Ipxe"].freeze
# diff server.rb-orig server.rb
70a71,82
> class Ipxe < Server
> def pxeconfig_dir
> "#{path}/pxelinux.cfg"
> end
> def pxe_default
> "#{pxeconfig_dir}/default.ipxe"
> end
> def pxeconfig_file mac
> "#{pxeconfig_dir}/01-"+mac.gsub(/:/,"-").downcase+".ipxe"
> end
> end
>
However, I immediately ran into issue with the size of ipxe config file -
it could be much larger that syslinux config file and if ipxe config file
is large, TFTP API only writes 464 bytes for me:
# curl -k --cacert /var/lib/puppet/ssl/certs/ca.pem --cert
/var/lib/puppet/ssl/certs/`hostname -f`.pem --key
/var/lib/puppet/ssl/private_keys/`hostname -f`.pem -H
"Accept:application/json" -X POST
https://<proxy>:8443/tftp/ipxe/00:11:22:33:44:55 -d "pxeconfig=`cat
default.ipxe`"
#
# ls -l default.ipxe 01-00-11-22-33-44-55.ipxe
-rw-r--r--. 1 foreman-proxy foreman-proxy 464 Aug 2 17:28
01-00-11-22-33-44-55.ipxe
-rw-r--r--. 1 foreman-proxy foreman-proxy 2976 Aug 2 17:28 default.ipxe
#
This problem exist even w/o above changes and is not ipxe-related. For
example, here's an attempt to create "syslinux" variant from a larger file
and resulting file is still 464 bytes in length:
# curl -k --cacert /var/lib/puppet/ssl/certs/ca.pem --cert
/var/lib/puppet/ssl/certs/`hostname -f`.pem --key
/var/lib/puppet/ssl/private_keys/`hostname -f`.pem -H
"Accept:application/json" -X POST
https://spc.vip.syd.ebay.com:8443/tftp/syslinux/00:11:22:33:44:55 -d
"pxeconfig=`cat default.ipxe`"
#
# ls -l default.ipxe 01-00-11-22-33-44-55
-rw-r--r--. 1 foreman-proxy foreman-proxy 464 Aug 2 17:31
01-00-11-22-33-44-55
-rw-r--r--. 1 foreman-proxy foreman-proxy 2976 Aug 2 17:28 default.ipxe
#
--
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.