温馨提示×

怎么装debian getconf

小樊
39
2026-09-10 14:32:19
栏目: 智能运维

getconfDebian 系统里 libc-bin 包提供的命令,大多数情况下系统已经自带了。如果你发现没有这个命令,可以按下面步骤安装。


1. 先确认是否真的没有

which getconf
# 或
getconf --version

如果提示 command not found,再继续安装。


2. 更新软件源(可选但推荐)

sudo apt update

3. 安装 getconf 所属的包

sudo apt install libc-bin

安装完成后,getconf 通常在:

/usr/bin/getconf

4. 验证

getconf LONG_BIT

输出一般是:

64

常见用法示例

getconf PAGE_SIZE
getconf _NPROCESSORS_ONLN
getconf GNU_LIBC_VERSION

如果你是在 最小化容器(如 debian:slim) 里,可能默认没装,用上面的 apt install libc-bin 就能解决。

需要我帮你写一个 Dockerfile 或排查具体环境也可以。

0