This function is useful in scenarios where a separate user account is needed to mount…