易陆发现互联网技术论坛

 找回密码
 开始注册
查看: 412|回复: 2
收起左侧

configure: error: PAM headers not found,编译openssh服务报错解决方法

[复制链接]
发表于 2023-8-22 15:00:05 | 显示全部楼层 |阅读模式

马上注册,结交更多好友,享用更多功能,让你轻松玩转社区。

您需要 登录 才可以下载或查看,没有账号?开始注册

x
编译openssh报错
' h* p7 m3 J' U5 |( N4 `$ [configure: error: PAM headers not found
* _0 a7 O4 Z# Ochecking for arc4random_stir... no
; L) g& i5 W+ x. d# c( Rchecking for arc4random_uniform... no
8 @! X0 y4 Q1 F% h5 k( r  hchecking whether OpenSSL's PRNG is internally seeded... yes
5 i7 m! j0 I$ D" xchecking for ia_openinfo in -liaf... no, `9 j8 F( W1 U5 n
checking for crypt in -lcrypt... yes3 v3 [" S* I# j" ^. C9 d
checking for crypt... yes
$ }" T) c, B* K; Hconfigure: error: PAM headers not found# X5 E4 x% f1 k/ D

$ |) ~& t! X3 F' W2 h9 z! I; i
/ ]% X! _. A9 i0 n; W& C6 I0 [& n
解决办法:
- z0 f  G/ U4 ?# Iyum install gcc zlib-devel pam-devel libselinux-devel zlib-devel openssl-devel -y
6 H; A" M1 P) Y/ y7 J* v" ~7 N2 s* u8 V: a/ W
安装时openssl-devel会影响其他安装包安装过程,建议去掉使用下面的方式的:
/ ]+ S: J. Z0 }. B6 h8 m7 |
yum install gcc zlib-devel pam-devel libselinux-devel zlib-devel -y  j  j# G3 L) l% Z: ~# q3 e8 l

