Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

merge the last 2 months of changes accumulated to master into the vtpm branch #4723

Merged
merged 106 commits into from
Jun 8, 2022

Commits on Oct 28, 2021

  1. Add 9pfs backend to vbds

    This allow to use a file path towards a folder instead of a VHD
    
    Signed-off-by: BenjiReis <benjamin.reis@vates.fr>
    Co-authored-by: Ronan Abhamon <ronan.abhamon@vates.fr>
    benjamreis and Wescoeur committed Oct 28, 2021
    Configuration menu
    Copy the full SHA
    2d21000 View commit details
    Browse the repository at this point in the history

Commits on Apr 7, 2022

  1. Sync varstore certificates in XAPI with those on disks

    - `Pool.set_uefi_certificates` is implemented and writes the certificates
    on all its hosts' disks
    
    - `Host.set_uefi_certificates` is now deprecated and transmit the call to the pool method
    - `Host.uefi_certificates` is deprecated as well as it's getter, the value is not updated.
    
    - On XAPI startup certificates stored in XAPI's `Pool.uefi_certificates`
    are written on disks
    
    - When a host joins the pool's certificates are written on its disk.
    
    This means:
    	- At every XAPI startup the certificates in host disks are synced with
    XAPI's `Pool.uefi_certificates`
    
    	- When `Pool.set_uefi_certificates` is called all hosts are synced on their disks
    with XAPI's `Pool.uefi_certificates`.
    
    Also: `Host.set_uefi_certificates` calls should be replaced by `Pool.set_uefi_certificates`, this requires changes
    in external libs (varstored, uefistored, etc) to set the pool's certificates: call `Pool.set_uefi_certificates`.
    
    See: xapi-project#4647
    
    Signed-off-by: BenjiReis <benjamin.reis@vates.fr>
    benjamreis committed Apr 7, 2022
    Configuration menu
    Copy the full SHA
    53d656b View commit details
    Browse the repository at this point in the history

Commits on Apr 8, 2022

  1. CP-35846: Restrict access to internal yum repo server (members only)

    This restricts the /repository endpoint to local-root only. This
    endpoint is exposed only on the coordinator, and used by other pool
    members to access the pool's yum repo mirror.
    
    Yum calls to this endpoint now require a pool secret to be used in a
    cookie, which is implemented through a yum plugin.
    
    Signed-off-by: Rob Hoes <rob.hoes@citrix.com>
    robhoes committed Apr 8, 2022
    Configuration menu
    Copy the full SHA
    d951478 View commit details
    Browse the repository at this point in the history
  2. Merge pull request xapi-project#4672 from robhoes/yumauth

    CP-35846: Restrict access to internal yum repo server (members only)
    robhoes committed Apr 8, 2022
    Configuration menu
    Copy the full SHA
    50ec142 View commit details
    Browse the repository at this point in the history
  3. CA-364138 XSI-1217: fix FD leak, Unix.EMFILE

    Close both FDs.
    
    Signed-off-by: Christian Lindig <christian.lindig@citrix.com>
    lindig committed Apr 8, 2022
    Configuration menu
    Copy the full SHA
    703b967 View commit details
    Browse the repository at this point in the history
  4. CA-366014: factor out dm_flags

    Signed-off-by: Edwin Török <edvin.torok@citrix.com>
    edwintorok committed Apr 8, 2022
    Configuration menu
    Copy the full SHA
    c12905c View commit details
    Browse the repository at this point in the history
  5. CA-366014: pass -dm qemu to UEFI qemu too

    emu-manager needs '-dm qemu' flag for migration to work correctly with
    upstream QEMU.
    Otherwise emu-manager doesn't send xen-set-global-dirty-log and some
    guest drivers may crash upon resume (e.g. the mouse).
    
    Treat Qemu_upstream_uefi as upstream too and pass the flag.
    
    Commit 0e8624a introduced '-dm qemu'
    but the UEFI version of the qemu profile didn't exist yet at the time.
    
    Later commit 971d788 introduced the
    UEFI qemu profile, and the build still worked due to the wildcard,
    so the missing flag went unnoticed until now.
    
    Replace the wildcard with an explicit list of when '-dm qemu' shouldn't
    be added, so the next time we introduce a new qemu profile we get a
    build failure and must decide which behaviour would be correct.
    
    Signed-off-by: Edwin Török <edvin.torok@citrix.com>
    edwintorok committed Apr 8, 2022
    Configuration menu
    Copy the full SHA
    5f33eb2 View commit details
    Browse the repository at this point in the history
  6. CA-366014: drop unused Profile.all

    It is unused and incomplete (it lacks UEFI).
    Drop it to avoid confusion.
    
    Signed-off-by: Edwin Török <edvin.torok@citrix.com>
    edwintorok committed Apr 8, 2022
    Configuration menu
    Copy the full SHA
    ec2f3c0 View commit details
    Browse the repository at this point in the history

