From my local machine, which command can tell me which machines I have connected via ssh, or ftp, etc? At the same time, which command can let me know which machines have tried to connect my machine via these different network protocols?
1 Answer
To check which port or address your computer is connected to try
sudo lsof -i sudo netstat -l
- 2The OP could also use
ss
(socket status) to see current connections.– SchivesCommentedMar 14, 2017 at 23:17 - @Schives you are right sudo netstat ss displays current connections.CommentedMar 15, 2017 at 9:33