2
0
mirror of https://github.com/xcat2/xcat-core.git synced 2026-11-19 17:02:15 +00:00
Commit Graph

63 Commits

Author SHA1 Message Date
Daniel Hilst 9804168ca9 Merge upstream master into feat/ipv6
Integration test of the 51 commits that landed on upstream master after this
branch was built. Four conflicts, all from edits to the same lines:

perl-XCAT/xCAT/BootUtils.pm: both sides add a new sub at the end of the file.
Master adds expand_node_template, this branch adds grub2_kernel_commands and
grub2_image_provides. All three are kept.

xCAT/xCAT.spec and xCATsn/xCATsn.spec: master wraps the chrony and dhcpd
requirements in a suse_version test, and its %endif lands on the line this
branch uses for radvd. The requirement stays outside the test, because an
openSUSE management node writes radvd.conf too.

xCAT-server/xCAT-server.spec: master's openSUSE requirement list is a superset
of this branch's, so master's is taken whole.

Signed-off-by: Daniel Hilst <392820+dhilst@users.noreply.github.com>
2026-10-31 08:55:22 -03:00
Daniel Hilst ac0ec70821 Merge pull request #7979 from VersatusHPC/refactor/debian-profile-lookup
refactor(netboot): share profile asset selection
2026-10-29 14:58:18 -03:00
Daniel Hilst d73343b198 fix(packaging): the openSUSE IPv6 module gap needs a requires, not a hard dependency
The previous commit required Socket6 and IO::Socket::INET6 on every RPM family. That
is wrong for EL and openEuler, where dnf installs a recommended package and the
existing Recommends already delivers both modules.

The gap is openSUSE only, and it has two parts. xCAT-server recommends both modules
inside a guard that names fedora, rhel and openEuler and omits suse_version, so an
openSUSE build declares neither a requires nor a recommends. perl-xCAT declares nothing
at all, although xCAT::SLP, xCAT::Client and xCAT::NetworkUtils all reach IPv6 through
these modules. A recommendation would not close it either: the openSUSE Minimal-VM
image sets solver.onlyRequires = true, so zypper installs no recommended package, which
is why xCAT already names a DHCP server directly.

Both specs now require both modules on openSUSE and recommend them on the families
whose package manager honours a weak dependency. The xCAT-server deb returns to a
Recommends.

Signed-off-by: Daniel Hilst <392820+dhilst@users.noreply.github.com>
2026-10-29 09:05:15 -03:00
Daniel Hilst bf3a2f066b fix(packaging): SLP discovery and IPMI over IPv6 are off on an openSUSE node
Socket6 and IO::Socket::INET6 are absent on a Leap 15.6 management node that carries
every other xCAT dependency, so $ip6support in xCAT::SLP and $doipv6 in xCAT::IPMI
evaluate to 0. SLP discovery and IPMI over IPv6 then do nothing and report no error.

Both packages exist: perl-Socket6 and perl-IO-Socket-INET6 are in the openSUSE main
repository and in the EL appstream repository. Nothing asked for them. perl-generators
reads a use statement, and every caller uses eval { require ... }, so the EL build
derives no perl(Socket6) either. xCAT-server named the deb packages as Recommends,
which apt 3.0 solver3 drops when it cannot place them.

perl-xCAT and xCAT-server now require both modules on every RPM family, and the
xCAT-server deb moves them from Recommends to Depends.

Captured by xCAT-test/unit/ipv6_socket_modules_declared.t, which fails 16 of its 20
assertions without this change.

Signed-off-by: Daniel Hilst <392820+dhilst@users.noreply.github.com>
2026-10-29 08:52:27 -03:00
Vinícius Ferrão 447db00a81 fix(netboot): keep profile helpers with shared image utilities
Shared image utilities must not require the Debian source directory.

Keep the profile helper beside imgutils and materialize the Debian copy
when building RPM and DEB packages. Source-only Debian copies must follow
symlinks; installed Debian directories stay self-contained.
2026-10-26 18:29:45 -03:00
Daniel Hilst 3124c9e756 fix(ipv6): the Socket6 dependency contradicts the code that loads it
Every caller of Socket6 and IO::Socket::INET6 loads it with an eval and keeps
working on IPv4 when the load fails. NetworkUtils carries a second resolver
path on core Socket for exactly that case. xCAT-server.spec and
xCAT-server/debian/control named both modules as a hard dependency, which
states a dependency the code does not have and stops xCAT installing where
the modules are missing.

