作者 主題: inittab如何設定個別的登入驗證呢?  (閱讀 393 次)

0 會員 與 1 訪客 正在閱讀本文。

unetin

  • 懷疑的國中生
  • **
  • 文章數: 72
    • 檢視個人資料
inittab如何設定個別的登入驗證呢?
« 於: 2016-10-27 15:39 »
我有一台舊的Linux主機,目前用遠端SSH登入和用VGA螢幕登入,用的帳號密碼都是/etc/passwd和/etc/shadow裡面記錄的資料
但如果接Console port的話,登入用的帳號密碼是執行(/opt/console/cli )來驗證...
現在我想要讓VGA螢幕登入和Console port登入都執行/opt/console/cli來驗證(遠端用SSH登入的驗證不變),請教該如何修改?
 
以下是我目前的inittab:

id:3:initdefault:

# System initialization.
si::sysinit:/etc/rc.d/rc.sysinit

l0:0:wait:/etc/rc.d/rc 0
l1:1:wait:/etc/rc.d/rc 1
l2:2:wait:/etc/rc.d/rc 2
l3:3:wait:/etc/rc.d/rc 3
l4:4:wait:/etc/rc.d/rc 4
l5:5:wait:/etc/rc.d/rc 5
l6:6:wait:/etc/rc.d/rc 6

# Trap CTRL-ALT-DELETE
ca::ctrlaltdel:/sbin/shutdown -t3 -r now

# When our UPS tells us power has failed, assume we have a few minutes
# of power left.  Schedule a shutdown for 2 minutes from now.
# This does, of course, assume you have powerd installed and your
# UPS connected and working correctly.
pf::powerfail:/sbin/shutdown -f -h +2 "Power Failure; System Shutting Down"

# If power was restored before the shutdown kicked in, cancel it.
pr:12345:powerokwait:/sbin/shutdown -c "Power Restored; Shutdown Cancelled"

s0:23:respawn:/sbin/agetty -n -l /opt/console/cli ttyS0 19200 vt100

# Run gettys in standard runlevels
1:2345:respawn:/sbin/agetty -n -l /opt/console/cli ttyS0 19200 vt100

# Run xdm in runlevel 5
# xdm is now a separate service
x:5:respawn:/etc/X11/prefdm -nodaemon