# 使用 Homebrew, apk, apt, MacPorts, Nix 安装 daemontools

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

## 安装

```sh
sudo av install brew:daemontools
```

其他安装命令:

### macOS

- Homebrew (100%):

```sh
brew install daemontools
```

  证据: local Homebrew formula metadata

- MacPorts (94%):

```sh
sudo port install daemontools
```

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

### Linux

- apk (92%):

```sh
sudo apk add daemontools
```

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

- Debian apt (92%):

```sh
sudo apt install daemontools
```

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

- Nix (92%):

```sh
nix profile install nixpkgs#daemontools
```

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

## 软件包事实

- **软件包键:** brew:daemontools
- **软件包管理器:** Homebrew
- **版本:** 0.76
- **来源摘要:** Collection of tools for managing UNIX services
- **主页:** <https://cr.yp.to/daemontools.html>
- **最后更新:** 2026-07-10T19:03:06-04:00
- **已生成:** 2026-08-03T19:37:03+00:00

## 可执行文件

- envdir (别名)
- envuidgid (别名)
- fghack (别名)
- multilog (别名)
- pgrphack (别名)
- readproctitle (别名)
- setlock (别名)
- setuidgid (别名)
- softlimit (别名)
- supervise (别名)
- svc (别名)
- svok (别名)
- svscan (别名)
- svscanboot (别名)
- svstat (别名)
- tai64n (别名)
- tai64nlocal (别名)

## 安装行为

- Bottle: 不可用

## 版本和新鲜度

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

daemontools is Daniel J. Bernstein's collection of Unix service supervision and logging tools. Its model is compact and filesystem-oriented: services are directories, each service has a run script, and small programs such as supervise, svscan, svc, multilog, envdir, setuidgid, softlimit, setlock, tai64n, and tai64nlocal compose the system.

### 项目历史

The official daemontools page describes the package as tools for managing UNIX services. The install guide distributes daemontools-0.76.tar.gz under /package/admin/daemontools-0.76 and documents a /package-based installation layout.

The upgrade notes show the package stabilizing its service model across the 0.53, 0.60/0.61, 0.70, and 0.75/0.76 lines. Notable changes include supervise switching to a service directory and ./run script, older logging utilities being replaced by multilog, accustamp and tailocal being replaced by tai64n and tai64nlocal, setuidgid being renamed from setuser, setlock and envdir being added, svscan accepting a service directory argument, and the package moving under /package/admin/daemontools.

### 采用历史

daemontools became influential among Unix administrators who wanted reliable supervision outside traditional init scripts. Its FAQ explicitly compares /service with inittab, ttys, init.d, and rc.local, arguing for easy installation and removal, automatic first startup, reliable restarts, reliable signaling, clean process state, and portability across Linux, BSD, Solaris, and other Unix systems.

Even on systems that no longer deploy daemontools itself, its vocabulary remains recognizable in later supervision systems: foreground daemons, run scripts, service directories, separate supervised loggers, and small process-control commands.

### 使用方式

A supervised service is a directory containing an executable ./run script. supervise changes into that directory, starts ./run, restarts it if it exits, honors a down file for initially disabled services, and writes status under the service directory's supervise subdirectory.

svscan starts one supervise process for each subdirectory of its scan directory, checks every five seconds for new services, restarts supervise processes that exit, and can also wire a service's output to a separately supervised log service. multilog saves, filters, timestamps, and rotates logs, pausing safely if the disk fills rather than dropping data.

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

For package nerds, daemontools is important because it expresses a service-manager philosophy in tiny binaries and directories rather than a large resident manager. The package is old, terse, and opinionated, but it influenced how Unix people talk about supervision, foreground services, log pipelines, and avoiding fragile init-script process state.

### 时间线

- 0.53-0.61: supervise changes to run ./run from a service directory.
- 0.60-0.61: older logging and timestamp tools are replaced by multilog, tai64n, and tai64nlocal; setuser becomes setuidgid.
- 0.61-0.70: setlock and envdir are added; svscan gains a command-line /service argument.
- 0.70-0.76: package installs under /package/admin/daemontools; svscanboot, readproctitle, and pgrphack are added.
- 0.76: Official install guide distributes daemontools-0.76.tar.gz.

### Related projects

- daemontools includes or centers on supervise, svscan, svc, svok, svstat, fghack, pgrphack, readproctitle, multilog, tai64n, tai64nlocal, setuidgid, envuidgid, envdir, softlimit, and setlock.
- Its service-supervision ideas are related to later daemontools-family and daemontools-inspired supervisors, though those projects are outside the official source set used here.

### 来源

- <https://cr.yp.to/daemontools.html>
- <https://cr.yp.to/daemontools/faq/create.html>
- <https://cr.yp.to/daemontools/install.html>
- <https://cr.yp.to/daemontools/supervise.html>
- <https://cr.yp.to/daemontools/svscan.html>
- <https://cr.yp.to/daemontools/upgrade.html>


## 安全说明

formula declares a Homebrew service.

- **Geiger 风险:** orange / 中
- formula declares a Homebrew service

## 其他软件包管理器记录

- Debian apt - daemontools - 1:0.76-14: normalized package name match | Debian stable package indexes: daemontools from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | collection of tools for managing UNIX services | https://cr.yp.to/daemontools.html
- Debian apt - daemontools-run - 1:0.76-14: normalized package name match | Debian stable package indexes: daemontools-run from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | daemontools service supervision | https://cr.yp.to/daemontools.html
- Nix - daemontools: normalized package name match | nixpkgs package indexes: pkgs/by-name/da/daemontools/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1
- Ubuntu apt - daemontools - 1:0.76-10: normalized package name match | Ubuntu 24.04 LTS package indexes: daemontools from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | collection of tools for managing UNIX services | https://cr.yp.to/daemontools.html
- Ubuntu apt - daemontools-run - 1:0.76-10: normalized package name match | Ubuntu 24.04 LTS package indexes: daemontools-run from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | daemontools service supervision | https://cr.yp.to/daemontools.html
- apk - daemontools - 0.76-r3: normalized package name match | Alpine Linux edge package indexes: daemontools from https://dl-cdn.alpinelinux.org/alpine/edge/testing/x86_64/APKINDEX.tar.gz | Collection of tools for managing UNIX services | https://cr.yp.to/daemontools.html
- apk - daemontools-openrc - 0.76-r3: normalized package name match | Alpine Linux edge package indexes: daemontools-openrc from https://dl-cdn.alpinelinux.org/alpine/edge/testing/x86_64/APKINDEX.tar.gz | Collection of tools for managing UNIX services (OpenRC init scripts) | https://cr.yp.to/daemontools.html
- MacPorts - daemontools: normalized package name match | MacPorts ports tree: sysutils/daemontools/Portfile from https://api.github.com/repos/macports/macports-ports/git/trees/master?recursive=1
- Nix - supervise: installed executable or alias match | nixpkgs package indexes: pkgs/by-name/su/supervise/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1


## Combined YAML source

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


## 来源

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