Commits on Apr 11, 2022

  1. CA-364138 XSI-1217: log number of FDs in use

    After starting a new server (for a varstored), report the number of open
    file descriptors in the log.
    
    Signed-off-by: Christian Lindig <christian.lindig@citrix.com>
    lindig committed Apr 11, 2022
    Configuration menu
    Copy the full SHA
    a4b7d64 View commit details
    Browse the repository at this point in the history
  2. CP-39551: avoid warnings in xapi-cli-server

    There were a lot of warnings here, mostly missing named parameters,
    quite a few of these were able to be automated using sed to add tildes,
    others couldn't because of how irregular the name of the parameters
    are, sometimes using self, sometimes the type of object; or they were
    too particular.
    
    There we also unused bindings which allowed for removal of parameters.
    
    Signed-off-by: Pau Ruiz Safont <pau.safont@citrix.com>
    psafont committed Apr 11, 2022
    Configuration menu
    Copy the full SHA
    78a83cd View commit details
    Browse the repository at this point in the history
  3. Merge pull request xapi-project#4675 from lindig/private/christianlin…

    …/CA-364138
    
     CA-364138 XSI-1217: fix FD leak, Unix.EMFILE
    lindig committed Apr 11, 2022
    Configuration menu
    Copy the full SHA
    2f5abb7 View commit details
    Browse the repository at this point in the history
  4. CP-39551: avoid warnings in xenopsd/xc

    These were mostly about removing unused code and removing usages of
    xenstore and xenctrl handles which allows avoiding opening them in quite
    a few places.
    
    I would not have expected the code around PCI devices to be unused, I
    wonder if it should actually be used.
    
    Signed-off-by: Pau Ruiz Safont <pau.safont@citrix.com>
    psafont committed Apr 11, 2022
    Configuration menu
    Copy the full SHA
    212ce66 View commit details
    Browse the repository at this point in the history
  5. ci: adjust the warning gate

    Signed-off-by: Pau Ruiz Safont <pau.safont@citrix.com>
    psafont committed Apr 11, 2022
    Configuration menu
    Copy the full SHA
    edcaf3d View commit details
    Browse the repository at this point in the history

Commits on Apr 12, 2022

  1. maintenance: ignore reformatting commits in git blame

    Signed-off-by: Pau Ruiz Safont <pau.safont@citrix.com>
    psafont committed Apr 12, 2022
    Configuration menu
    Copy the full SHA
    3753f8f View commit details
    Browse the repository at this point in the history

Commits on Apr 13, 2022

  1. Merge pull request xapi-project#4682 from psafont/private/paus/ignore…

    …-reformats
    
    maintenance: ignore reformatting commits in git blame
    edwintorok committed Apr 13, 2022
    Configuration menu
    Copy the full SHA
    042cec4 View commit details
    Browse the repository at this point in the history
  2. Merge pull request xapi-project#4679 from psafont/private/paus/warnings

    CP-39551: avoid warnings in xapi-cli-server and xenopsd/xc
    edwintorok committed Apr 13, 2022
    Configuration menu
    Copy the full SHA
    4cf52b9 View commit details
    Browse the repository at this point in the history
  3. Merge pull request xapi-project#4659 from xcp-ng/synch-varstored-betw…

    …een-hosts
    
    Sync varstore certificates in XAPI with those on disks
    edwintorok committed Apr 13, 2022
    Configuration menu
    Copy the full SHA
    85fdc21 View commit details
    Browse the repository at this point in the history
  4. Merge pull request xapi-project#4561 from xcp-ng/add_9pfs_backend

    Add `9pfs` backend to vbds
    edwintorok committed Apr 13, 2022
    Configuration menu
    Copy the full SHA
    5ca8c6c View commit details
    Browse the repository at this point in the history
  5. CP-39551: avoid warnings in xenopsd/xc

    Signed-off-by: Pau Ruiz Safont <pau.safont@citrix.com>
    psafont committed Apr 13, 2022
    Configuration menu
    Copy the full SHA
    a0e24f1 View commit details
    Browse the repository at this point in the history
  6. CP-39551: remove unused cases of variants in libs

    Signed-off-by: Pau Ruiz Safont <pau.safont@citrix.com>
    psafont committed Apr 13, 2022
    Configuration menu
    Copy the full SHA
    4369569 View commit details
    Browse the repository at this point in the history
  7. ci: adjust error / warning gate

    Signed-off-by: Pau Ruiz Safont <pau.safont@citrix.com>
    psafont committed Apr 13, 2022
    Configuration menu
    Copy the full SHA
    3804ba9 View commit details
    Browse the repository at this point in the history
  8. Merge pull request xapi-project#4683 from psafont/ci-gate

    CP-39551: avoid warnings in xenopsd/xc and libs
    psafont committed Apr 13, 2022
    Configuration menu
    Copy the full SHA
    6a5b3c7 View commit details
    Browse the repository at this point in the history

