Hi Abubakar Ali,
Thank you for reaching out to the Microsoft Q&A platform.
Based on your question description we understand that you are Unable to Access VM via SSH After Reboot.
In addition to Andreas, please follow the below troubleshot steps:
Reset the SSH configuration and reset the credentials for the user.
Verify the network security group rules permit SSH traffic and role assignment.
Ensure that a Network Security Group rule exists to permit SSH traffic (by default, TCP port 22).
If you are using Microsoft Entra ID to manage SSH logins, the user must be assigned the Virtual Machine Administrator Login or Virtual Machine User Login role on the resource group that contains the VM and its associated resources.
Check the VM resource health and the VM reports as being healthy.
Restart the VM and Redeploy the VM.
Please find the below document for your reference:
https://learn.microsoft.com/en-us/troubleshoot/azure/virtual-machines/linux/troubleshoot-ssh-connection
I hope this information is helpful. Please feel free to reach out if you have any further questions.
If the answer is helpful, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".
Thank you.