• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar
  • Skip to footer navigation

The Geek Diary

  • OS
    • Linux
    • CentOS/RHEL
    • Solaris
    • Oracle Linux
    • VCS
  • Interview Questions
  • Database
    • oracle
    • oracle 12c
    • ASM
    • mysql
    • MariaDB
  • DevOps
    • Docker
    • Shell Scripting
  • Big Data
    • Hadoop
    • Cloudera
    • Hortonworks HDP

login Command Examples in Linux

by admin

The login utility logs users (and pseudo-users) into the computer system. If no user is specified, or if a user is specified and authentication of the user fails, login prompts for a user name. Authentication of users is configurable via pam. Password authentication is the default.

If the file /etc/nologin exists, login displays its contents to the user and exits. This is used by shutdown(8) to prevent users from logging in when the system is about to go down.

login Command Examples

1. To login to the system:

# login 

2. To tell login not to destroy the environment:

# login -p 

3. To skip the second login authentication:

# login -f 

4. To display version information:

# login -V

5. To display help text:

# login --help

login command reads the /etc/login.defs configuration file.

Filed Under: Linux

Some more articles you might also be interested in …

  1. How to resolve the error “-bash: xclock: command not found” in CentOS / RHEL
  2. Error: Can’t open display: hostname:x.y when running xclock
  3. Unable to Run X Applications Through SSH in Linux
  4. CentOS / RHEL 7 : How to install and configure ftp server (vsftpd)
  5. CentOS / RHEL : Resize (extend) non-root EXT3/4 filesystem on non-LVM device (hard disk partition)
  6. CentOS / RHEL : How to prioritize the devices used for swap partition
  7. “not enough to start the array” – error while staring mdadm RAID array
  8. How To Customize The Screensaver Options In Gnome on CentOS/RHEL 7
  9. CentOS / RHEL 6 : How to Change the Volume Group Name for Root Disk Device
  10. CentOS / RHEL : How to adjust the telnet timeout (and how to disable it)

You May Also Like

Primary Sidebar

Recent Posts

  • vgextend Command Examples in Linux
  • setpci command – configure PCI device
  • db_load command – generate db database
  • bsdtar command – Read and write tape archive files

© 2022 · The Geek Diary

  • Archives
  • Contact Us
  • Copyright