Search the FAQ Archives

3 - A - B - C - D - E - F - G - H - I - J - K - L - M
N - O - P - Q - R - S - T - U - V - W - X - Y - Z
faqs.org - Internet FAQ Archives

comp.sys.hp.hpux FAQ
Section - 5.1.4 How can I disable non-root logins?

( Single Page )
[ Usenet FAQs | Web FAQs | Documents | RFC Index | Cities ]


Top Document: comp.sys.hp.hpux FAQ
Previous Document: 5.1.3 How can I restrict regular users from logging in at the console?
Next Document: 5.1.5 Where can I find a list of all patches corresponding to security advisories?
See reader questions & answers on this topic! - Help others by sharing your knowledge
Add the following to /etc/profile, then 'touch /etc/nologin'; this will
disable all new logins, except by root:

  uid=`id -u`
  if [ -f /etc/nologin -a $uid -ne 0 ]; then
    echo "Sorry, no logins allowed; try later!"
    sleep 5
    exit 0
  fi

User Contributions:

Comment about this article, ask questions, or add new information about this topic: