![]() |
please help with ssh
hay guys, i need to connect my n900 to my win7 64bit laptop, i have had the n900 since januery and never used ssh, and decided its time to learn, how ever i cant seam to find any walk throus or guides so im after some help,
i have downloaded winscp on to my laptop and openssh client and server on to the n900 but dont know what to do next lol? thanks for any help snake |
Re: please help with ssh
First you need to either know the root password or you need to set the password for another user.
(Installing ssh on the device forces you to change it anyway!) Then get your devices ip (i am using wireless) - In terminal type Code:
ifconfig http://content.screencast.com/users/...11-08_1759.png In the result you will get something that looks like the IP. One you know that complete the winscp screen like this: http://content.screencast.com/users/...11-08_1755.png Click Login http://content.screencast.com/users/...11-08_1757.png Enter the root password! (Done!) If you the login box stalls, try connecting to a website, anyone on your n900, and either wait or rety it - sometimes the n900 just needs a wake up ;) |
Re: please help with ssh
Caveats and hints:
You cannot login from another host into your N900 when using GPRS, at least not if it uses ppp. A lan connection (generally 192.168.x.x) will do fine. You must setup a connection from the N900 to your lan first. You can login as user@192.168.x.x; which does not need changes to sshd.conf. root login is a no-no and should be disabled by default. Paai PS: There is a widget that displays your IP number on the N900 desktop. |
Re: please help with ssh
Quote:
in terminal i have sudo gainroot then ifconfig found inet addr types this in host name on winscp put root as the user name hit login but nothing happens after this, your second screen shot does not apear so then i uninstalled and reinstalled winscp, however this didnt solve the problem any ideas??? oh and btw both laptop and n900 can access the internet as normal |
Re: please help with ssh
In your N900 status bar thingy at the top do you have a button that says SSH Status? As that turns SSH on or OFF - it's off after each reboot etc for me, so i need to remember to turn it back on
edit - forgot to mention, that status bar things can scroll up and down too - so it may not always look like it is there. Found googley image here http://www.my-maemo.com/grafika/sshswitcher.jpg |
Re: please help with ssh
there is no option for ssh in my status bar!!! hmmmm that could be the problem
|
Re: please help with ssh
or... your IP address was wrong or a firewall on your PC is blocking WinSCP
|
Re: please help with ssh
:) possibly either of those too hehehe :P
|
Re: please help with ssh
Meh just found out thats not installed by default - no harm in having it though!
http://maemo.org/downloads/product/Maemo5/ssh-status/ |
Re: please help with ssh
but you also need password. When you were setting up SSH on N900 at some point you had to enter some password. That password you need to enter beside user name in winscp.
I'm using filezilla on ubuntu and everything went fine at very first attempt. I also set up fixed IP for my N900 and make a bookmark in filezilla so SSH is just a click away. edit: And of course, you have to turn SSH on on your N900. Either with applet (install separately) in your status bar or via terminal. |
Re: please help with ssh
Quote:
In Windows try pinging you phone, for example: Code:
ping 192.168.0.4 |
Re: please help with ssh
Quote:
|
Re: please help with ssh
Quote:
follow the procedure again, and winscp still just disapears, when i click login :-( edit, also tried pinging my n900 and got this reply C:\Users\martyn>ping 192.168.2.2 Pinging 192.168.2.2 with 32 bytes of data: Reply from 192.168.2.6: Destination host unreachable. Reply from 192.168.2.6: Destination host unreachable. Reply from 192.168.2.6: Destination host unreachable. Reply from 192.168.2.6: Destination host unreachable. Ping statistics for 192.168.2.2: Packets: Sent = 4, Received = 4, Lost = 0 (0% loss) |
Re: please help with ssh
tried ping again and got this
C:\Users\martyn>ping 192.168.2.2 Pinging 192.168.2.2 with 32 bytes of data: Reply from 192.168.2.2: bytes=32 time=249ms TTL=64 Reply from 192.168.2.2: bytes=32 time=170ms TTL=64 Reply from 192.168.2.2: bytes=32 time=180ms TTL=64 Reply from 192.168.2.2: bytes=32 time=202ms TTL=64 Ping statistics for 192.168.2.2: Packets: Sent = 4, Received = 4, Lost = 0 (0% loss), Approximate round trip times in milli-seconds: Minimum = 170ms, Maximum = 249ms, Average = 200ms however winscp still just shuts its self down |
Re: please help with ssh
So you phone is reachable from you PC on 192.168.2.2 so something else is blocking WinSCP. Look at the PC's firewall.
|
Re: please help with ssh
ok, well, at least you are connecting now, even if a little slowly.
I do find winscp can't see the device if it's not awake so to speak.... on the device try pinging something else, or loading a website as you try conencting via winscp (I normally just have facebook on in the background, as it is an internet whore)... The other thing, if you can, dicsonnect or turn of any pc firewalls etc, just to confirm it's not that. |
Re: please help with ssh
iv gota go to work now guy, will have to pick this up tomoro! cheers for your help today thou, will re post when i get home :D
|
Re: please help with ssh
I have the same problem as thesnake505 and solve it as "off" the firewall of windows7 while I made ssh session.
|
Re: please help with ssh
Quote:
|
Re: please help with ssh
Apart from winscp there is apso putty, that opens a ssh-terminal on your windows host. Try it.
If you can ping the N900 there probably is no firewall active. Finally you can try 'telnet 192.168.2.2. 22' from the windows commandline to see if the N900 listens on the ssh port (22). BTW: do you have a password for the 'user' acount on the N900? Perhaps winscp refuses to work if the password field id empty? You can remedy that with 'passwd user' from the n900 commandline. Paai |
Re: please help with ssh
Quote:
not sure what u meant with passwd user from the n900?? when i installed openssh it asked for a password, have tried with and with out the password in the feild and also with user as the username! will have a look at the other win7 ssh client u mention! i do have ubuntu on this laptop, im guessing its worth a try using that, so could some one do me a quick quide to setting up ssh with ubuntu? and i do appreciate all the help given :D |
Re: please help with ssh
Quote:
You need to set a password for it, by: Open up the terminal, and as root type: passwd user (note, passwd is not a typo). Then you will be able to login as user, logining in as root via SSH is a bad idea. |
Re: please help with ssh
snake:
first, check that the ssh daemon is running on your N900 $ ps ax | grep sshd it should show someting like 897 ? Ss 0:00 /usr/sbin/sshd Like jd4200 and myself already suggested: give yourself a password. $ passwd user New pasword for user: retype password: (Your name on the N900 is always 'user') Install putty, run it It will ask for hostname or ip-address. That will be 192.168.2.2 for you (BTW: you don't have a DHCP server that can assign different IP-numbers?) A black window will appear with 'username' (that will be user) and 'password for user' (that will be the password you assigned to user). jd4200 and I have already said that enabling root login and logging in as root is a Bad Idea (TM). I will say it again. paai |
Re: please help with ssh
hay, mannaged to get a connection using putty which is cool so thanks all for that, i like the way it looks just like terminal x n the n900 :D
now i have a couple of questions, how do i transfer files using putty? if nessacery with using putty can i login as root with sudo gain root??? cheers |
Re: please help with ssh
You cannot transfer files using PuTTY as it just a Terminal window running on your phone. As you can access the N900 now, give WinSCP a try again.
When you login with PuTTY it asks you for a user name and password User name:root Password:The password you entered in the N900 when you installed OpenSSH |
Re: please help with ssh
winSCP is still not working, im now getting invalid access to memory every time i hit login!
|
Re: please help with ssh
There is a commandline counterpart to winscp, called PSCP. Download it from the same site as putty itself.
Your problems with winscp are worrying. Are you certain there is no virus in it? Run a viruscheck on your windows PC, delete winscp and install it again. Paai |
Re: please help with ssh
Quote:
Snake, if you changed sshd.conf to allow root logins, you'd better change it back. Paai |
Re: please help with ssh
Quote:
But I gather that you are not very experienced with Linux, so understand that being root is an excellent opportunity to shoot yourself in both feet at the same time, so avoid it as much as possible. Paai |
Re: please help with ssh
Quote:
|
Re: please help with ssh
IIRC N900 wifi goes "sleep"(if there is no data transfer) even-thought it seems to be connected. At least I have to first set SSH on and additionally open web-page on n900 or do something that involves data transfer. And after that I can connect to my n900 with winscp in my home network.
|
Re: please help with ssh
Honestly, putty and winscp are both good things for the poor windows user. But the full experience of secure shell can only be achieved between two linux machines, in my oppinoin. If you're stuck in Windows and want to gain access to another machine in a more complex way you might want to use cygwin, which is a more linux adapted environment. If you are even more stuck on "windows" in general NXServer/Client is something where you can get a fast desktop experience over a secure connection (that won't work with the N900 maemo though since afaik you cannot get the hildon over x11).
You can also if you're on a 3g or GSM connection and only is interested in the xterminal access to your n900 (and providing that you at home have a openssh server, probably under linux) use reverse ssh to gain access to your phone. But I won't explain it of course, it would be ridiculous since google is your friend. However, with reverse ssh I suggest you to make a bash script for that, and then aliases to access that script in a more compact way. Rant over. Good night. |
Re: please help with ssh
scp can be fun. I have been using ssh from the beginning though and its easy to setup.
|
All times are GMT. The time now is 17:00. |
vBulletin® Version 3.8.8