I have an instance I created from the web console, using the "Classic" wizard & the default Amazon Linux image.
When I go to Instance Actions, Connect, and select the "Connect with a standalone SSH Client" option, it has the correct string, using ec2-user@.
I saved that as an AMI, and then created a new instance via the ec2 command-line tools:
ec2-run-instances <ami> -k <my key> -g <my security group>
Now when I get the connect string, it uses root@, which doesn't work - I need to change that to ec2-user to actually connect.
This isn't a big deal, but I'm wondering why there's a difference - is there a missing parameter when I create it via the command line?
ec2-user and root are two different users on the server. By default, root SSH access is not allowed per /etc/ssh/sshd_config. You could change this, of course, but it's considered a good security practice. (Root is a known, privileged account, and therefore a prime target for attackers.)
How old are your ec2 command-line tools? I'd guess that they used to allow root access previously, but no longer do that.