Commits on Apr 14, 2022

  1. fixes regarding DNS management in IPv6:

    Issues:
    - DNS is not set when configuring an IPv6
    - When a DNS is set all dns entries are overriden, this is problematic when using both IPv4 and IPv6 in the same PIF.
    
    Fixes:
    - set DNS when an IPv6 is configured
    - only overrides DNS entries of the same family when an IP/IPv6 is configured
    - 'determine_gateway_and_dns_ifs' also look for 'ipv6_configuration_mode' to find possible gateway and dns pifs
    
    Signed-off-by: BenjiReis <benjamin.reis@vates.fr>
    benjamreis committed Apr 14, 2022
    Configuration menu
    Copy the full SHA
    a36426d View commit details
    Browse the repository at this point in the history
  2. Merge pull request xapi-project#4303 from xcp-ng/add-ipv6-dns

    fixes regarding DNS management
    psafont committed Apr 14, 2022
    Configuration menu
    Copy the full SHA
    47a7074 View commit details
    Browse the repository at this point in the history
  3. CP-39551: avoid warnings in xapi

    Signed-off-by: Pau Ruiz Safont <pau.safont@citrix.com>
    psafont committed Apr 14, 2022
    Configuration menu
    Copy the full SHA
    8aaa7d6 View commit details
    Browse the repository at this point in the history
  4. CP-39551: avoid warnings from PR xapi-project#4659

    Signed-off-by: Pau Ruiz Safont <pau.safont@citrix.com>
    psafont committed Apr 14, 2022
    Configuration menu
    Copy the full SHA
    9a52bfc View commit details
    Browse the repository at this point in the history
  5. ci: activate make check now that there no warnings are emitted

    Signed-off-by: Pau Ruiz Safont <pau.safont@citrix.com>
    psafont committed Apr 14, 2022
    Configuration menu
    Copy the full SHA
    6d5b2b9 View commit details
    Browse the repository at this point in the history
  6. Add binary xapi_gzip for testing Xapi_compression

    The compression library Xapi_compression spawns processes to compress
    and uncompress streams. To facilitate easier testing, add a small
    stand-alone filter that compresses or uncompresses its standard input.
    This filter requires the presence of forkexecd to work - so typically a
    Citrix Hypervisor installation. We don't install this binary but it is
    available for developers.
    
    Signed-off-by: Christian Lindig <christian.lindig@citrix.com>
    lindig committed Apr 14, 2022
    Configuration menu
    Copy the full SHA
    95d15e9 View commit details
    Browse the repository at this point in the history

Commits on Apr 18, 2022

  1. Add temporary feature 'Internal_repo_access' to allow update in mix mode

    In commit d951478, a new function was added to restrict the repository
    access to pool members only. With this funciton, the pool members need
    to use pool_secret in access requests to the mirrorred repositories on
    the pool coordinator for authentication.
    
    But in updating, this would cause the pool members can't access the
    mirrored repositories as at that time the pool coordinator has been
    updated to check the pool_secret while the pool members have not been
    udpated to use pool_secret.
    
    Per suggestion from Rob Hoes, this commit adds a temporary feature flag
    to make the pool coordinator be able to distinguish the case in the
    mixed mode in updating.
    
    Signed-off-by: Ming Lu <ming.lu@citrix.com>
    minglumlu committed Apr 18, 2022
    Configuration menu
    Copy the full SHA
    aa970ed View commit details
    Browse the repository at this point in the history

Commits on Apr 19, 2022

  1. ci: fix testing of xapi-xenstored in newer opam's sandboxes

    xs-opam's CI is the only environment where /tmp is not writable and
    XDG_RUNTIME_DIR is not set. Using TMPDIR with /tmp as a backup will mean
    the socket is writeable in all environments
    
    Signed-off-by: Pau Ruiz Safont <pau.safont@citrix.com>
    psafont committed Apr 19, 2022
    Configuration menu
    Copy the full SHA
    3eb74f9 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    a285883 View commit details
    Browse the repository at this point in the history
  3. Merge pull request xapi-project#4687 from minglumlu/private/mingl/int…

    …ernal_repo_access
    
    Add temporary feature 'Internal_repo_access' to allow update in mix mode
    robhoes committed Apr 19, 2022
    Configuration menu
    Copy the full SHA
    55cd1f9 View commit details
    Browse the repository at this point in the history

Commits on Apr 20, 2022

  1. Merge pull request xapi-project#4685 from lindig/master

    Add binary xapi_gzip for testing Xapi_compression
    lindig committed Apr 20, 2022
    Configuration menu
    Copy the full SHA
    441cc4e View commit details
    Browse the repository at this point in the history
  2. CA-366430: do not wipe PK.auth/dbx.auth

    These files are owned by other RPM packages.
    Also upgrade would need to be taken into consideration where
    uefi-certificates would already be set on a pool, but just with KEK+db
    without PK+dbx.
    In that case if we order uploading PK/dbx and restart xapi the wrong way
    around we may get these files wiped completely from the system.
    Wiping just KEK+db should be enough to ensure we don't have stale files
    around.
    
    Signed-off-by: Edwin Török <edvin.torok@citrix.com>
    edwintorok committed Apr 20, 2022
    Configuration menu
    Copy the full SHA
    d7f15f2 View commit details
    Browse the repository at this point in the history
  3. Merge pull request xapi-project#4689 from xapi-project/private/edvint…

    …/pkauth
    
    CA-366430: do not wipe PK.auth/dbx.auth
    robhoes committed Apr 20, 2022
    Configuration menu
    Copy the full SHA
    3417a49 View commit details
    Browse the repository at this point in the history

