2
0
mirror of https://github.com/xcat2/confluent.git synced 2026-06-15 16:17:40 +00:00
Commit Graph

93 Commits

Author SHA1 Message Date
Jarrod Johnson 38fe07ea28 Fix name of ssh in various ubuntu scripts 2026-05-13 13:52:29 -04:00
Jarrod Johnson c11fdcc286 Add missing syncfiles examples to ubuntu profiles 2026-05-13 13:51:13 -04:00
Jarrod Johnson 2d29813320 Store device for future use in ubuntu deployment 2025-10-02 14:28:46 -04:00
Jarrod Johnson a9d15de156 Rework Ubuntu identity image DHCP bringup
The stock Ubuntu approach was inadequate.  It would DHCP out every nic and take the fastest result, and no going back.

Now the CDC nic can frequently win that race.

First, rmmod cdc_ether, as a scenario that is completely right out.

But beyond that, let Ubuntu have one shot at multi-nic bringup.  Beyond that, maintain a list of all link-up devices.

If the check should fail, then start doing one nic at a time, cycling through them.

Also, the openssl s_client timeout is painfully slow, use subshell and kill to speed up things.
2025-10-02 10:55:43 -04:00
Jarrod Johnson 5905510a32 Move tmp script execution out of /tmp
Some environments want noexec on /tmp, this will work in such environments.
2025-08-28 08:34:07 -04:00
Jarrod Johnson 48a0c21300 Refine getinstalldisk
Reduce obvious output about skipped devices.

Rule out any read-only device.

Amend minimum size to 2GB.

Among same priority devices, select the smallest target.
2025-08-01 09:00:25 -04:00
Jarrod Johnson 97e4d7c3d0 Skip sr0 if attempted 2025-07-29 15:33:05 -04:00
Jarrod Johnson b21d8b75e0 Incorporate block device into retry loop
Have block devices checked for identity information
in a loop with network source search.

Block devices may be delayed for various reasons. The previous method
could be bypassed by fast block device cutting off slow device
enumeration. It also incurred a delay for the network install
case.
2025-04-02 09:50:15 -04:00
Jarrod Johnson f6e9691b7f Amend arguments on IPv4 invocation
It turns out that when busybox invokes openssl for
IPv4, it does not pass a servername field.

In this case, start amending arguments after '-verify' instead, to catch
the verify_ip argument correctly.
2025-03-20 08:21:47 -04:00
Jarrod Johnson ef68259745 Provide more full fixup of openssl invocation in wget
For IPv4 and IPv6, strip the ':443' for arguments where it doesn't make sense.

For IPv6, strip out [, ], and '%' from those arguments.
2025-03-19 12:41:50 -04:00
Jarrod Johnson 1e463367fe Switch Ubunut initramfs to ssl
The busybox wget invocation of openssl is broken.

Override by stubbing it out to let openssl pick the verify
hostname instead of wget specified one, which is incorrect.
2025-03-18 15:52:37 -04:00
Hengli Kuang 75a0f44a36 add a loop to find the accessible deployer when the method is not static 2025-02-28 13:53:28 +08:00
Jarrod Johnson b9f4051396 Export variables set in confluent functions 2025-02-03 16:40:57 -05:00
Jarrod Johnson 2c9b526de4 Repeat the interface loop for Ubuntu identity deploy
It may happen that the first pass at nics misses
a viable network interface due to slow link up
or slow spanning tree forwarding.

Repeat the loop through the interfaces to have follow
up chances at success.
2024-12-05 14:26:26 -05:00
Jarrod Johnson 008c1308b4 Handle nvm subsystem without driver.
A variant of the M.2 RAID enablement kit does not manifest with nvme
driver.  Address this by allowing 'nvm' subsystype. to allow blank driver.

Also, to be on the safe side, have self.driver always be a string,
so it can be 'falsey' but still work as a string.
2024-10-26 08:16:56 -04:00
Jarrod Johnson 1da27083cc Another cleanup of syncfileclient output 2024-04-09 15:08:56 -04:00
Jarrod Johnson 67b3c48dc9 Clean up error output on syncfileclient execution 2024-04-09 14:58:38 -04:00
Jarrod Johnson 02f301b5d0 Fix mistakes in syncfileclient change 2024-04-09 13:41:27 -04:00
Jarrod Johnson f68f9f4693 Make syncfile step robust or pause
If syncfiles fails, keep it retrying.

Also, slow down sync checking to avoid hammering the system.

Further, randomized delay to spread highly synchronized requestors.

