# 使用 Homebrew, apk, apt, Nix, pacman, dnf, MacPorts, zypper 安装 unixodbc

查看 unixodbc 的安装路径、可执行文件、元数据以及面向 AI 代理工作流的安全说明。

## 安装

```sh
sudo av install brew:unixodbc
```

其他安装命令:

### macOS

- Homebrew (100%):

```sh
brew install unixodbc
```

  证据: local Homebrew formula metadata

- MacPorts (94%):

```sh
sudo port install unixODBC
```

  证据: MacPorts ports tree: databases/unixODBC/Portfile from https://api.github.com/repos/macports/macports-ports/git/trees/master?recursive=1

### Linux

- apk (92%):

```sh
sudo apk add unixodbc
```

  证据: Alpine Linux edge package indexes: unixodbc from https://dl-cdn.alpinelinux.org/alpine/edge/main/x86_64/APKINDEX.tar.gz

- Debian apt (92%):

```sh
sudo apt install unixodbc
```

  证据: Debian stable package indexes: unixodbc from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz

- Nix (92%):

```sh
nix profile install nixpkgs#unixodbc
```

  证据: nixpkgs package indexes: pkgs/by-name/un/unixodbc/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1

- pacman (92%):

```sh
sudo pacman -S unixodbc
```

  证据: Arch Linux sync databases: unixodbc from https://geo.mirror.pkgbuild.com/core/os/x86_64/core.db.tar.gz

- dnf (92%):

```sh
sudo dnf install odbcinst-generate
```

  证据: Fedora Rawhide package metadata: odbcinst-generate from https://dl.fedoraproject.org/pub/fedora/linux/development/rawhide/Everything/x86_64/os/repodata/07190dc5ae9f35ae73866675fed6d95fe6e8d9fe22c9d7cdf85862cb2ed24a4c-primary.xml.zst

- zypper (92%):

```sh
sudo zypper install libodbc2
```

  证据: openSUSE Tumbleweed package metadata: libodbc2 from https://download.opensuse.org/tumbleweed/repo/oss/repodata/50b07339cb64c8ed4091bdbabddadc1ff5737b090e478818a195b40d8a3292861a879139b4a3987c31109699fde9fbf4a716367ddf4eef77da75f96e3193d6ed-primary.xml.zst

## 软件包事实

- **软件包键:** brew:unixodbc
- **软件包管理器:** Homebrew
- **版本:** 2.3.14
- **来源摘要:** ODBC 3 connectivity for UNIX
- **主页:** <https://www.unixodbc.org/>
- **仓库:** <https://github.com/lurcher/unixODBC>
- **最后更新:** 2026-06-27T17:28:37-04:00
- **已生成:** 2026-08-03T19:37:03+00:00

## 可执行文件

- dltest (别名)
- isql (别名)
- iusql (别名)
- odbc_config (别名)
- odbcinst (别名)
- slencheck (别名)

## 安装行为

- Bottle: 不可用

## 版本和新鲜度

- 页面生成时间: 2026-08-03
- 管理器版本: 2.3.14
## 项目历史与用法

unixODBC is a free ODBC subsystem and SDK for Linux, macOS, and Unix. Its central role is the driver manager: the layer that lets applications use ODBC APIs while loading and configuring database-specific drivers on non-Windows systems.

### 项目历史

The upstream README describes unixODBC as an open source ODBC subsystem and SDK for Linux, Mac OSX, and UNIX, including a driver manager, installer library and command-line tool, plus command-line tools for driver installation and SQL work. Its web documentation describes it as a complete, free/open ODBC solution for UNIX/Linux.

unixODBC grew around the need to reproduce the Windows ODBC environment on non-Windows platforms. The official odbcinst guide explains that Windows ODBC used .ini-style configuration historically, and unixODBC implements the same configuration model and APIs through ini files and libodbcinst.

### 采用历史