Commits on Apr 22, 2022

  1. Don't use --force in gzip decompress

    Normally gzip stops reading input when it has reached its own end-of
    input marker even when that is before the end of input. This is
    overridden by --force for decompression and it is creating a problem for
    us because suspend images on disk are represented as devices that are
    larger than the actual content - so --force kept reading beyond the
    actual input and this in turn was not accepted by the code taking the
    uncompressed output.
    
    Signed-off-by: Christian Lindig <christian.lindig@citrix.com>
    lindig committed Apr 22, 2022
    Configuration menu
    Copy the full SHA
    ab7dd15 View commit details
    Browse the repository at this point in the history
  2. Merge pull request xapi-project#4684 from psafont/private/paus/warnings

    CP-39551: Remove all compiler warnings (finally!)
    robhoes committed Apr 22, 2022
    Configuration menu
    Copy the full SHA
    fa6f118 View commit details
    Browse the repository at this point in the history
  3. CP-34028: add unit tests for UUID

    Also adds a pretty_printer and an equal function
    
    Signed-off-by: Pau Ruiz Safont <pau.safont@citrix.com>
    psafont committed Apr 22, 2022
    Configuration menu
    Copy the full SHA
    56656dd View commit details
    Browse the repository at this point in the history
  4. CP-34028: Stop accepting all input as valid UUIDs

    Change signature functions that generate UUIDs from inputs to return a
    UUID as an option. They now transform the input to make sure the
    resulting string is a valid UUID.
    
    Signed-off-by: Pau Ruiz Safont <pau.safont@citrix.com>
    psafont committed Apr 22, 2022
    Configuration menu
    Copy the full SHA
    e9a83da View commit details
    Browse the repository at this point in the history
  5. chore: properly deprecate methods

    Also reorganized the functions and signatures to group similar
    functionality together.
    
    Signed-off-by: Pau Ruiz Safont <pau.safont@citrix.com>
    psafont committed Apr 22, 2022
    Configuration menu
    Copy the full SHA
    1ef7e36 View commit details
    Browse the repository at this point in the history
  6. CP-34028: Implement Uuid using Uuidm

    Signed-off-by: Pau Ruiz Safont <pau.safont@citrix.com>
    psafont committed Apr 22, 2022
    Configuration menu
    Copy the full SHA
    d3f9bf2 View commit details
    Browse the repository at this point in the history
  7. CP-34028: add {to,from}_bytes to uuid

    It's useful to extract uuid from hashed bytes
    
    Signed-off-by: Pau Ruiz Safont <pau.safont@citrix.com>
    psafont committed Apr 22, 2022
    Configuration menu
    Copy the full SHA
    f149711 View commit details
    Browse the repository at this point in the history
  8. CP-34028: adapt code for new uuid interface

    Signed-off-by: Pau Ruiz Safont <pau.safont@citrix.com>
    psafont committed Apr 22, 2022
    Configuration menu
    Copy the full SHA
    9b97d87 View commit details
    Browse the repository at this point in the history
  9. CP-34028: Use /dev/urandom as the only uuid source

    Compared to /dev/random uses the same CSPRNG (since Linux 4.8) and it
    doesn't block
    
    OCaml's PRNG is not a CSPRNG as it is predictable
    
    Signed-off-by: Pau Ruiz Safont <pau.safont@citrix.com>
    psafont committed Apr 22, 2022
    Configuration menu
    Copy the full SHA
    24b4f18 View commit details
    Browse the repository at this point in the history
  10. CP-34028: Replace make_uuid with make

    Signed-off-by: Pau Ruiz Safont <pau.safont@citrix.com>
    psafont committed Apr 22, 2022
    Configuration menu
    Copy the full SHA
    c7e38b8 View commit details
    Browse the repository at this point in the history
  11. CP-34028: Replace Uuidm with Uuid wherever possible

    Now the only modules where Uuidm is used is inside Uuid, and in
    varstoredguard's RPC. This is to avoid using GADTs for little benefit
    
    Signed-off-by: Pau Ruiz Safont <pau.safont@citrix.com>
    psafont committed Apr 22, 2022
    Configuration menu
    Copy the full SHA
    0398ffb View commit details
    Browse the repository at this point in the history
  12. maintenance: use compact tests globally

    Now all alcotest binaries are executed in compact mode when running make
    test. This allows the developers to run the tests with dune runtest
    --profile=debug to see all the output of test if they wish to.
    
    Signed-off-by: Pau Ruiz Safont <pau.safont@citrix.com>
    psafont committed Apr 22, 2022
    Configuration menu
    Copy the full SHA
    a36d6a4 View commit details
    Browse the repository at this point in the history

Commits on Apr 24, 2022

  1. CP-32574: Refine code to separate merge_updates function out

    Signed-off-by: Ming Lu <ming.lu@citrix.com>
    minglumlu committed Apr 24, 2022
    Configuration menu
    Copy the full SHA
    a0ca80d View commit details
    Browse the repository at this point in the history
  2. CP-32574: Split code into more files

    This commit doesn't change any code. It only move some codes to a few
    new files so that they could be used more easily later.
    
    Signed-off-by: Ming Lu <ming.lu@citrix.com>
    minglumlu committed Apr 24, 2022
    Configuration menu
    Copy the full SHA
    d9b4a15 View commit details
    Browse the repository at this point in the history
  3. CP-32574: Add new modules to support livepatch

    Signed-off-by: Ming Lu <ming.lu@citrix.com>
    minglumlu committed Apr 24, 2022
    Configuration menu
    Copy the full SHA
    e49438a View commit details
    Browse the repository at this point in the history
  4. CP-32574: Return applied_livepatches from getting host updates

    Signed-off-by: Ming Lu <ming.lu@citrix.com>
    minglumlu committed Apr 24, 2022
    Configuration menu
    Copy the full SHA
    a878676 View commit details
    Browse the repository at this point in the history
  5. CP-32574: Calculate up-to-date flag with considering un-applied livep…

    …atches
    
    Signed-off-by: Ming Lu <ming.lu@citrix.com>
    minglumlu committed Apr 24, 2022
    Configuration menu
    Copy the full SHA
    c081442 View commit details
    Browse the repository at this point in the history
  6. CP-32574: Consolidate with considertation on livepatches

    Signed-off-by: Ming Lu <ming.lu@citrix.com>
    minglumlu committed Apr 24, 2022
    Configuration menu
    Copy the full SHA
    bd39dd0 View commit details
    Browse the repository at this point in the history
  7. Split functions out of set_available_updates

    Signed-off-by: Ming Lu <ming.lu@citrix.com>
    minglumlu committed Apr 24, 2022
    Configuration menu
    Copy the full SHA
    301247e View commit details
    Browse the repository at this point in the history
  8. Refine names of variables related with update ID

    Signed-off-by: Ming Lu <ming.lu@citrix.com>
    minglumlu committed Apr 24, 2022
    Configuration menu
    Copy the full SHA
    fe0634c View commit details
    Browse the repository at this point in the history
  9. Fixup: Reverse the bool value if RPM package updates available

    This commit fixes the bug introduced in c081442:
    prior to c081442, the bool value is for [up_to_date], while after the
    commit, it is for [pkg_updates_available].
    If there is(are) RPM package updates, it means a host is NOT up to date.
    
    This commit is just for this bug.
    
    Signed-off-by: Ming Lu <ming.lu@citrix.com>
    minglumlu committed Apr 24, 2022
    Configuration menu
    Copy the full SHA
    8017dcf View commit details
    Browse the repository at this point in the history
  10. Fixup: Unused open, variables and functions

    Signed-off-by: Ming Lu <ming.lu@citrix.com>
    minglumlu committed Apr 24, 2022
    Configuration menu
    Copy the full SHA
    de7c897 View commit details
    Browse the repository at this point in the history