Declare both as Recommends in the spec and in debian/control. A package
manager installs a recommendation by default, so a management node still gets
them. Both are in EL AppStream and in openEuler 24.03 everything, measured
from its primary.xml.

The family cache block in networkutils_ipv6_helpers.t was guarded on Socket6
and skipped where the unit suite runs, which has no Socket6. The family cache
keys are the same on both resolver paths, so the guard now accepts either
resolver: six more assertions run, and one of them fails when the OnlyV4 and
OnlyV6 cache split is removed.

Signed-off-by: Daniel Hilst <392820+dhilst@users.noreply.github.com>
2026-10-26 15:27:20 -03:00
Vinícius Ferrão f05677d173 feat(ipv6): add EL10 IPv6-only provisioning support
An IPv6-only provisioning network cannot deploy a node. The discovery and
credential callbacks open IPv4 sockets, the kickstart and boot templates
render an IPv4 address into every endpoint, and makehosts drops an IPv6
value because hosts.pm gates on isIpv4addr.

NetworkUtils gains the address helpers the rest of the change uses:
format_host_port, parse_host_port and format_uri_host bracket an IPv6
literal, getNodeNetworkCfg6 reads the static IPv6 configuration of a node,
my_ip_facing_family selects the management-node address of one family,
getIPv6ReverseZone builds a nibble-aligned reverse zone, and
node_is_ipv6_only and ipv6_server_for_node answer the two questions the
plugins used to answer for themselves. credentials.pm opens the callback
socket through IO::Socket::INET6 when the modules are present and keeps the
IPv4 path when they are not. Template.pm and anaconda.pm render an IPv6
kickstart network line and bracketed endpoints. The postscripts and the
stateless xcatroot format every endpoint through the bracketing helpers.

xCAT-server requires perl-IO-Socket-INET6 and perl-Socket6 on EL, and
libio-socket-inet6-perl and libsocket6-perl on Debian.

(cherry picked from commits c0a69bb5a and caa8ca790)
Ported onto upstream master ee6b4f532. The two commits are folded because the
second refactors the first. Master is kept where it has a newer form of the
same thing: the getipaddr cache guard, the Kea control_socket_path helper, the
netboot method list, install_device_params, the modern_installer test and the
isValidIp validator, which replaces the isValidIPAddress this branch added.

Signed-off-by: Daniel Hilst <392820+dhilst@users.noreply.github.com>
(cherry picked from commit 3928c04507)
2026-10-26 15:27:08 -03:00
Vinícius Ferrão 103076c852 fix(debian): skip service actions inside proc-mounted chroots 2026-10-22 17:33:44 -03:00
Daniel Hilst 21a0ad8089 Merge pull request #7962 from VersatusHPC/feat/uftp-rootimg-transport
feat(uftp): distribute stateless root images over UFTP multicast
2026-10-21 15:52:02 -03:00
Vinícius Ferrão 199e4733a7 feat(uftp): add the UFTP transfer listener
Booting nodes need a server that sends a published root image once to
every node that asks for it in a short window.

xcat-uftp-listener accepts HTTP/1.0 GET requests that name an image
path and its digest. It serves only an archive that packimage published
under the configured image roots, for a digest that the checksum file
lists. It keeps the archive open from the first request, so a later
packimage does not change the bytes of a queued batch. It collects the
requests for the same inode, digest and port for batch_delay seconds,
then runs one closed-group uftp session for the batch. Connections,
queued jobs, senders and receivers per job are limited.

The sender gets an argument vector built only from the configuration,
and signs the encrypted session with a persistent server key. It drops a
receiver that misses nearly every block of a section, so one node
without multicast cannot hold the session open. A sender that is not the
UFTP 5 build of xcat-dep is refused.

block_size allows larger packets on jumbo frame networks, up to the
8800-byte limit of uftp.

xCAT::UFTP holds the decisions of the listener: request checks, batches,
limits, timeouts and the runtime check. The script holds the sockets,
the key commands and the sender processes.

The packages install the service but do not enable it. Package removal
stops and disables it.
2026-10-21 11:44:21 -03:00
Vinícius Ferrão 0ad1448564 fix(packaging): remove write access from Debian profile payloads
Group-writable sources leave install and netboot assets writable by other users in the Debian package. Remove group and other write permission from those two staged trees. Preserve executable bits and leave source files and the rest of the payload unchanged.
2026-10-19 19:31:25 -03:00
Vinícius Ferrão cd90878516 refactor(init): share target detection and pending-state cleanup
Signed-off-by: Vinícius Ferrão <2031761+viniciusferrao@users.noreply.github.com>
2026-10-11 11:46:10 -03:00
Vinícius Ferrão a7bd3fb631 fix(debian): declare libcgi-pm-perl for the REST API
xcat-server ships xcatws.cgi and restapi.pl with the endpoint enabled in
apache, and both load CGI at top level. Nothing declared the module, so on
a management node where nothing else pulled it every /xcatws request
answered 500. The rpm package requires perl(CGI).

