Aix

sshd 程序不工作

  • January 9, 2013

我有一個 AIX 伺服器突然停止為 SSH 連接提供服務。當我嘗試通過 startsrc -s sshd 啟動服務時,它說:

0513-059 The sshd Subsystem has been started. Subsystem PID is 258300.

但是,在發出命令後,服務狀態立即顯示為無效:

sshd             ssh                           inoperative

初始化腳本的位置很好,並拋出與上面相同的結果。

編輯:這是 odmget 命令輸出:

SRCsubsys:
   subsysname = "sshd"
   synonym = ""
   cmdargs = "-D"
   path = "/usr/sbin/sshd"
   uid = 0
   auditid = 0
   standin = "/dev/console"
   standout = "/dev/console"
   standerr = "/dev/console"
   action = 1
   multi = 0
   contact = 2
   svrkey = 0
   svrmtype = 0
   priority = 20
   signorm = 15
   sigforce = 9
   display = 1
   waittime = 20
   grpname = "ssh"

嘗試手動啟動服務時,出現以下錯誤:

exec(): 0509-036 Cannot load program /usr/sbin/sshd because of the following errors:
0509-150   Dependent module libz.a(libz.so.1) could not be loaded.
0509-022 Cannot load module libz.a(libz.so.1).
0509-026 System error: A file or directory in the path name does not exist.

任何幫助將不勝感激。

看起來libz.so.1您的系統上缺少。

您可以嘗試以下方法:

LogLevel DEBUG31 )啟用/etc/ssh/sshd_config

security.debug /var/log/syslog.security.debug rotate time 1d files 42)添加字元串/etc/syslog.conf

3)然後

# touch /var/log/syslog.security.debug
# stopsrc -s syslogd
# startsrc -s syslogd
# stopsrc -s sshd
# startsrc -s sshd

引用自:https://unix.stackexchange.com/questions/60663