Commits on Apr 25, 2022

  1. Merge pull request xapi-project#4678 from minglumlu/private/mingl/CP-…

    …32574
    
    Support livepatch - part 1
    minglumlu committed Apr 25, 2022
    Configuration menu
    Copy the full SHA
    e0d286f View commit details
    Browse the repository at this point in the history

Commits on Apr 26, 2022

  1. Merge pull request xapi-project#4676 from edwintorok/private/edvint/u…

    …efi-qemu
    
    CA-366014: avoid qemu device state issues during migration in UEFI mode
    robhoes committed Apr 26, 2022
    Configuration menu
    Copy the full SHA
    2386d7a View commit details
    Browse the repository at this point in the history
  2. Merge pull request xapi-project#4691 from lindig/private/christianlin…

    …/gzip
    
    Don't use --force in gzip decompress
    lindig committed Apr 26, 2022
    Configuration menu
    Copy the full SHA
    af4fc08 View commit details
    Browse the repository at this point in the history

Commits on Apr 27, 2022

  1. Merge pull request xapi-project#4532 from psafont/reuuid

    CP-34028: implement Uuid with Uuidm
    psafont committed Apr 27, 2022
    Configuration menu
    Copy the full SHA
    2c19fa7 View commit details
    Browse the repository at this point in the history
  2. maintenance: make xapi-xenops-tests more granular

    In practice means single values don't block others values from being
    tested. Using alcotest failures make test failures easier to read and
    reason about.
    
    Signed-off-by: Pau Ruiz Safont <pau.safont@citrix.com>
    psafont committed Apr 27, 2022
    Configuration menu
    Copy the full SHA
    ed0dc8c View commit details
    Browse the repository at this point in the history
  3. maintenance: move tests for platformdata together

    This makes it easier to locate which parts of it are tested and to what
    extent.
    
    Signed-off-by: Pau Ruiz Safont <pau.safont@citrix.com>
    psafont committed Apr 27, 2022
    Configuration menu
    Copy the full SHA
    4a219b8 View commit details
    Browse the repository at this point in the history
  4. CA-366098: Raise internal xenopsd error on task timeout

    Previously the task was reported as cancelled, which was nonsensical and
    made triaging issues harder than necessary. Instead report an internal
    error as this is not expected. The task is still cancelled to make it
    disappear.
    
    The internal wait method has been changed to be able to return relevant
    information about the event captured, allowing to not just return a
    boolean if desired. This is useful to retrieve information about tasks
    just once instead of losing the information and making callers retrieve
    again the information which makes the code flow difficult to navigate
    and understand.
    
    Signed-off-by: Pau Ruiz Safont <pau.safont@citrix.com>
    psafont committed Apr 27, 2022
    Configuration menu
    Copy the full SHA
    77f3dee View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    b85c41e View commit details
    Browse the repository at this point in the history

Commits on May 10, 2022

  1. libs/uuid: run tests only in the uuid package

    Signed-off-by: Pau Ruiz Safont <pau.safont@citrix.com>
    psafont committed May 10, 2022
    Configuration menu
    Copy the full SHA
    58d0083 View commit details
    Browse the repository at this point in the history
  2. CP-39805: Avoid deprecated bindings in mtime

    The conversions from and to nanoseconds in floats are going to be
    deprecated in mtime 1.4, avoid using them.
    
    Signed-off-by: Pau Ruiz Safont <pau.safont@citrix.com>
    psafont committed May 10, 2022
    Configuration menu
    Copy the full SHA
    ca9b73f View commit details
    Browse the repository at this point in the history
  3. Datamodel: replace some recent rel_next entries

    Signed-off-by: Rob Hoes <rob.hoes@citrix.com>
    robhoes committed May 10, 2022
    Configuration menu
    Copy the full SHA
    082e187 View commit details
    Browse the repository at this point in the history
  4. Merge pull request xapi-project#4698 from psafont/maintenance

    maintenance: run uuid tests as part of that package
    robhoes committed May 10, 2022
    Configuration menu
    Copy the full SHA
    aae222d View commit details
    Browse the repository at this point in the history
  5. CA-366801: xsh: fix XAPI blob sync and EBADF

    xsh was closing the file descriptor both in the 'proxy' function and in
    the stunnel wrapper code.
    Push down the Unixfd.(!) dereference into the proxy code to make it
    obvious that we have a Unix.close there, and replace that with
    Unixfd.safe_close which avoids double close.
    
    This was causing blob sync to fail in XAPI with an rsync protocol error
    (due to the extra EBADF printed by xsh).
    
    Fixes: c6511f0 "CA-337546: update to new Stunnel_cache API with Safe_resources support"
    
    Signed-off-by: Edwin Török <edvin.torok@citrix.com>
    edwintorok committed May 10, 2022
    Configuration menu
    Copy the full SHA
    11cce30 View commit details
    Browse the repository at this point in the history
  6. Merge pull request xapi-project#4697 from edwintorok/private/edvint/xsh

    xsh: fix XAPI blob sync in pools
    edwintorok committed May 10, 2022
    Configuration menu
    Copy the full SHA
    f25ab57 View commit details
    Browse the repository at this point in the history

