Skip to content

Aleph-vm 0.4.0

Compare
Choose a tag to compare
@hoh hoh released this 22 Mar 10:17
· 162 commits to main since this release

We are excited to announce aleph-vm in version 0.4.0.

This update brings a series of improvements and bug fixes that enhance the stability, performance, and usability of Aleph.im's virtual machine infrastructure. With this version, we aim at deploying the features introduced at the beginning of the year to the entire network.

As usual, node operators are expected to upgrade to the new release within a 2 weeks windows from the release.

Improvements and New Features

  • Improved Error Handling and Debugging: Refactoring and enhancements have been made to improve the traceability of exceptions and errors, making it easier for developers to debug issues.
  • Interface and Network Handling Enhancements: The handling of busy network interfaces and the management of network errors have been improved, including more informative logging and adjustments to prevent instance creation failures.
  • Support for QEMU Instances: aleph-vm now allows the running of QEMU instances, expanding the versatility of the virtual machine environment.
  • Runtime and Dependency Updates: Updated runtime dependencies to include newer versions of aleph-sdk-python and fastapi, among others, ensuring better performance and security.
  • Cors Support: Implemented CORS support on both supervisor and diagnostic VM endpoints, enhancing integration capabilities with different frontends.
  • Configuration Improvements: Introduced default hypervisor options and refined the configuration of MyPy for better type checking and code quality.
  • Persistent VM Management: Enhancements to the detection and management of persistent VMs improve stability and reduce potential for errors after orchestrator reboots.

Notable changes

  • Fixed a series of bugs related to VM execution stopping, interface management, and asynchronous operations that could lead to crashes or unexpected behavior.
  • Resolved issues with network interface manipulation, making error conditions more visible and manageable.
  • Adjusted the handling of missing or busy interfaces, reducing the potential for errors during VM setup.
  • Addressed various code quality issues, including outdated dependencies, incorrect type annotations, and issues identified through static analysis.
  • Enhanced the system's resilience to network and execution errors, including better handling of timeouts and busy resources.
  • Implemented several fixes and updates aimed at improving the testing environment, from integration with CodeCov to adjustments in CI workflows to ensure tests are more reliable and comprehensive.

This release consolidates several weeks of dedicated work to enhance aleph-vm's robustness, ease of use, and feature set. We appreciate the community's feedback and contributions, which have been invaluable in making these improvements possible.

Pull Requests in details

  • Fix: Argument vm_id was missing. by @hoh in #539
  • Fix: Status check fastapi view could crash due to ServerDisconnectedError. by @hoh in #537
  • Fix: An IndexError was raised if no execution was left for this sender. by @hoh in #536
  • Fix: TypeError: catching classes that do not inherit from BaseException is not allowed by @hoh in #535
  • Fix: socket.getaddrinfo does not always return 2 values by @hoh in #540
  • Added CORS support on supervisor endpoints by @nesitor in #542
  • Detect already running Persistent VMs by @nesitor in #541
  • Cleanup: Minor code cleanup and refactoring by @hoh in #546
  • Fix: Linux kernel from package could not be on a different device by @hoh in #543
  • Add nftables as a dependency by @aliel in #547
  • Implement CORS on diagnostic VM endpoints by @nesitor in #551
  • Check request token exists by @nesitor in #550
  • Fix: CI did not run pytest by @hoh in #545
  • Fix: Caller expected tuple but got a single value by @hoh in #555
  • Allow running Qemu instances by @nesitor in #557
  • Solve random 500 errors on ephemeral VMs by @nesitor in #549
  • Fix issues with stopping VMs by @hoh in #554
  • Use stronger typing with Mypy by @hoh in #556
  • Update runtime dependencies by @hoh in #548
  • Runtimes: Update locale settings to en_US UTF-8 by @aliel in #562
  • Fix: Paths to fake data were broken by refactoring by @hoh in #559
  • Fix: Benchmark command did not initialize or check settings by @hoh in #561
  • Fix: Errors in network interface manipulation were invisible by @hoh in #566
  • Fix: Small code quality fixes by ruff check --fix by @hoh in #565
  • Fix: Firecracker would not start without DNS servers, even when networking is disabled. by @hoh in #564
  • Fix: Workflows used deprecated actions by @hoh in #567
  • Fix: Tests on Droplets ran even when tests failed by @hoh in #568
  • Fix: asyncio.run was sometimes used within a coroutine by @hoh in #560
  • Fix: Depencency aleph-message was outdated by @hoh in #569
  • Fix: Network errors were hard to inspect by @hoh in #571
  • Fix FAKE_DATA_PROGRAM issue on instances. by @nesitor in #572
  • Implement default hypervisor options on settings by @nesitor in #573
  • Fix: pyproject.toml license field must point to a file by @hoh in #574
  • Fix: Deleting a missing interface crashed by @hoh in #576
  • Fix: Interface being busy prevented instance creation by @hoh in #579
  • Fix: Waiting for another tasks reached timeout by @hoh in #580
  • Fix: Failing to restart nddpd caused the exception to escalate by @hoh in #584
  • Fix: Guest API would crash due to FileNotFound by @hoh in #583
  • Solve network issues on Ubuntu hosts by @nesitor in #586

Full Changelog: 0.4.0a3...0.4.0

How to upgrade

1. Upgrade the packages

This part did not change, download and install the new package as usual.

On Debian 11 (Bullseye):

rm -f /opt/aleph-vm.debian-11.deb
wget -P /opt https://github.com/aleph-im/aleph-vm/releases/download/0.4.0/aleph-vm.debian-11.deb
apt install /opt/aleph-vm.debian-11.deb

On Debian 12 (Bookworm):

rm -f /opt/aleph-vm.debian-12.deb
wget -P /opt https://github.com/aleph-im/aleph-vm/releases/download/0.4.0/aleph-vm.debian-12.deb
apt install /opt/aleph-vm.debian-12.deb

On Ubuntu 22.04 (Jammy Jellyfish):

rm -f /opt/aleph-vm.ubuntu-22.04.deb
sudo wget -P /opt https://github.com/aleph-im/aleph-vm/releases/download/0.4.0/aleph-vm.ubuntu-22.04.deb
sudo apt install /opt/aleph-vm.ubuntu-22.04.deb

2. Enable Pay-as-you-go (optional)

See the release notes of version 0.4.0 alpha1.