unixODBC became infrastructure rather than an end-user application: databases, language bindings, BI tools, office suites, and proprietary drivers could target a common ODBC manager on Unix-like systems. The official documentation includes guides for DB2, FreeTDS, Informix, Perl DBD::ODBC, PHP, OpenOffice/StarOffice, connection pooling, and other integration scenarios.

Its package-manager footprint reflects that infrastructure role. The input shows it packaged across Homebrew, Alpine, Debian and Ubuntu libraries, Fedora, MacPorts, Nix, Arch, and openSUSE, often as the dependency that makes higher-level database connectors work.

### 使用方式

Package users encounter unixODBC through tools such as isql, iusql, odbcinst, odbc_config, dltest, and slencheck. isql tests DSNs and runs SQL from a shell; odbcinst registers drivers and data sources; odbc_config exposes build/link flags for software compiling against the installed driver manager.

The practical admin workflow is ini-file driven. System configuration typically lives in odbcinst.ini and odbc.ini under an etc directory, while user DSNs can live in ~/.odbc.ini. The README notes that ODBCSYSINI can override where unixODBC looks for system configuration.

### 为什么软件包爱好者会关心

unixODBC is package-nerd significant because it is the quiet shared ABI beneath many database packages. A broken driver-manager path, SQLLEN size mismatch, missing ini file, or loader issue can make unrelated database clients fail.

It is also a classic Unix packaging problem: libraries, headers, CLI diagnostics, driver registration, dynamic loading, and vendor drivers all have to agree. That is why tools such as odbc_config, odbcinst, dltest, and slencheck matter even though most users only wanted an application to connect to a database.

### 时间线

- Late 1990s-early 2000s: unixODBC developed as an ODBC subsystem for Unix and Linux platforms.
- 2001: ChangeLog entries show the 2.1.x line adding packaging and platform work, including Mac install/package directories.
- 2002: The 2.2.x line added iusql, odbcinst options, DataManager updates, MySQL/PostgreSQL driver work, and platform fixes.
- 2004: Version 2.2.10 continued portability, driver-manager, VMS, AIX, PostgreSQL, and setup improvements.
- 2015: Version 2.3.4 included driver-manager fixes, man pages, slencheck, mingw-w64 handling, and more ODBC 3.8 work.

### Related projects

- Related projects and ecosystems include Microsoft ODBC, database-specific ODBC drivers, FreeTDS, DB2, Informix, PostgreSQL and MySQL ODBC drivers, Perl DBD::ODBC, PHP ODBC integrations, OpenOffice/StarOffice data access, and vendor Unix database clients.
- The repository also points to SourceForge, GitHub, and the unixODBC web site as project resources, reflecting its long life across older and newer open source hosting.

### 来源

- <https://raw.githubusercontent.com/lurcher/unixODBC/master/ChangeLog>
- <https://raw.githubusercontent.com/lurcher/unixODBC/master/README>
- <https://www.unixodbc.org/doc/>
- <https://www.unixodbc.org/doc/UserManual/>
- <https://www.unixodbc.org/odbcinst.html>
- source_facts.package-manager


## 安全说明

broad file, network, media, or database tool signal.

- **Geiger 风险:** blue / 中
- broad file, network, media, or database tool signal


## Configuration and credential file locations

These source-backed paths show where this package keeps local settings or durable credentials. Automic Vault can use them as review targets for secret scanning, migration, and command approval.


## Configuration files

- Unix: /usr/local/etc/odbcinst.ini, /usr/local/etc/odbc.ini, /etc/odbcinst.ini, /etc/odbc.ini, ~/.odbc.ini
## 其他软件包管理器记录

