Created attachment 185469 [details] Add make config option to remove ec2 facts the latest rubygem-facter (2.5.0) tries to communicate with a Amazon web page (169.254.169.254) for any virtual machine of type xen or kvm. On my RootBSD VPS we see this timing: pirzyk@stitch:~/tmp 2>time facter > /dev/null real 7m43.22s user 0m0.25s sys 0m0.11s After the attached patch is applied the timings return to normal: pirzyk@stitch:~/tmp 3>time facter > /dev/null real 0m0.34s user 0m0.21s sys 0m0.12s The patch add an option to remove the ec2 facts from the facter install, following the same steps available to remove the zfs/zpool facts.
I had the same problem on my bhyve virtual machines (all FreeBSD). Disabling EC2 facts solved the problem, facter show the facts within milliseconds instead of minutes. IMHO EC2 facts should be disabled by default as well as ZFS facts.
A commit references this bug: Author: robak Date: Wed Nov 8 11:53:50 UTC 2017 New revision: 453731 URL: https://svnweb.freebsd.org/changeset/ports/453731 Log: sysutils/rubygem-facter: add AWS EC2 facts option On machines that are not running in AWS EC2 cloud running facter was taking very long time trying to gather information that wasn't there. This change adds an option allowing to disable such facts in similar manner to ZFS related facts. PR: 221552 Submitted by: pirzyk Changes: head/sysutils/rubygem-facter/Makefile
Committed, thanks!