Commits on May 13, 2022

  1. Merge pull request xapi-project#4701 from robhoes/master

    Datamodel: replace some recent rel_next entries
    robhoes committed May 13, 2022
    Configuration menu
    Copy the full SHA
    0d0d2a8 View commit details
    Browse the repository at this point in the history

Commits on May 16, 2022

  1. CP-38688 introduce Message.destroy_many() API/CLI call

    The RPC overhead when destroying many messages is high. To avoid it,
    introcuce a message to destroy several messages in one call. This
    introduces a new API call Message.destroy_many. The corresponding CLI
    command message-destroy is extended to accept a parameter "uuids" to
    accept multiple UUIDs in additio to the existing "uuid" parameter.
    
    I notice that destroyig a message by itself is not cheap because it
    parses the XML content of the message being destroyed. In an unlucky
    case it also involves scanning a directory on the file system to remove
    an alias.
    
    Signed-off-by: Christian Lindig <christian.lindig@citrix.com>
    lindig committed May 16, 2022
    Configuration menu
    Copy the full SHA
    923cabd View commit details
    Browse the repository at this point in the history
  2. Upgrade VM runtime state when xenopsd restarts

    This is needed for the case that the type of the backend's internal
    state is extended in a xenopsd update, such that any running VMs have
    the current runtime metadata. Case in point is the recent addition of
    the platformdata key, where the default value (an empty map) is not
    sufficient.
    
    Signed-off-by: Rob Hoes <rob.hoes@citrix.com>
    robhoes committed May 16, 2022
    Configuration menu
    Copy the full SHA
    88405ce View commit details
    Browse the repository at this point in the history

