2
0
mirror of https://github.com/xcat2/confluent.git synced 2024-11-29 13:00:03 +00:00
Commit Graph

3861 Commits

Author SHA1 Message Date
Jarrod Johnson
2ef41fedf6 Add el9 compatible build
CentOS Stream 9 is not backwards compatible enough to run the
same confluent utilities that the other distributions use.

For now, use fedora to build.
2021-10-06 15:51:12 -04:00
Jarrod Johnson
d666050ef7 Consolidate neigh wait time in slp
Rather than incurring it on each iteration (causing a scan to take
15 seconds in test), defer to
handle them all later (reducing to 5 seconds to scan).
2021-10-05 10:59:17 -04:00
Jarrod Johnson
3c72f9f18f Refactor slp neigh warm-up
Rather than pulling it out at active_scan level, intervene deeply.

This fixes the problem where an ip gets used as a key rather than mac.
2021-10-05 10:50:51 -04:00
Jarrod Johnson
f50abd662a Provide analogus improvements to ssdp from slp
Recent changes to try to make neigh table fresh and viable in slp
can also apply to ssdp.

Bring those changes forward.
2021-10-05 10:03:28 -04:00
Jarrod Johnson
1fda0e50d8 Fix stub from refactor
foobar was a stand-in for continue to
allow refactor, and needed
to be changed to return.
2021-10-05 08:04:58 -04:00
Jarrod Johnson
1a80d9f31a Extend neigh table refresh to snoop
Improve reliability of 'snooping' slp.
2021-10-04 16:36:22 -04:00
Jarrod Johnson
c569826ff1 Improve scan result with missing neigh entries
If no neigh table is present for
a given address, send a packet to
induce kernel activity.

Then wait for a bit over 2 seconds to allow for
2 retries (at default settings)
and then proceed assuming all findable neighbor table
entries will be found.
2021-10-04 16:22:12 -04:00
Jarrod Johnson
1c69700e1d Fix missing port 22
Either this was overlooked or the sshd_config stopped including
Port 22.  Fix by putting in port 22.  If port 22 already existed,
sshd is fine with the configuration being configured twice.
2021-10-01 08:34:51 -04:00
Jarrod Johnson
92949f012f Merge tag '3.2.2'
Fix collective mode
2021-10-01 08:03:50 -04:00
Jarrod Johnson
398c8b3a71 Improve syncfiles permission denied reporting
When a non-readable file was
encountered, confluent would
cryptically report rsync failure.

Check for the usual culprit, unreadable files if rsync fails.

Cause this error to manifest with clearer text.
2021-09-30 12:01:29 -04:00
Jarrod Johnson
c93917e4a4 Add a failsafe for errors trying to connect to a new leader
Provide better experience in the face of the class of errors such
as the one fixed by previous commit.
2021-09-30 08:18:39 -04:00
Jarrod Johnson
c1113430a2 Pass only the name rather than full sockaddr on retire
Followers of a server that is retiring to join the better leader
were being given incorrect format which would fail in the dns lookup.
2021-09-30 08:11:19 -04:00
Jarrod Johnson
d899cfbf1a Clean disk to install in pre
Installers frequently fail if there's a derelict lvm on disk.

Explicitly remove the on-disk content and deactive lvm to let
anaconda work reliably.
2021-09-29 14:31:18 -04:00
Jarrod Johnson
99ba4e7765 Handle ip aliases in pxe
Use netutil assessment of the
best server ip for pxe responses.

Using 'recvip' is too simplistic for broadcast
packets.  recvip just gets the first ipv4 address on the interface,
when an alias may be better.

netutil assesses all the possible aliases, thus has better logic and pxe.py
now uses it.
2021-09-27 11:04:42 -04:00
Jarrod Johnson
929392c746 Fix hangs on check_output
Eventlet narrowly targets overriding
select in subprocess, to avoid rewriting adequate functions.

However, subprocess does an 'optimization' to skip
select if there's fewer than 3 pipes to juggle and no timeout specified.

Induce python to always use select
by specifying a very long timeout.

This causes confluent to be able to spawn multiple subprocesses and
not be hung waiting for input.
2021-09-23 10:42:47 -04:00
Jarrod Johnson
5d20ee6cca Serialize ssh agent interaction
Race conditions could occur when multiple
requests came in too close together.
2021-09-23 09:40:10 -04:00
Jarrod Johnson
42038048da Drop PC from the speed prefix 2021-09-22 10:52:29 -04:00
Jarrod Johnson
d08d597818 Properly show DCPMM in nodeinventory 2021-09-22 10:50:32 -04:00
Jarrod Johnson
3869dd6918 Fix imgutil capture
Adding options for oshandler
broke fingerprinting for capture.

Fix by passing None and triggering the AttributeErrors.
2021-09-22 08:17:18 -04:00
Jarrod Johnson
4ab5cac3eb Generate random serial number for certificate
Hardcoding 0x123 serial number would cause strict clients to reject the
certificate.