Block attempts to do multiple concurrent syncfile runs.
2024-04-09 11:07:11 -04:00
Jarrod Johnson 6502573d90 Bring ubuntu 22 versions of firstboot and post to 20 2024-03-18 09:15:11 -04:00
Jarrod Johnson 3dd09b95e4 Fix Ubuntu 20 pre script to match 22 2024-03-18 09:13:53 -04:00
Jarrod Johnson a595d31e94 Explicitly invoke bash for ubuntu post
Ubuntu really tries to use non-bash, explicitly use bash when we need it.
2024-03-18 08:56:06 -04:00
henglikuang1 ea88ccb0ad Fix efivars handling of unexpected unmount 2024-01-11 14:31:45 +08:00
Jarrod Johnson 68ce3d039d Filter out nvme 'c' devnames, that are used to refer to paths to nvme
Some versions start manifesting nvme devnames with 'c', which
are to be used to interact with multipath to have raw devices
backing a traditional nvme device.
2023-11-27 08:34:34 -05:00
Jarrod Johnson f16cf4387f Further Ubuntu enhancements
Add confignet to Ubuntu 20 and 22
Add syncfile to the ubuntu diskless/cloning
2023-09-01 16:40:02 -04:00
Jarrod Johnson 95c5253944 Remove CIDR prefix length in ubuntu 20 deployment
This produces invalid configuration for subiquity otherwise.
2023-08-11 15:01:55 -04:00
Jarrod Johnson ca2dcd2dbe Reference identity network in ubuntu 20.04
When using identity image, also use identity image
for network configuration.
2023-08-11 14:34:12 -04:00
Jarrod Johnson dba6e7f378 Change Ubuntu 20.04 to be consistent to 22.04
This aims to bring
identity image deployment fully to ubuntu 20.0.4.
2023-08-11 13:44:37 -04:00
Jarrod Johnson 7b150773df Extend multi-nic guessing to Ubuntu 20/22 2023-04-20 15:45:32 -04:00
Jarrod Johnson 305a3a06d2 Ensure $HOME is set during firstboot
systemd tends not to set environment variables.  However some firstboot
scripts generally expect $HOME to be correct.
2023-04-12 11:22:27 -04:00
Jarrod Johnson bb7a72db65 Fix for ipv6 deployment
Need to avoid double-bracketing of the server and also disable globbing
so curl does not mistake the ip address for a glob attempt.
2023-02-13 09:36:42 -05:00
Jarrod Johnson 20e6e1e521 Refresh functions to cope with v6-only usage 2022-11-08 08:52:29 -05:00
Jarrod Johnson 6eb4bf28e5 Another iteration to try to have IP adaptive syncfiles
It is likely that a client connects from fe80::, which
is explicitly omitted from ssh principals.

This time, have the client provide all currently set IP addresses
and the server will make a determination.

There remains the possibility it misconfigures a nic and tries to use that,
inducing failure.  One strategy would be to filter the addresses and
only provide from the 'current' interface.  Another is to just take
the hit as the node is likely going to suffer a lot from such a
misconfiguration anyway.
2022-10-05 12:23:47 -04:00
Jarrod Johnson b98759698a Sync up getinstalldisk and add another m.2 model 2022-09-01 13:22:50 -04:00
Jarrod Johnson 5fb766e62b Move apiclient consistently to /opt/confluent/bin
It's more reasonable to have
it in a bin directory
2022-03-03 11:11:29 -05:00
Jarrod Johnson 224663d0c8 Fix execution of confluent functions after run_remote_python 2021-10-29 13:50:04 -04:00
Jarrod Johnson 729408a0cb Fix run_remote aafter the cleanup was added
The removal of the temp dir needed to be linked with
whether the script was dedicated or shared tmp with a run_remote_parts.
2021-10-29 13:01:59 -04:00
Jarrod Johnson 8eb6ce0b69 Specify absolute path for mktemp
mktemp defaults to relative, to produce the correct
behavior, must be absolute template.
2021-10-25 12:03:26 -04:00
Jarrod Johnson 98a6ffd9b6 Update more profiles with the APPENDONCE support 2021-10-15 16:16:11 -04:00
Jarrod Johnson f33ed9b4d9 Cleanup after script execution
Leave cleaner tmp directories when functions are ran.
2021-10-15 12:16:48 -04:00
Jarrod Johnson 04dd374bfb Synchronize functions across the supported OSes 2021-10-15 12:10:24 -04:00
Jarrod Johnson 57f346fa4c Implement syncfiles parameters
chmod and chown as directed
by the syncfiles file if present
2021-10-08 10:27:57 -04:00
Jarrod Johnson 3b7e7afc24 Fix inconsistent handling of marginal id in syncfileclient
Also, resynchronize syncfileclient across the distributions.
2021-10-07 12:36:52 -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 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 f881f955d4 Correct typo in ubunut initramfs scripts 2021-09-15 12:20:08 -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 225618ef75 Add stall in firstboot for deployer to be available 2021-08-09 15:19:36 -04:00