Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game. |
| Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
 |
GNU/Linux Basic Guide
This 255-page guide will provide you with the keys to understand the philosophy of free software, teach you how to use and handle it, and give you the tools required to move easily in the world of GNU/Linux. Many users and administrators will be taking their first steps with this GNU/Linux Basic guide and it will show you how to approach and solve the problems you encounter.
Click Here to receive this Complete Guide absolutely free. |
|
 |
|
06-08-2010, 09:58 AM
|
#1
|
|
LQ Newbie
Registered: Jun 2010
Posts: 6
Rep:
|
Cannot ssh to Ubuntu box from Windows laptop.
I've just set up OpenSSH on my Ubuntu 8.04 box. Observe no firewall in system services list on ubuntu box. Attempt to ssh using putty from windows laptop attached to same router.
Putty connection times out. Can ping ubuntu box from laptop.
What might I be doing wrong?
Thanks,
Owen.
|
|
|
|
06-08-2010, 10:01 AM
|
#2
|
|
Senior Member
Registered: May 2006
Location: USA
Distribution: Debian
Posts: 4,474
|
Are you connecting to the right address?
Is SSHd running on the server?
|
|
|
|
06-08-2010, 10:01 AM
|
#3
|
|
Guru
Registered: May 2009
Location: Gibraltar, Gibraltar
Distribution: Fedora 18 with Awesome WM
Posts: 6,796
|
Hello and Welcome to LinuxQuestions,
Did you install the SSH server on your Ubuntu box? Check with this:
and if you installed check with this if it's running:
If both are true then check if you have it listening:
Code:
netstat -aln | grep ":22"
Kind regards,
Eric
|
|
|
|
06-08-2010, 10:03 AM
|
#4
|
|
Senior Member
Registered: May 2005
Location: Paraguay
Posts: 1,565
Rep:
|
Make sure SSH is running on Ubuntu:
It should return something like:
Code:
720 ? 00:00:00 sshd
|
|
|
|
06-08-2010, 10:09 AM
|
#5
|
|
Member
Registered: May 2010
Location: In world
Distribution: RHEL, CentOS, Ubuntu
Posts: 275
Rep:
|
Please make sure that you have installed openssh-server package in Ubuntu and check whether SSH is running with "ps -ef | grep ssh".
|
|
|
|
06-09-2010, 02:56 AM
|
#6
|
|
LQ Newbie
Registered: Jun 2010
Posts: 6
Original Poster
Rep:
|
Apparently, every thing's fine on Ubuntu box:
Code:
owen@stage-hub:~$ which sshd
/usr/sbin/sshd
owen@stage-hub:~$ ps -ef|grep sshd
root 4820 1 0 17:28 ? 00:00:00 /usr/sbin/sshd
owen 5856 5806 0 17:45 pts/0 00:00:00 grep sshd
owen@stage-hub:~$ netstat -aln|grep ":22"
tcp6 0 0 :::22 :::* LISTEN
owen@stage-hub:~$
Curiously, I cannot ping Windows laptop from Ubuntu box.
Could this be a firewall problem on my Windows laptop? Could it be a problem with my router?
Thanks,
Owen.
|
|
|
|
06-09-2010, 03:11 AM
|
#7
|
|
Guru
Registered: May 2009
Location: Gibraltar, Gibraltar
Distribution: Fedora 18 with Awesome WM
Posts: 6,796
|
Hi,
Can you post your IP configuration of both your Windows and Ubuntu box? Do you have SELinux enabled on Ubuntu? Check with:
Can you ping your router from both boxes?
Kind regards,
Eric
|
|
|
|
06-09-2010, 04:38 AM
|
#8
|
|
Member
Registered: Jul 2009
Posts: 31
Rep:
|
Can't ping the Windows machine... this disturbs me/ The Windows firewalls have honestly caused me a lot of head aches - that's not just a Linux fan boy talking. Might be worth seeing if you can disable this for testing temporarily if it's a safe environment.
Personally I'd want to be able to ping the IP addresses of both devices (and the IP of the router). Might be worth checking the arp table if you are seeing any oddities. Will kinda look like this in a Linux:
Code:
XXXX$ arp -a
? (192.168.1.1) at 00:24:c4:12:34:56 [ether] on eth0
? (192.168.1.2) at 00:50:7f:12:34:56 [ether] on eth0
and this in Windows:
Code:
C:\Users\XXXX>arp -a
Interface: 192.168.1.105 --- 0xb
Internet Address Physical Address Type
192.168.1.1 00-24-c4-12-34-56 dynamic
192.168.1.2 00-50-7f-12-34-56 dynamic
I'd be wanting to see everything on the LAN there.
|
|
|
|
06-10-2010, 04:09 AM
|
#9
|
|
LQ Newbie
Registered: Jun 2010
Posts: 6
Original Poster
Rep:
|
Can ping router from Ubuntu.
Hence, believing problem is with Windows laptop, I opened a command line session on my Windows laptop and did what CmdoColin suggested:
Code:
C:\Documents and Settings\Owen Thomas>arp -a
Interface: 192.168.1.64 --- 0x2
Internet Address Physical Address Type
192.168.1.254 00-1f-9f-d2-84-a0 dynamic
Curiously, the Ubuntu box (192.168.1.67) does not appear.
Believe therefore that remedy lies with Windows config. Although this is a linux discussion group, I would appreciate a fix to this problem.
Thanks,
Owen.
|
|
|
|
06-10-2010, 04:10 AM
|
#10
|
|
LQ Newbie
Registered: Jun 2010
Posts: 6
Original Poster
Rep:
|
Windows XP SP3 I believe.
|
|
|
|
06-10-2010, 07:17 AM
|
#11
|
|
Member
Registered: Jul 2009
Posts: 31
Rep:
|
You were able to ping the Ubuntu machine from your XP machine previously. Try this again, and then check your arp tables again on both machines. If not used / machine is rebooted, they can not be there.
If the mac address again isn't appearing in the arp table then generically check your hardware. Otherwise I'd disable an re-enable the Ethernet port hardware in windows and check the drivers.
Otherwise check the device they connected together with. If it's your internet router; it might be worth checking there is no firewall rules between ports.
|
|
|
|
06-10-2010, 09:27 AM
|
#12
|
|
LQ Newbie
Registered: Jun 2010
Posts: 6
Original Poster
Rep:
|
It might be a trivial note, but the Windows to router is Wireless, Ubuntu to router is Ethernet.
Ubuntu and Windows have been rebooted. Pinged Ubunto and Windows from each to the other as suggested, and retried arp. Running arp reports address of Ubuntu from Windows and vice versa.
Router reports firewall is disabled. This, to me, is still suggestive of a Windows firewall problem.
Hmmm... I disable Windows firewall, and still cannot reach ssh. Very ponderous. I might require some on-site help.
Owen.
|
|
|
|
06-10-2010, 09:52 AM
|
#13
|
|
Member
Registered: Apr 2009
Location: Perth, Australia
Distribution: Ubuntu/CentOS
Posts: 208
Rep:
|
Quote:
Originally Posted by oo-ves
Apparently, every thing's fine on Ubuntu box:
Code:
owen@stage-hub:~$ netstat -aln|grep ":22"
tcp6 0 0 :::22 :::* LISTEN
|
sshd is not listening on ipv4.
Please run these commands, and post the output.
Code:
ip route
ifconfig
sudo netstat -tlnp
service ssh status
sudo iptables-save
Thanks,
SuperJediWombat
|
|
|
|
06-10-2010, 10:11 AM
|
#14
|
|
Member
Registered: Feb 2005
Location: Coventry, UK
Distribution: Home: Gentoo x86/amd64, Debian ppc. Work: Ubuntu, SuSe, CentOS
Posts: 343
Rep:
|
Doesn't most OpenSSH packages ship with all the "listening" options disabled by default in the config?
I know for sure that gentoo ships with the
#port 22
#192.168.0.0/24
both commented out for security reasons (Only enable exactly what you need). This means anyone who might of accidently installed openSSH in the past and then had it turned on randomly.
I notice no one else appears to have checked this yet - I'm not sure where the config file is on this distrobution, but I'd reccomend checking the listening options.
|
|
|
|
06-10-2010, 06:44 PM
|
#15
|
|
Member
Registered: Apr 2009
Location: Perth, Australia
Distribution: Ubuntu/CentOS
Posts: 208
Rep:
|
Ubuntu should be listening on 0.0.0.0:22 and :::22 by default.
Run this and post the output please:
Code:
grep -v '^#\|^$' /etc/ssh/sshd_config
|
|
|
|
| Thread Tools |
Search this Thread |
|
|
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
All times are GMT -5. The time now is 08:10 AM.
|
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|