$ x7 M; I, R4 {# Vglibc-2.17-325.el7_9.i686 is a duplicate with glibc-2.17-317.el7.x86_64glibc-common-2.17-325.el7_9.x86_64 is a duplicate with glibc-common-2.17-317.el7.x86_64krb5-libs-1.15.1-50.el7.x86_64 is a duplicate with krb5-libs-1.15.1-37.el7_6.x86_64krb5-libs-1.15.1-51.el7_9.i686 is a duplicate with krb5-libs-1.15.1-50.el7.x86_64libselinux-2.5-15.el7.i686 is a duplicate with libselinux-2.5-14.1.el7.x86_64libselinux-python-2.5-15.el7.x86_64 is a duplicate with libselinux-python-2.5-14.1.el7.x86_64libselinux-utils-2.5-15.el7.x86_64 is a duplicate with libselinux-utils-2.5-14.1.el7.x86_64nspr-4.32.0-1.el7_9.x86_64 is a duplicate with nspr-4.21.0-1.el7.x86_64nss-softokn-freebl-3.67.0-3.el7_9.i686 is a duplicate with nss-softokn-freebl-3.44.0-8.el7_7.x86_64nss-util-3.67.0-1.el7_9.x86_64 is a duplicate with nss-util-3.44.0-4.el7_7.x86_641:openssl-1.0.2k-24.el7_9.x86_64 is a duplicate with 1:openssl-1.0.2k-19.el7.x86_641:openssl-libs-1.0.2k-24.el7_9.i686 is a duplicate with 1:openssl-libs-1.0.2k-19.el7.x86_64policycoreutils-2.5-34.el7.x86_64 is a duplicate with policycoreutils-2.5-29.el7_6.1.x86_64selinux-policy-3.13.1-268.el7.noarch is a duplicate with selinux-policy-3.13.1-229.el7_6.12.noarchselinux-policy-targeted-3.13.1-268.el7.noarch is a duplicate with selinux-policy-targeted-3.13.1-229.el7_6.12.noarchzlib-1.2.7-19.el7_9.i686 is a duplicate with zlib-1.2.7-18.el7.x86_64
6 L3 C0 {! X& l: T8 _9 b: D1 o3 t6 p& ]( N# @# j) {

8 @3 T& c7 h3 a: a. @+ H$ p8 [# a0 Z# b# F

7 U$ G* `# p- @  @+ e
3 p7 p9 S0 \5 m, ^8 a& }* A
- V6 B: T/ e+ @, s$ @' y+ Q& T2 Y7 R
 楼主| 发表于 2023-8-22 15:00:06 | 显示全部楼层
yum install gcc zlib-devel pam-devel libselinux-devel zlib-devel -y  X6 W4 r. e0 F2 A* P8 _9 g
' ~* T& b; W2 [! s8 o
configure: WARNING: unrecognized options: --with-md5-passwords
' q( o$ E( J+ P1 H+ ]) K
+ }& X% g* f4 K0 ~/ k) QOpenSSH has been configured with the following options:9 h, `! p: f& ?' C1 n$ _$ O
                     User binaries: /usr/bin/ D; _) b( S6 ~
                   System binaries: /usr/sbin) j( R9 p( f* ]. v: F1 ?& H. N
               Configuration files: /etc/ssh& f0 K: d3 e. G- _7 Y
                   Askpass program: /usr/libexec/ssh-askpass7 ]5 Q  W. L* m. |" L
                      Manual pages: /usr/share/man/manX8 ~0 I, w7 S, Z- @3 X1 _% _
                          PID file: /var/run
& K7 V' N9 {" p  Privilege separation chroot path: /var/empty; ^/ c* H0 Q% ?( A- r6 N' g; k2 z
            sshd default user PATH: /usr/bin:/bin:/usr/sbin:/sbin
8 ?, C) F3 i6 ]9 h+ f                    Manpage format: doc
9 I1 {/ n5 }. a. D                       PAM support: yes
1 Q' T9 Q) s, P- G8 j% p                   OSF SIA support: no
- o$ c5 c3 g# m5 X$ o                 KerberosV support: no! u4 I; I1 K( E" k
                   SELinux support: no- s2 n0 g9 d* o4 W$ [
                   libedit support: no9 T5 V! x2 E! e- j; O  H
                   libldns support: no
/ M* k$ f- [* d# C) W% D  Solaris process contract support: no
5 J3 s4 j! T6 u6 t7 M# Q           Solaris project support: no" ]7 N2 a! V) D# y
         Solaris privilege support: no
% Z  y) u7 I- N& o, a+ p$ P       IP address in $DISPLAY hack: no: h! ^: V$ E: }% a* `/ ^6 F  O
           Translate v4 in v6 hack: yes
, U0 b- U$ M  ~                  BSD Auth support: no
- \9 O8 S9 u/ S9 s  x; o( Z              Random number source: OpenSSL internal ONLY
3 B  q" G# c! V4 S  X, G             Privsep sandbox style: seccomp_filter
7 u+ G, b- z5 ^                   PKCS#11 support: yes
/ l; N& O  b* n: t; G! F0 Y! y7 M                  U2F/FIDO support: yes" d7 j* {* w( p" t. L! A, C

5 a8 e; |  [  V7 n# }9 V              Host: x86_64-pc-linux-gnu
& L) x8 z' A8 Z: r& r3 u          Compiler: cc -std=gnu11
, {5 N: M4 f% V( |, t2 V2 v# u    Compiler flags: -g -O2 -pipe -Wall -Wpointer-arith -Wuninitialized -Wsign-compare -Wformat-security -Wsizeof-pointer-memaccess -Wno-pointer-sign -Wno-unused-result -fno-strict-aliasing -D_FORTIFY_SOURCE=2 -ftrapv -fno-builtin-memset -fstack-protector-strong -fPIE  
7 H' J1 \  N% cPreprocessor flags: -I/usr/ssl  -D_XOPEN_SOURCE=600 -D_BSD_SOURCE -D_DEFAULT_SOURCE -D_GNU_SOURCE! O9 Y. q' P* T& H+ H
      Linker flags: -L/usr/ssl  -Wl,-z,relro -Wl,-z,now -Wl,-z,noexecstack -fstack-protector-strong -pie
7 E  g) e% h2 u3 p         Libraries: -ldl -lutil  -lresolv/ e7 b7 A/ C, R+ n" b4 C
     +for channels: -lcrypto  -lz
" @6 Z+ `0 N7 d         +for sshd: -lcrypt  -lpam. H/ i; z: ^2 N8 n5 |8 T8 `

2 }4 P, Y" d7 T3 ]PAM is enabled. You may need to install a PAM control file . t! y# X; L: T! v
for sshd, otherwise password authentication may fail. ! h0 R$ `% c( _
Example PAM control files can be found in the contrib/
4 g, \/ @- H! R- zsubdirectory8 {9 W7 P3 x0 W5 d& H" h- G, O6 `5 L
 楼主| 发表于 2023-8-22 15:00:07 | 显示全部楼层
报了错误
5 x# b4 E% d& p) ]$ E
! i: h( g. h- n% j2 qconfigure: error: PAM headers not found
: Q3 \/ M: Y6 j; Y2 k解决方案/ S; U/ x' n9 _, ?
yum -y install pam-devel
您需要登录后才可以回帖 登录 | 开始注册

本版积分规则

关闭

站长推荐上一条 /4 下一条

北京云银创陇科技有限公司以云计算运维,代码开发

QQ|返回首页|Archiver|小黑屋|易陆发现技术论坛 ( 蜀ICP备2026014127号-1 )点击这里给我发消息

GMT+8, 2026-4-8 21:30 , Processed in 0.055443 second(s), 24 queries .

Powered by Discuz! X3.4 Licensed

© 2012-2025 Discuz! Team.

快速回复 返回顶部 返回列表