You can temporarily disable user logins by:
Creating the /etc/nologin file.
Bringing the system to run level 0 (single-user mode). See "Shutting Down a System (Tasks)" in System Administration Guide, Volume 1 for information on bringing the system to single-user mode.
Create this file to disallow user logins and notify users when a system will be unavailable for an extended period of time due to a system shutdown or routine maintenance.
If a user attempts to log in to a system where this file exists, the contents of the nologin(4) file is displayed, and the user login is terminated. Superuser logins are not affected.