getconf 是 Debian 系统里 libc-bin 包提供的命令,大多数情况下系统已经自带了。如果你发现没有这个命令,可以按下面步骤安装。
which getconf
# 或
getconf --version
如果提示 command not found,再继续安装。
sudo apt update
sudo apt install libc-bin
安装完成后,getconf 通常在:
/usr/bin/getconf
getconf LONG_BIT
输出一般是:
64
getconf PAGE_SIZE
getconf _NPROCESSORS_ONLN
getconf GNU_LIBC_VERSION
如果你是在 最小化容器(如 debian:slim) 里,可能默认没装,用上面的 apt install libc-bin 就能解决。
需要我帮你写一个 Dockerfile 或排查具体环境也可以。