Proper system shutdown implementation.