While we are still not guaranteeing uniqueness, the chances of a
duplicate are impossibly small.
2021-09-22 07:48:44 -04:00
Jarrod Johnson
3a911acb81 Fix the efibootmgr override logic
Fully realize the chroot invocation of efibootmgr and also
bail out if no new boot number is detected.
2021-09-21 15:50:45 -04:00
Jarrod Johnson
1cb5efae75 Call efibootmgr in chroot for ubuntu 2021-09-21 11:21:13 -04:00
Jarrod Johnson
861c0230c7 Reorder ubuntu to first in post
Ubuntu tends to install itself as behind network
device.  Amend to match other OSes and avoid network
boot.
2021-09-21 10:03:29 -04:00
Jarrod Johnson
3b3fffb36b Note workaround for 'No data available'
In a diskless boot, sometimes the build system
might not label the scratch contents
correctly.  setfiles can be used to fix it.

Notably, this seems to cause the overlay+squashfs to
return 'no data available' on select
calls even with selinux disabled, so it may be another
gap with overlay and/or limitation of squashfs when
queried about modification without a label.
2021-09-21 08:13:06 -04:00
Jarrod Johnson
dd89c48b9a Fix problem where syncfiles could fail on certan hosts
If the set of oldhosts and newhosts were just so,
targlines or sourcelines could be all
null and cause index errors.
2021-09-20 08:01:41 -04:00
Jarrod Johnson
6acd3c2b7d Add ability to execute functions as a command
This gives easier access over nodeshell and similar to run functions by executing the
functions as a script with arguments.
2021-09-20 08:00:35 -04:00
Jarrod Johnson
fdc9b3c283 Add confluent2hosts utility
Add utility to help add/modify /etc/hosts for a noderange.

Also fix buggy code in syncfileclient noticed while
reusing it for confluent2hosts.
2021-09-17 12:57:18 -04:00
Jarrod Johnson
1b88e44c59 Ignore broken lldp results
Some switches may have broken incomplete records,
skip such records to focus on viable complete records.
2021-09-16 15:49:36 -04:00
Jarrod Johnson
f881f955d4 Correct typo in ubunut initramfs scripts 2021-09-15 12:20:08 -04:00
Jarrod Johnson
9687ce89b8 Use fe80:: match to find index for getting addresses
This fixes a problem where fetching
from fe80:: fails to identify nic.
2021-09-13 17:54:18 -04:00
Jarrod Johnson
5276618b73 Actually remove group on split 2021-09-13 14:09:07 -04:00
Jarrod Johnson
38669ddbbc Have nodegroupremove accept comma delimited groups 2021-09-13 14:01:46 -04:00
Jarrod Johnson
2dcd0f769a Support defining multiple groups in one go 2021-09-13 13:48:56 -04:00
Jarrod Johnson
d254cb08ac Default to None for second arg to get_apikey
In some context, we don't need to check both, we have a confirmed manager. Just take
one argument for that scenario.
2021-09-13 11:48:36 -04:00
Jarrod Johnson
66ddcfc194 Separate connection check from connection
Messing with connect corrupted
the http client too much,
have a separate helper function to evaluate
the candidate deployers,
then pass only the winner on.
2021-09-13 11:21:38 -04:00
Jarrod Johnson
95ea913108 Have genesis opt into ipv6 deploycfg 2021-09-13 10:26:50 -04:00
Jarrod Johnson
52bebe41d1 Provide ipv6 only for deploycfg2
Older profiles may trip over new network
lines, spare them 'v6' entries until
they opt into deploycfg2.
2021-09-13 10:26:17 -04:00
Jarrod Johnson
06e32c53cc Fix overly vague extraction of deploy_server
If deploy_server appears anywhere, it confuses
the scripts
2021-09-13 10:23:13 -04:00
Jarrod Johnson
7ba10e559e Correct ipv4/v6 handling in get_apikey 2021-09-13 10:03:32 -04:00
Jarrod Johnson
cf097b153e Fix typo in genesis network bringup 2021-09-10 12:50:06 -04:00
Jarrod Johnson
269d9c79d1 Let functions set confluent_mgr
The better logic in functions is used instead of the simplistic logic.
2021-09-10 12:28:00 -04:00
Jarrod Johnson
1c3c54a35b Update functions to be more thorough
confluent_mgr could be ipv6 or
may need to be updated from a
link local or may need to go to copernicus data to work.
2021-09-10 11:40:17 -04:00
Jarrod Johnson
66d378a007 Simplify the ipv6 support and fix invocation before deploycfg 2021-09-10 09:16:08 -04:00
Jarrod Johnson
35b74764bf Amend apiclient to support v4/v6 2021-09-09 17:15:29 -04:00
Jarrod Johnson
11796cda81 Correct the ipv6 prefix name 2021-09-09 16:51:27 -04:00
Jarrod Johnson
8eb242cba0 Add ipv6 support to genesis 2021-09-09 16:27:59 -04:00
Jarrod Johnson
a4de3b93ec Merge branch 'master' into ip6 2021-09-08 12:44:05 -04:00
Jarrod Johnson
a3486c5e68 Skip calling localectl when possible
localectl can sometimes be unworkable,
prefer sourcing the relevant configuration files directly
when possible.
2021-09-08 12:43:56 -04:00
Jarrod Johnson
465b973f79 Add unencrypted option to pack and rework multi-repo support
Support skipping encryption if a user does not want it. Further support mulitple '-r'
arguments and fix builds when
no -r is specified.
2021-09-08 12:43:50 -04:00
Jarrod Johnson
20f607f49e Skip calling localectl when possible
localectl can sometimes be unworkable,
prefer sourcing the relevant configuration files directly
when possible.
2021-09-08 12:42:43 -04:00