If you can't get it working 100% every time on localhost (127.0.0.1) then you got big problems - in other words no point trying to login from elsewhere across a network until you got local login sussed out. Try using the ip address, and try using the standard port (22) - are you sure your isp hasn't blocked port 2222 (or any other port for that matter) and is your n900 behind a NAT/firewall (and do you have the required port forwarding etc?).