I am trying to automate the file transfer between server and the local machine, which I was able to do it on laptop running windows 7 as well as Ubuntu. Now trying to implement it on the local desktop machine running windows server 2003, by installing cygwin. I am able to transfer files via


the errror message got using the following command is as below.

 $ ssh -vvv test username@example.se:~/?
OpenSSH_6.0p1, OpenSSL 1.0.1c 10 May 2012
debug2: ssh_connect: needpriv 0
debug1: Connecting to test [] port 22.
debug1: connect to address port 22: Connection timed out
ssh: connect to host test port 22: Connection timed out

some help would be appreciated. I do not understand, why i am unable to since server settings must be ok as I was able to transfer files using scp from my laptop. what can be the reason. some help needed immediately if possible. thanks.

  • Is this question mark really part of your command line or is it just a typo? (here: $ ssh -vvv test username@example.se:~/?) – Claudio Jul 10 '12 at 16:19
  • Can you ping the IP address of the server? Can you run a trace route to it? – Zoredache Jul 10 '12 at 16:38

This error shows you couldn't connect to the server. That can have many reasons:

  • a firewall blocking incoming connections to your server
  • a firewall blocking outgoing connections from your computer
  • ssh daemon on the server configured to listen on a non-standard port
  • stopped ssh daemon

Since you can transfer files from your other computer I'd say you probably have a firewall blocking the connection. By the way... I supposed this host "test" is just a hypothetical example you used. Note it's IP address is not a valid local address (, so if this message is real you should try using the server's IP address in place of "test".

  • I agree that IP is just some numbers instead of the actual IP, ssh daemon on the server configured to listen to the non standard port ! "I was able to ´scp´ from my laptop with same config in server." yes I can ping to the server, its ok with 0 packet loss. Question mark was part of the command which resulted the output files above. I saw it in some posts and used it did not know exactly what it does. – tough Jul 10 '12 at 16:54
  • If the server is configured to listen on a non-standard port you have to specify it on the command line. Suppose the port you are using is 2222. Then you should use this for ssh: ssh -p2222 user@server. Note that for scp the switch is a P instead of p: scp -P2222 file user@server:~/directory (supposing directory is under your homedir). – Claudio Jul 10 '12 at 17:13
  • as I have successfully connected via ssh, that must not be a problem with the port, could you please highlight on this. I am quite new so, detailed explanation would help me more. link says something about it but could not figure out on which side it is talking about client or the server side? – tough Jul 11 '12 at 9:25
  • Now it seems that I can log in with ssh and do scp as well, don know what changes caused this. but it works, as far as i know my commands were not correct. – tough Jul 11 '12 at 11:46
  • @tough, if you post the commands you used for connecting successfully I can explain you why they worked. – Claudio Jul 11 '12 at 12:15

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.