Linux ftpshut Command
The Linux ftpshut command shuts down the FTP server at a specified time.
This command allows system administrators to shut down the FTP server at a set time and can send a warning message to users before the shutdown. If the shutdown time is set to "none", the server will shut down immediately. If set using "+30", it means the server will shut down in 30 minutes. Similarly, if set in the format "1130", it means the server will shut down daily at 11:30, using a 24-hour clock. After the FTP server is shut down, a file named shutmsg will be created in the /etc directory. Deleting this file will restart the FTP server functionality.
Syntax
ftpshut [-d<minutes>][-l<minutes>][shutdown time]["warning message"]
Parameters:
-d<minutes> Time to disconnect all FTP connections.
-l<minutes> Time to stop accepting new FTP logins.
Example
To shut down the FTP server at 11:00 PM, and to reject new FTP logins 5 minutes before the shutdown, and to disconnect all FTP connections 3 minutes before the shutdown, with a warning message, use the following command:
ftpshut -d 3 -l 5 1100 "Server will be shutdown at 23:00:00"