stop a service with
systemctl, but you need to also
disable it and anything that would cause it to start up. You can use
systemctl disable sshd so that
sshd will not be started when you turn the system on in the future. If I'm not mistaken, any existing
ssh connections will be maintained even after running
systemctl stop sshd. No new connections should be able to become established.
You can see that with your
systemctl command, you have
sshd.socket. You need to stop and disable both of these using
systemctl, likely the socket first, and then the service. One is dependent on the other and will not be disabled unless done in the proper order.
$ sudo systemctl stop sshd.service sshd.socket
$ sudo systemctl disable sshd.socket
$ sudo systemctl disable sshd.service
As it has been mentioned, Ubuntu's
openssh-server only installs
ssh.service, and no socket. This is also true about Debian Stretch. It seems you've deviated from default and without more details it's hard to know exactly what's going on.
Depending on the requirements, removing the package providing
openssh-server) would be a more fool-proof approach. Please consider things such as the physical location of the machine, etc, before completely disabling