AliSQL:阿里巴巴开源的MySQL,带有向量和DuckDB引擎。
AliSQL: Alibaba's open-source MySQL with vector and DuckDB engines

原始链接: https://github.com/alibaba/AliSQL

## AliSQL:为规模和人工智能而优化的MySQL AliSQL是阿里巴巴集团开发的MySQL分支,专为大规模环境中的高性能、稳定运行而设计。8.0.44版本集成了DuckDB作为原生存储引擎,可以直接通过SQL实现轻量级的分析能力。 主要特性包括对企业级向量处理(高达16,383维)的原生支持,并针对语义搜索和推荐等人工智能应用优化了ANN搜索。未来的开发重点将是显著改进DDL操作(速度、安全性、减少延迟)、恢复时间目标(RTO)和复制吞吐量。 AliSQL是开源的(GPL-2.0许可),并由阿里巴巴积极维护,欢迎通过GitHub进行社区贡献。从源代码构建需要CMake、Python3和C++17编译器,仓库中提供了详细的构建说明。

## AliSQL:阿里巴巴的MySQL揭秘 阿里巴巴最近开源了AliSQL,这是一款兼容MySQL的数据库,具有向量和DuckDB引擎。 这在Hacker News上引发了讨论,特别是用户分享的一段过去与阿里巴巴高管会面的经历。 在会议上,高管们声称他们为云平台*完全重写*了MySQL,否认它是基于原始版本。 AliSQL的开源似乎证明了这一说法不实,让该用户感到有趣。 另一位评论员链接了一篇研究论文,表明由于构建完全多节点系统存在限制,选择了类似的“拼凑”架构(MySQL + DuckDB)。 这次讨论凸显了AliSQL起源可能存在误导性的呈现方式。
相关文章

原文

AliSQL is Alibaba's MySQL branch, forked from official MySQL and used extensively in Alibaba Group's production environment. It includes various performance optimizations, stability improvements, and features tailored for large-scale applications.

🚀 Quick Start (DuckDB)

Quickly build your DuckDB node: How to set up a DuckDB node

  • AliSQL Version: 8.0.44 (LTS)
  • Based on: MySQL 8.0.44
  • DuckDB Storage Engine:AliSQL integrates DuckDB as a native storage engine, allowing users to operate DuckDB with the same experience as MySQL. By leveraging AliSQL for rapid deployment of DuckDB service nodes, users can easily achieve lightweight analytical capabilities.

  • Vector Storage:AliSQL natively supports enterprise-grade vector processing for up to 16,383 dimensions. By integrating a highly optimized HNSW algorithm for high-performance Approximate Nearest Neighbor (ANN) search, AliSQL empowers users to build AI-driven applications—such as semantic search and recommendation systems—seamlessly using standard SQL interfaces.

  • DDL Optimization (planned):AliSQL delivers a faster, safer, and lighter DDL experience through innovations such as enhanced Instant DDL, parallel B+tree construction, a non-blocking lock mechanism, and real-time DDL apply—significantly improving schema change efficiency and virtually eliminating replication lag.

  • RTO Optimization (planned):AliSQL deeply optimizes the end-to-end crash recovery path to accelerate instance startup, shorten RTO, and restore service quickly.

  • Replication Optimization (planned): AliSQL significantly boosts replication throughput and minimizes lag by implementing Binlog Parallel Flush, Binlog in Redo, and specialized optimizations for large transactions and DDL operations.

Prerequisites:

  • CMake 3.x or higher
  • Python3
  • C++17 compliant compiler (GCC 7+ or Clang 5+)

Build Instructions:

# Clone the repository
git clone https://github.com/alibaba/AliSQL.git
cd AliSQL

# Build the project (release build)
sh build.sh -t release -d /path/to/install/dir

# For development/debugging (debug build)
sh build.sh -t debug -d /path/to/install/dir

# Install the built MySQL server
make install

Build Options:

  • -t release|debug: Build type (default: debug)
  • -d <dest_dir>: Installation directory (default: /usr/local/alisql or $HOME/alisql)
  • -s <server_suffix>: Server suffix (default: alisql-dev)
  • -g asan|tsan: Enable sanitizer
  • -c: Enable GCC coverage (gcov)
  • -h, --help: Show help

For DuckDB-specific support, see the DuckDB Support Options.

AliSQL 8.0 became an open-source project in December 2025 and is actively maintained by engineers at Alibaba Group.

Contributions are welcome! Please:

  1. Fork the repository
  2. Create a feature branch
  3. Make your changes with appropriate tests
  4. Submit a pull request

For bug reports and feature requests, please use the GitHub Issues page.

This project is licensed under the GPL-2.0 license. See the LICENSE file for details.

AliSQL is based on MySQL, which is licensed under GPL-2.0. The DuckDB integration follows the same licensing terms.

联系我们 contact @ memedata.com