Signed-off-by: Vinícius Ferrão <2031761+viniciusferrao@users.noreply.github.com>
2026-09-09 11:54:16 -03:00
Vinícius Ferrão 53692323b4 fix(xCAT-server): declare the tool copycd builds the riscv64 loader with
copycd builds the riscv64 boot loader by running grub-mkimage, which
grub-common ships on every supported Ubuntu release. Nothing declared it, so a
management or service node installed without that package copies riscv64 media
and produces no loader, while DHCP keeps pointing every riscv64 node at the path
where the loader should be.

The declaration belongs to xcat-server, which carries the plugin that runs the
command, so both metapackages inherit it.

Signed-off-by: Vinícius Ferrão <2031761+viniciusferrao@users.noreply.github.com>
2026-09-08 22:01:32 -03:00
Vinícius Ferrão 036bb24c87 fix(packaging): preserve xcatd init state on Debian (#7615)
* refactor(packaging): share precise systemd state detection

* test(packaging): cover precise systemd state detection

* test(packaging): allow explicit Debian init mode

* fix(packaging): honor explicit Debian init targets

* test(packaging): cover Debian init target detection

* fix(packaging): add Debian xcatd init state helper

* test(packaging): cover Debian xcatd init state helper

* test(packaging): allow delegated SysV registration

* fix(packaging): preserve Debian xcatd conffile lifecycle

* test(packaging): mirror explicit Debian init mode

* test(packaging): cover Debian xcatd conffile lifecycle

* fix(packaging): contain init state file umask

* test(packaging): cover init state permissions

* fix(packaging): contain preinstall context umask

* test(packaging): cover preinstall umask containment

* fix(packaging): detect all systemd enablement links

* test(packaging): cover all systemd enablement links

* test(packaging): allow shared purge state path

* refactor(packaging): reuse Debian init state path

* fix(packaging): detect runtime systemd masks

* test(packaging): cover runtime systemd masks

* test(packaging): model Debian SysV registration

* refactor(packaging): reuse shared init state detection

* test(packaging): enforce shared Debian state probes

* test(packaging): allow explicit unregistered masks

* fix(packaging): preserve Debian SysV registration state

* test(packaging): cover Debian SysV registration states

* fix(packaging): clean failed Debian state writes

* test(packaging): cover failed Debian state writes

* fix(packaging): retain unregistered systemd provenance

* test(packaging): cover unregistered systemd upgrades

* fix(packaging): fail closed on shared state errors

* test(packaging): cover shared state detector failures

* test(packaging): mirror native xcatd runlevels

* fix(packaging): recover rejected SysV layouts

* test(packaging): cover rejected SysV layouts

* test(packaging): cover SysV rebuild retries

* refactor(packaging): reuse systemctl readiness guard

* test(packaging): enforce shared systemctl guard
2026-07-28 19:31:36 +00:00
Vinícius Ferrão 6a3f71bf68 fix(packaging): avoid SysV init paths in modern DEBs 2026-07-16 01:43:16 -03:00
Vinícius Ferrão 7897f30bfe Modernize xcatd service packaging 2026-05-04 18:13:23 -03:00
GONG Jie 15f1c37152 Update grub2-xcat requirement 2019-05-16 17:17:09 +08:00
GONG Jie 4c7ae57111 Remove trailing spaces in file xCAT-server/debian/postrm 2017-12-31 23:59:59 +00:00
GONG Jie 584d12bfd0 Remove trailing spaces in file xCAT-server/debian/copyright 2017-12-31 23:59:59 +00:00
Bin Xu 57bc7c1f57 Add a default systemd unit file based on the auto-generated one from SysV (#5394)
* Add a default systemd unit file based on the auto-generated one from SysV

* modify the xcatd testcase when using systemd
2018-07-23 17:31:50 +08:00
chenglch 2ac315cbe2 Add default logrotate configuration for gocons
Add logrotate conf for the console log files and log
of goconserver.
2018-03-27 17:11:25 +08:00
neo954 327db76f9e Make all the deb packages have the exactly same version and release numbers 2017-01-03 12:56:15 +08:00
ertaozh 52a995f810 add depended pkg http-async and net-https-nb for xCAT-server 2016-03-23 01:24:05 -04:00
WangXiaoPeng 7444165c19 defect 4756: Add switch mgmt cfg for Ubuntu
We added some configuration files for xdsh to run switch management
control. But all the configuration files were not checked in for
Ubuntu. This fix is to add them for Ubuntu.
2015-07-22 23:39:58 -04:00
Victor Hu 78a6d8e39e Revert "For Ubuntu builds, adding a .gitignore to ignore the files generated"
This reverts commit 829f107beb.
2015-06-15 17:32:34 -04:00
Victor Hu 829f107beb For Ubuntu builds, adding a .gitignore to ignore the files generated
from the builds.  Also remove the changelog because that file is going
to be ignored from the source tree.  Ubuntu builds are being done
in the xcat-core directory and causing issues when we are switching
between releases.    Should probably change the builds scripts as a longer
term solution
2015-06-15 17:14:05 -04:00
WangXiaoPeng aa7765accf defect 4625: fix the issue that restapi does not work on Ubuntu 2015-03-26 07:15:33 -04:00
WangXiaoPeng f02a5e927d defect 4625: create necessary dirs for apache2 cfg 2015-03-26 07:15:15 -04:00
Victor Hu f8bd32838a Change the debian/rules file to executable to supress
a warning during the build.  The rules file is required to have
execute permission as it's the debian "Makefile"
2015-03-25 17:42:51 -04:00
immarvin 9d628fb636 fix defect #4155 [fvt]2.9:could not install xcat use the latest build for no perl(Confluent::Client) 2014-09-15 21:00:26 -07:00
immarvin 83ed138db2 fix defect #4155 [fvt]2.9:could not install xcat use the latest build for no perl(Confluent::Client) 2014-09-15 03:04:57 -07:00
immarvin 7f8b48ba40 fix defect #4155 [fvt]2.9:could not install xcat use the latest build for no perl(Confluent::Client) 2014-09-15 02:50:34 -07:00
immarvin d0585fe056 fix defect #4155 [fvt]2.9:could not install xcat use the latest build for no perl(Confluent::Client) 2014-09-15 02:41:51 -07:00
zhaoertao a68140b3b9 fix a bug about putting mypostscripts for ubuntu 2014-07-13 21:52:57 -07:00
zhaoertao 8c296f2257 supporting of build xcat-core for ppc64el 2014-07-04 00:14:11 -07:00
immarvin 8756aa4cd8 add a new ubuntu dependency libcrypt-cbc-perl 2014-04-28 00:23:45 -07:00
immarvin 694b3eac6c add dependency libcrypt-rijndael-perl for ubuntu 2014-04-27 20:42:39 -07:00
immarvin 36c2404d1c add grub2-xcat as a dependency to enable provisioning rhel7 on an ubuntu MN 2014-03-25 01:17:24 -07:00
xq2005 7abd27fbfe put mypostscript.tmpl under /opt/xcat/share/xcat/templates/mypostscript 2013-12-02 00:10:47 -08:00
xq2005 3b1333d88f fix the postinst script for xcat-server on ubuntu 2013-09-10 02:24:18 -07:00
xq2005 9800265c12 start the xcatd on ubuntu/debian when system booting 2013-08-02 01:46:26 -07:00
xq2005 5263081254 ubuntu and debian ship SHA.pm instand of SHA1.pm
git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@16914 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd
2013-07-09 07:21:49 +00:00
xq2005 28d9fdd2aa change the Maintainer to xCAT when building packages on ubuntu
git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@16760 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd
2013-06-26 07:34:47 +00:00
xq2005 eee22d9c39 find SHA.pm in /usr/lib/perl on ubuntu/debian
git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@16729 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd
2013-06-24 07:36:06 +00:00
xq2005 e5a4cc7075 fix the SHA1.pm miss problem on ubuntu
git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@16037 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd
2013-04-23 02:30:55 +00:00
xq2005 002b2ec9df build xCAT-server on debian/ubuntu
git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@15383 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd
2013-03-05 05:36:29 +00:00
xq2005 1acb9398d6 only create the link to sha.pm after installation on ubuntu/debian
git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@15194 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd
2013-02-16 07:53:19 +00:00
xq2005 f4a553d085 debian default run level is 2, add catd to init.d
git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@14904 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd
2013-01-17 03:10:34 +00:00
xq2005 10804f4c3b ib config script move to xCAT-server/share/xcat/devicetype/IBSwitch
git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@14534 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd
2012-12-04 07:22:34 +00:00