Recommended SSH connection method
We recommend using SSH key authentication for connecting to your Virtual Machines. SSH keys provide better security compared to password authentication.
To set up SSH key authentication:
- Generate SSH keys or use existing ones.
- Add your public key to the Gcore Customer Portal.
- Select the key when creating a VM.
WarningSSH keys cannot be downloaded again after creation. Make sure to save your private key in a secure location immediately after generating it.
Add multiple SSH keys to a resource
To allow multiple users or devices to access the same VM, add several SSH keys through the Gcore Customer Portal when creating a VM. In the SSH key section, select multiple keys from your saved keys list.
To add more keys to your account, see Add a public SSH key to the Customer Portal.
Cannot log in as root. Permission denied error
Gcore platform images have root SSH login disabled by default for security reasons.
The default username depends on the operating system. When creating a VM, the portal displays the correct username in the format ssh [username]@ipaddress.
| Operating system | Default username |
|---|
| Ubuntu | ubuntu |
| Debian | debian |
| Fedora | fedora |
| CentOS | cloud-user |
| Rocky Linux | rocky |
| SUSE | sles |
| Fedora-CoreOS | core |
| Windows | Admin (RDP only) |
You can also find your VM’s username in the Gcore Customer Portal: go to Cloud > Virtual Instances, open your instance, and check the information next to the Access to Console link in the format [login]@[ip-of-your-VM].
After connecting with the default user, you can switch to root:
InfoCustom images may have different default usernames or allow root login. Check with the image provider for specific access credentials.
No password received via email
Gcore does not send VM credentials via email. By default, Virtual Machines only accept SSH key authentication.
If you need password access for the VNC console, configure a password during VM creation. For details, see Set a password for a Virtual Machine.
WarningVNC console passwords are for emergency access only. SSH key authentication is the recommended method for connecting to Virtual Machines.
Lost SSH key and cannot connect
If you lost your private SSH key:
-
If you configured a password during VM creation: Access the VM via the VNC console and add a new public key to
~/.ssh/authorized_keys.
-
If no password was configured: Delete the VM and create a new one. Make sure to save the SSH private key during creation.
TipTo prevent losing access, add multiple SSH keys to your VM during creation or use the User Data field to configure a VNC console password as a backup access method.
Incorrect firewall rules. Errors: Connection timed out
This error is usually caused by incorrect firewall configuration.
To allow ping (ICMP):
Add an inbound rule with ICMP protocol:
| Protocol | Type | Code | Source |
|---|
| ICMP | Any | Any | 0.0.0.0/0 |
To allow SSH connections:
Add an inbound rule for TCP port 22:
| Protocol | Port | Source |
|---|
| TCP | 22 | 0.0.0.0/0 |
The default firewall group includes these rules. Select the default group when creating a VM if you have difficulties configuring a custom firewall.
Incorrectly added SSH key. Errors: Connection refused
While generating a key with the PuttyGen utility, you should keep in mind that PuTTY and OpenSSH use different formats of public SSH keys. If the public key has a format like BEGIN SSH2 PUBLIC KEY, it will not work. The key should start with “ssh-rsa AAAA…”.
When creating a key from the PuttyGen utility, you can just use The OpenSSH format key that appears in the interface after generation. You should copy it from the field “Public key for pasting into OpenSSH authorized_keys file”
No floating (public) IP address. Connection refused error
If you used a previously created subnet while creating the machine, the system allows you to create a server without a floating IP.
The SSH connection would not be possible in this case, because an internal IP address is not announced on the Internet. You should add a floating IP address to the newly created machine for the connection from external networks.
The failure to connect to the remote server with Windows OS on it. Connection error
The Connection error occurs when you are trying to connect to the remote machine with Windows OS on it.
In most cases, it is due to an incorrectly selected VM connection Protocol. It is not possible to connect to a Windows OS-based server through SSH.
You should use the RDP Protocol (Remote Desktop Protocol). On a Windows PC, the distribution is installed by the default.
Network appliance images (FortiGate, MikroTik)
Network appliance images have their own authentication methods and do not use standard SSH key authentication.
| Appliance | Default username | Default password |
|---|
| FortiGate | admin | empty (you will be prompted to set a new password on first login) |
| MikroTik CHR | admin | empty |
Access these appliances via:
- VNC console in the Gcore Customer Portal
- Web interface (FortiGate:
https://[VM-IP], MikroTik: http://[VM-IP])
- SSH (after initial configuration via console)
- WinBox (MikroTik only)