Commits on May 17, 2022

  1. CA-367120: Missing net new RPMs in picking up metadata from updateinfo

    Prior to this fix, "yum updateinfo list updates" was used to get the
    accumulative update RPM package list. The update IDs of these packages
    would be used to pick up associated update metadata from updateinfo.
    And similarly, another command "repoquery -a --pkgnarrow=updates" is
    used to get the RPM packages to be installed in the update.
    
    The outputs of both command lines above, however, don't include the net
    new RPM packages. This causes a bug that the metadata of updates
    associated with these net new RPM packages are missed in constructing
    overall update infomation, especially the update guidance.
    
    The fix is to use "yum updateinfo list available" and
    "repoquery -a --pkgnarrow=available" to include the net new RPM packages
    as well.
    
    Meanwhile, some obsoleted packages might be reported as net new RPMs.
    Therefore, an extra step is added to filter out these obsoleted RPMs.
    
    Signed-off-by: Ming Lu <ming.lu@citrix.com>
    minglumlu committed May 17, 2022
    Configuration menu
    Copy the full SHA
    c020034 View commit details
    Browse the repository at this point in the history
  2. CA-367120: Add un-installed packages into accumulative update list

    This commit fixes a bug in following case:
    One new RPM package is to be installed due to being required by an
    existing package. The new package has not been installed. There are
    accumulative updates for this new package. Example:
    foo-1-1.rpm introduced in update-01, but not installed
    foo-2-1.rpm introduced in update-02, but not installed
    foo-3-1.rpm introduced in update-03, and to be installed in this update
    
    In this case, the accumulative updates (update-01 and update-02) should
    be included in consolidating update information.
    
    Signed-off-by: Ming Lu <ming.lu@citrix.com>
    minglumlu committed May 17, 2022
    Configuration menu
    Copy the full SHA
    3f68b24 View commit details
    Browse the repository at this point in the history
  3. CA-367120: Add debug logs for outputs of YUM/RPM command lines

    The YUM/RPM command lines may return long ouptput strings which might be
    truncated by logging.
    
    This commit adds extra debug logs for the outputs of these command lines
    as they are useful in debugging.
    
    Signed-off-by: Ming Lu <ming.lu@citrix.com>
    minglumlu committed May 17, 2022
    Configuration menu
    Copy the full SHA
    9b22a3d View commit details
    Browse the repository at this point in the history
  4. Merge pull request xapi-project#4704 from minglumlu/private/mingl/CA-…

    …367120
    
    Missing net new RPMs in picking up metadata from updateinfo
    minglumlu committed May 17, 2022
    Configuration menu
    Copy the full SHA
    f3ab12b View commit details
    Browse the repository at this point in the history
  5. CP-38688 make Message.destroy_many() async, too

    Update the definition of Message.destroy_many to use the default flags,
    which inlcudes the Async flag that ensures an async version of this API
    call is provided. This should further improve user experiences since we
    expect this call to be slow when many messages are removed.
    
    Signed-off-by: Christian Lindig <christian.lindig@citrix.com>
    lindig committed May 17, 2022
    Configuration menu
    Copy the full SHA
    9b33278 View commit details
    Browse the repository at this point in the history
  6. XSI-1246/CA-367232: Daily license re-apply fails is HA is enabled

    A CH host is meant to re-apply it's license once a day, in order to
    correctly handle expiry and to pick up any new licenses. This is some by
    setting a timer in a thread in v6d, which triggers a host.apply_edition
    call to xapi after 24 hours. The problem is that this call is rejected
    if HA is enabled, which breaks the mechanism.
    
    We'll fix this by allowing a host.apply_edition call if the edition is
    not being changed. This is still consistent with the original intention
    of the restriction (as evidenced by the code comment).
    
    Signed-off-by: Rob Hoes <rob.hoes@citrix.com>
    robhoes committed May 17, 2022
    Configuration menu
    Copy the full SHA
    894e882 View commit details
    Browse the repository at this point in the history
  7. Merge pull request xapi-project#4708 from robhoes/master

    Upgrade VM runtime state when xenopsd restarts
    robhoes committed May 17, 2022
    Configuration menu
    Copy the full SHA
    0778243 View commit details
    Browse the repository at this point in the history
  8. Merge pull request xapi-project#4710 from lindig/private/christianlin…

    …/CP-38688
    
    CP-38688 make Message.destroy_many() async, too
    robhoes committed May 17, 2022
    Configuration menu
    Copy the full SHA
    26afb30 View commit details
    Browse the repository at this point in the history
  9. Filter input dns when reconfiguring a pif IP(v6)

    Instead of throwing an exception when a DNS doesn't have
    the correct ip familly: just ignore it
    
    It means when reconfiguring:
    - an ipv4: only the ipv4 entries on the input dns will kept and
    only the ipv6 dns already set to the pif will be kept
    - an ipv6: only the ipv6 entries on the input dns will kept and
    only the ipv4 dns already set to the pif will be kept
    
    This is usefull in the case both family are configured on a pif
    
    Right now the installer and xsconsole can fail when reconfiguring an
    IP or an IPv6 and both family DNS are present, which can often happen
    in case of dual stack
    
    Signed-off-by: BenjiReis <benjamin.reis@vates.fr>
    benjamreis committed May 17, 2022
    Configuration menu
    Copy the full SHA
    7f82c86 View commit details
    Browse the repository at this point in the history
  10. Merge pull request xapi-project#4711 from robhoes/apply-ha

    XSI-1246/CA-367232: Daily license re-apply fails is HA is enabled
    robhoes committed May 17, 2022
    Configuration menu
    Copy the full SHA
    353b0c7 View commit details
    Browse the repository at this point in the history
  11. Merge pull request xapi-project#4705 from xcp-ng/filter-dns-when-reco…

    …nfiguring-pif
    
    Filter input dns when reconfiguring a pif IP(v6)
    robhoes committed May 17, 2022
    Configuration menu
    Copy the full SHA
    3bda7d9 View commit details
    Browse the repository at this point in the history

Commits on May 18, 2022

  1. CA-366309: ignore HA when checking update readiness

    In particular, the evacuation plan is computed in a different way when
    HA is enabled. We want the update readiness to check things as if HA is
    disabled, because before updates are applied, HA will be disabled anyway.
    
    Signed-off-by: Rob Hoes <rob.hoes@citrix.com>
    robhoes committed May 18, 2022
    Configuration menu
    Copy the full SHA
    f1d4d7e View commit details
    Browse the repository at this point in the history
  2. Merge pull request xapi-project#4714 from robhoes/ha_update_checks

    CA-366309: ignore HA when checking update readiness
    robhoes committed May 18, 2022
    Configuration menu
    Copy the full SHA
    9c72f99 View commit details
    Browse the repository at this point in the history
  3. XenAPI.py: define how to build package in pyproject.toml

    This fixes xapi-project#4716
    
    Signed-off-by: Pau Ruiz Safont <pau.safont@citrix.com>
    psafont committed May 18, 2022
    Configuration menu
    Copy the full SHA
    eafe3df View commit details
    Browse the repository at this point in the history

Commits on May 20, 2022

  1. Merge pull request xapi-project#4717 from psafont/package-peping

    XenAPI.py: define how to build package in pyproject.toml
    robhoes committed May 20, 2022
    Configuration menu
    Copy the full SHA
    f7c2180 View commit details
    Browse the repository at this point in the history
  2. Merge pull request xapi-project#4690 from psafont/unit-tests

    maintenance: make xapi-xenops tests more granular
    robhoes committed May 20, 2022
    Configuration menu
    Copy the full SHA
    133eecc View commit details
    Browse the repository at this point in the history
  3. CP-38583 add Host.last_software_update field with data/time

    Add a new field that reflects the last time Host.apply_software_updates
    was run (or the time of the first installation).
    
    Signed-off-by: Christian Lindig <christian.lindig@citrix.com>
    lindig committed May 20, 2022
    Configuration menu
    Copy the full SHA
    95300f6 View commit details
    Browse the repository at this point in the history
  4. xapi: avoid spawning processes to touch files

    The check against an empty string needs to be kept as some of the
    variables use an empty string as an alternative to None, meaning not to
    create the file at all.
    
    Signed-off-by: Pau Ruiz Safont <pau.safont@citrix.com>
    psafont committed May 20, 2022
    Configuration menu
    Copy the full SHA
    674816b View commit details
    Browse the repository at this point in the history
  5. xapi: avoid spawning a process directly to reconfigure syslogs

    use forkexecd instead
    
    Signed-off-by: Pau Ruiz Safont <pau.safont@citrix.com>
    psafont committed May 20, 2022
    Configuration menu
    Copy the full SHA
    2a29912 View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    cf2f4a6 View commit details
    Browse the repository at this point in the history
  7. Merge pull request xapi-project#4718 from lindig/private/christianlin…

    …/CP-38583
    
    CP-38583 add Host.last_software_update field with data/time
    lindig committed May 20, 2022
    Configuration menu
    Copy the full SHA
    6884a2a View commit details
    Browse the repository at this point in the history