- Debian apt - libodbc2 - 2.3.12-2: normalized package name match | Debian stable package indexes: libodbc2 from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | ODBC Driver Manager library for Unix | https://www.unixodbc.org
- Debian apt - libodbccr2 - 2.3.12-2: normalized package name match | Debian stable package indexes: libodbccr2 from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | ODBC Cursor library for Unix | https://www.unixodbc.org
- Debian apt - libodbcinst2 - 2.3.12-2: normalized package name match | Debian stable package indexes: libodbcinst2 from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | Support library for accessing ODBC configuration files | https://www.unixodbc.org
- Debian apt - odbcinst - 2.3.12-2: normalized package name match | Debian stable package indexes: odbcinst from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | Helper program for accessing ODBC configuration files | https://www.unixodbc.org
- Debian apt - unixodbc - 2.3.12-2: normalized package name match | Debian stable package indexes: unixodbc from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | Basic ODBC tools | https://www.unixodbc.org
- Debian apt - unixodbc-common - 2.3.12-2: normalized package name match | Debian stable package indexes: unixodbc-common from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | Common ODBC configuration files | https://www.unixodbc.org
- Debian apt - unixodbc-dev - 2.3.12-2: normalized package name match | Debian stable package indexes: unixodbc-dev from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | ODBC libraries for Unix (development files) | https://www.unixodbc.org
- Nix - unixodbc: normalized package name match | nixpkgs package indexes: pkgs/by-name/un/unixodbc/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1
- Ubuntu apt - libodbc2 - 2.3.12-1build2: normalized package name match | Ubuntu 24.04 LTS package indexes: libodbc2 from https://archive.ubuntu.com/ubuntu/dists/noble/main/binary-amd64/Packages.gz | ODBC Driver Manager library for Unix | https://www.unixodbc.org
- Ubuntu apt - libodbccr2 - 2.3.12-1build2: normalized package name match | Ubuntu 24.04 LTS package indexes: libodbccr2 from https://archive.ubuntu.com/ubuntu/dists/noble/main/binary-amd64/Packages.gz | ODBC Cursor library for Unix | https://www.unixodbc.org
- Ubuntu apt - libodbcinst2 - 2.3.12-1build2: normalized package name match | Ubuntu 24.04 LTS package indexes: libodbcinst2 from https://archive.ubuntu.com/ubuntu/dists/noble/main/binary-amd64/Packages.gz | Support library for accessing ODBC configuration files | https://www.unixodbc.org
- Ubuntu apt - odbcinst - 2.3.12-1build2: normalized package name match | Ubuntu 24.04 LTS package indexes: odbcinst from https://archive.ubuntu.com/ubuntu/dists/noble/main/binary-amd64/Packages.gz | Helper program for accessing ODBC configuration files | https://www.unixodbc.org
- Ubuntu apt - unixodbc - 2.3.12-1build2: normalized package name match | Ubuntu 24.04 LTS package indexes: unixodbc from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | Basic ODBC tools | https://www.unixodbc.org
- Ubuntu apt - unixodbc-common - 2.3.12-1build2: normalized package name match | Ubuntu 24.04 LTS package indexes: unixodbc-common from https://archive.ubuntu.com/ubuntu/dists/noble/main/binary-amd64/Packages.gz | Common ODBC configuration files | https://www.unixodbc.org
- Ubuntu apt - unixodbc-dev - 2.3.12-1build2: normalized package name match | Ubuntu 24.04 LTS package indexes: unixodbc-dev from https://archive.ubuntu.com/ubuntu/dists/noble/main/binary-amd64/Packages.gz | ODBC libraries for Unix (development files) | https://www.unixodbc.org
- apk - unixodbc - 2.3.14-r1: normalized package name match | Alpine Linux edge package indexes: unixodbc from https://dl-cdn.alpinelinux.org/alpine/edge/main/x86_64/APKINDEX.tar.gz | Unix Open DataBase Connectivity sub-system and SDK | https://www.unixodbc.org/


## Combined YAML source

View the package source record on GitHub. [combined/unixodbc.yml](https://github.com/mxcl/pkgdb/blob/main/combined/unixodbc.yml)


## 来源

- pkg.so package database
- Geiger risk classifier
- curated configuration and credential file locations
- curated package history
- pkgdb category and tag curation
- external package-manager database matches
- cross-ecosystem install command graph
