I have issue with my SSH service in VM, I try to fix it using serial port connection, I can take this connection but every time I want to reconnect by serial port I have to restart the VM, because the last connection is still active.
I tried in vain send “~." to serail port input and desabling than ennabling.
My question is How to end active connection and began new one or take over this active connection.
thank you.
Hello benzaouia,
Welcome to GCC!
Serial port connection is used for troubleshooting instances that are not properly booting up and not accessible. If you are having difficulties connecting to your instance via SSH:
1. Can you please send me a screenshot of the error while connecting to your VM via SSH?
2. Have you setup your firewall already for tcp:22 ingress type?
3. Do you have any recent changes on your VM config?
There are other solutions to resolve your SSH issue but I need more details about the error that you are encountering.
Thank you,
the problem has resolved, by reconfig the OS of VM firewall
The first time I am focused in cloud platform firewall, this is my mistake
Hello benzaouia,
Glad to know that. Enjoy using Google Cloud.
Thanks!
Hello Willbin,
Thank you for your response,
Yes I have issue with my SSH connection, with this message error :
>>
xxxxxxxxx@cloudshell:~ (xxxxxxxxxxxxxx)$ gcloud compute ssh "xxxxxxxx"
Did you mean zone [europe-west1-c] for instance: [instance-1] (Y/n)? n
No zone specified. Using zone [xxxxxxxxxxxxxxx] for instance: [xxxxxxxxxx].
ssh: connect to host xxxxxxxxxxx port 22: Connection timed out
Recommendation: To check for possible causes of SSH connectivity issues and get
recommendations, rerun the ssh command with the --troubleshoot option.
gcloud compute ssh xxxxxxxxxxxxxx --project=xxxxxxxxxxxxxxxx --zonexxxxxxxxxxxxxxx --troubleshoot
Or, to investigate an IAP tunneling issue:
gcloud compute ssh xxxxxxxxxxx --project=xxxxxxxxxxxxxx --zone=xxxxxxxxxxxxxxx --troubleshoot --tunnel-through-iap
ERROR: (gcloud.compute.ssh) [/usr/bin/ssh] exited with return code [255].
<<
The first time I have an SSH connection after the same change in my machine, I forget it with the error message higher.