Commits on May 23, 2022

  1. Repository Update Unit Tests: Livepatch

    Signed-off-by: Ming Lu <ming.lu@citrix.com>
    minglumlu committed May 23, 2022
    Configuration menu
    Copy the full SHA
    5e1ab60 View commit details
    Browse the repository at this point in the history
  2. Repository Update Unit Tests: Refine files of existing unit tests

    Signed-off-by: Ming Lu <ming.lu@citrix.com>
    minglumlu committed May 23, 2022
    Configuration menu
    Copy the full SHA
    d22a7d6 View commit details
    Browse the repository at this point in the history
  3. Repository Update Unit Tests: UpdateInfo with LivePatch

    Signed-off-by: Ming Lu <ming.lu@citrix.com>
    minglumlu committed May 23, 2022
    Configuration menu
    Copy the full SHA
    6858db4 View commit details
    Browse the repository at this point in the history
  4. Repository Update Unit Tests: Livepatch in repository_helper

    Prior to support live patch, the guidance of an update is determined by
    "recommendedGuidance". With supporting to live patch, a new metadata
    "livepatchGuidance" is introduced.
    
    In an update, if a live patch in it is determined as applicable, its
    "livepatchGuidance" will overwrite its "recommendedGuidance".
    
    Signed-off-by: Ming Lu <ming.lu@citrix.com>
    minglumlu committed May 23, 2022
    Configuration menu
    Copy the full SHA
    93ab198 View commit details
    Browse the repository at this point in the history
  5. Merge pull request xapi-project#4692 from minglumlu/private/mingl/CP-…

    …39487
    
    Support livepatch - part 2 - unit tests
    minglumlu committed May 23, 2022
    Configuration menu
    Copy the full SHA
    990d8e8 View commit details
    Browse the repository at this point in the history

Commits on May 24, 2022

  1. CP-39884 generalise interface to gzip/zstd-like tools

    The existing interface to compressions tools assumes that all tools
    receive the exact same command-line arguments. As such, it inhibits
    using specific features of each tool for diferent use cases.
    
    This patch introduces two things:
    
    * Each compression tool may use specific options, unavailable by another
      implementation.
    
    * Each compression tool may provide profiles for different use cases,
      like high compression or fast compression. So far only a default
      profile is implemented but adding more is trivial. At the same time,
      clients are shielded from the underlying command-line options being
      used.
    
    Signed-off-by: Christian Lindig <christian.lindig@citrix.com>
    lindig committed May 24, 2022
    Configuration menu
    Copy the full SHA
    0a7a968 View commit details
    Browse the repository at this point in the history

Commits on May 25, 2022

  1. Merge pull request xapi-project#4719 from lindig/private/christianlin…

    …/CP-39884
    
    CP-39884 generalise interface to gzip/zstd-like tools
    lindig committed May 25, 2022
    Configuration menu
    Copy the full SHA
    19e8bf7 View commit details
    Browse the repository at this point in the history
  2. fixup! CP-38583 add Host.last_software_update field with data/time

    We want to use Xapi_host.get_servertime instead of Date.localtime
    because it impacts the representation used for XMLRPC. This is obviously
    a design deficiency as the representation of dates in XMLRPC should be
    decided during serialisation and not at creation.
    
    Signed-off-by: Christian Lindig <christian.lindig@citrix.com>
    
    fixup! CP-38583 add Host.last_software_update field with data/time
    
    Signed-off-by: Christian Lindig <christian.lindig@citrix.com>
    lindig committed May 25, 2022
    Configuration menu
    Copy the full SHA
    c2435b8 View commit details
    Browse the repository at this point in the history
  3. Use XMLRPC date format for Host.software_version.date

    Change the date format for the build as it is recorded in the
    Host.software_version.date field to match the XMLRPC date format for
    consistency and expectations by Citrix Hypervisor Center.
    
    The format used by XMLRPC http://xmlrpc.com/spec.md
    is claimed to be ISO8601:
    
      19980717T14:08:55
    
    This is somewhat doubtful becuase it mixes no punctuation for the date
    with punctuation for the time.
    
    https://stackoverflow.com/a/36775198
    
    Signed-off-by: Christian Lindig <christian.lindig@citrix.com>
    lindig committed May 25, 2022
    Configuration menu
    Copy the full SHA
    34124f1 View commit details
    Browse the repository at this point in the history
  4. Merge pull request xapi-project#4721 from lindig/private/christianlin…

    …/CP-38583
    
    Fix date representations for CH Center
    lindig committed May 25, 2022
    Configuration menu
    Copy the full SHA
    98239da View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    1dd5bbd View commit details
    Browse the repository at this point in the history