LinuxQuestions.org
Support LQ: Use code LQCO20 and save 20% on CrossOver Office
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices

Reply
 
LinkBack Search this Thread
Old 11-20-2009, 04:47 PM   #1
FredGSanford
Member
 
Registered: Nov 2005
Location: USA
Distribution: Mageia 1
Posts: 907
Blog Entries: 5

Rep: Reputation: 73
Computers Won't Connect


How do I get my tower system to see my netbook using Mandriva 2010 & Gnome on both machines. When I click the Network in Nautilas, and choose the netbook, I get "server refuse to connect message".

I also have an imac with osx and the tower connects to the imac without problems. Am I missing some software for this?

When I tried ssh into the netbook I get "refuse to connect". Both PC machines have the ssh-server & client installed. Pinging both machines work.

Any ideas/suggestions?
 
Old 11-20-2009, 05:12 PM   #2
ShadowCat8
Member
 
Registered: Nov 2004
Location: Arcadia, CA
Distribution: Gentoo, Sabayon (RedHat4.x-9.x, FedoraCore 1.x-4.x, Debian Potato-Sarge, LFS 6.0, etc.)
Posts: 123

Rep: Reputation: 29
Sounds like a configuration issue with the Netbook.

What happens when you try the following commands on the Netbook?:
Quote:
$ ifconfig

eth0 Link encap:Ethernet HWaddr 00:00:00:00:00:00
inet addr:<IP Address> Bcast:192.168.1.255 Mask:255.255.255.0
inet6 addr: 0000::0000:0000:0000:0000/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:9392505 errors:0 dropped:0 overruns:0 frame:0
TX packets:9370187 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:3282310928 (3.0 GiB) TX bytes:6887567297 (6.4 GiB)
Memory:d3200000-d3220000

$ ssh <use above IP Address>
Let us know.
 
Old 11-20-2009, 05:39 PM   #3
FredGSanford
Member
 
Registered: Nov 2005
Location: USA
Distribution: Mageia 1
Posts: 907
Blog Entries: 5

Original Poster
Rep: Reputation: 73
Yes, it show the netbook IP Address. The netbook is connected by wireless card. It's an Acer Aspire One.

When I tried ssh into the netbook I get "ssh 192.168.0.000
ssh: connect to host 192.168.0.000 port 22: Connection refused".

I replaced the real ip string.

Last edited by FredGSanford; 11-20-2009 at 05:42 PM.
 
Old 11-20-2009, 07:58 PM   #4
Web31337
Member
 
Registered: Sep 2009
Location: Russia
Distribution: Gentoo, LFS
Posts: 398
Blog Entries: 72

Rep: Reputation: 65
the only idea: ssh is down?
connection refused means there is no service running on port.
do netstat -antp | grep :22 at your netbook and see if it listens.
optionally try connecting other port if you run something else there(for instance webserver listening tcp port 80) and see if it also refuses connection, that will tell then that wireless connection not working as expected.
 
Old 11-20-2009, 08:09 PM   #5
jschiwal
Moderator
 
Registered: Aug 2001
Location: Fargo, ND
Distribution: SuSE AMD64
Posts: 15,263

Rep: Reputation: 561Reputation: 561Reputation: 561Reputation: 561Reputation: 561Reputation: 561
Run "sudo /sbin/chkconfig sshd" on the server to see if the ssh daemon is running.

Check the permissions of your home directories and your ~/.ssh directories. They can't be world readable.

Check your /etc/ssh/sshd_config settings. After fresh installing a new distro, I had a problem connecting. The problem is that my "AllowUsers" configuration entry had my hostname instead of the hostname.domainpart that was in /etc/hosts. Using ssh user@host.domain worked.

To double check connectivity, try "telnet hostname 22". If you see something like:
telnet hpmedia 22
Trying 192.168.1.101...
Connected to hpmedia.
Escape character is '^]'.
SSH-2.0-OpenSSH_5.2

Then the service is running. If you can't connect, look at your firewall settings.

Try "ssh -vv user@host". This will print debug information.

Last edited by jschiwal; 11-21-2009 at 05:05 AM. Reason: typo fix
 
Old 11-20-2009, 08:25 PM   #6
Web31337
Member
 
Registered: Sep 2009
Location: Russia
Distribution: Gentoo, LFS
Posts: 398
Blog Entries: 72

Rep: Reputation: 65
good advice but anyway "connection refused" is "connection refused", telling us there is no actual service on port so there may be three reasons for that:
1. network link is broken... in a real weird way but since it's wireless this is not so weird;
2. no SSHd running on netbook;
3. SSHd runs on other port! see what jshiwal suggests.
ssh user@host -p <PORT> or telnet host <PORT> or nc host <PORT>(netcat, additional utility not in standard utils list) with port 22 will tell for sure. If sshd is really running on port 22 then there must be something with link, it can't be other way. i give up if it is. ^_^
 
Old 11-21-2009, 05:08 AM   #7
jschiwal
Moderator
 
Registered: Aug 2001
Location: Fargo, ND
Distribution: SuSE AMD64
Posts: 15,263

Rep: Reputation: 561Reputation: 561Reputation: 561Reputation: 561Reputation: 561Reputation: 561
Web31337: Don't give up before checking the firewall.
 
Old 11-21-2009, 07:19 AM   #8
FredGSanford
Member
 
Registered: Nov 2005
Location: USA
Distribution: Mageia 1
Posts: 907
Blog Entries: 5

Original Poster
Rep: Reputation: 73
I checked mandriva control center and it seems sshd was not started on both the tower & netbook, so I started them.

I did uncomment port 22 and added the IP addresses to both machine's /etc/ssh/sshd_config

Below is from netbook

[ghostdawg@localhost ~]$ netstat -antp | grep :22
(Not all processes could be identified, non-owned process info
will not be shown, you would have to be root to see it all.)
[ghostdawg@localhost ~]$ su -
Password:
[root@localhost ~]# netstat -antp | grep :22
[root@localhost ~]#


This is using the tower. When I use nautilas to access the imac, which will connect using nautilas, then I type the netstat command, I get information.

[root@localhost ~]# netstat -antp | grep :22
tcp 0 0 192.168.1.102:47799 192.168.1.100:22 ESTABLISHED 9135/ssh
tcp 0 0 192.168.1.102:47798 192.168.1.100:22 ESTABLISHED 8319/ssh

The netbook nautilas doesn't show the Macs at all in the network pane. Should it?

Last edited by FredGSanford; 11-21-2009 at 07:59 AM.
 
Old 11-21-2009, 09:50 AM   #9
Web31337
Member
 
Registered: Sep 2009
Location: Russia
Distribution: Gentoo, LFS
Posts: 398
Blog Entries: 72

Rep: Reputation: 65
what are the results of testing this on other port/testing other service with telnet? did you restart sshd service after config update?
the general rule is to provide as more information as possible. paste of sshd_config would be in place.
--
upd:
2 jschiwal: yeah, right. but configuration of firewall that rejects(TCP*RST) not drops packets is for advanced needs and usually made by hand =) so we'd already knew about it from FredGSanford.

Last edited by Web31337; 11-21-2009 at 10:03 AM.
 
Old 11-21-2009, 11:10 AM   #10
FredGSanford
Member
 
Registered: Nov 2005
Location: USA
Distribution: Mageia 1
Posts: 907
Blog Entries: 5

Original Poster
Rep: Reputation: 73
From tower system

$ netstat -antp | grep :80
tcp 0 0 192.168.1.102:58710 209.85.225.18:80 ESTABLISHED 25840/firefox

--------------------------------

$ cat /etc/ssh/sshd_config
# $OpenBSD: sshd_config,v 1.80 2008/07/02 02:24:18 djm Exp $

# This is the sshd server system-wide configuration file. See
# sshd_config(5) for more information.

# This sshd was compiled with PATH=/usr/local/bin:/bin:/usr/bin

# The strategy used for options in the default sshd_config shipped with
# OpenSSH is to specify options with their default value where
# possible, but leave them commented. Uncommented options change a
# default value.

Port 22
#AddressFamily any
ListenAddress 192.168.1.107
#ListenAddress ::

# Disable legacy (protocol version 1) support in the server for new
# installations. In future the default will change to require explicit
# activation of protocol 1
Protocol 2

# HostKey for protocol version 1
HostKey /etc/ssh/ssh_host_key
# HostKeys for protocol version 2
HostKey /etc/ssh/ssh_host_rsa_key
HostKey /etc/ssh/ssh_host_dsa_key

# Lifetime and size of ephemeral version 1 server key
#KeyRegenerationInterval 1h
#ServerKeyBits 1024

# Logging
# obsoletes QuietMode and FascistLogging
#SyslogFacility AUTH
#LogLevel INFO

# Authentication:

#LoginGraceTime 2m
PermitRootLogin without-password
#StrictModes yes
#MaxAuthTries 6
#MaxSessions 10

#RSAAuthentication yes
#PubkeyAuthentication yes
#AuthorizedKeysFile .ssh/authorized_keys

# For this to work you will also need host keys in /etc/ssh/ssh_known_hosts
#RhostsRSAAuthentication no
# similar for protocol version 2
#HostbasedAuthentication no
# Change to yes if you don't trust ~/.ssh/known_hosts for
# RhostsRSAAuthentication and HostbasedAuthentication
#IgnoreUserKnownHosts no
# Don't read the user's ~/.rhosts and ~/.shosts files
#IgnoreRhosts yes

# To disable tunneled clear text passwords, change to no here!
#PasswordAuthentication yes
#PermitEmptyPasswords no

# Change to no to disable s/key passwords
#ChallengeResponseAuthentication yes

# Kerberos options
#KerberosAuthentication no
#KerberosOrLocalPasswd yes
#KerberosTicketCleanup yes
#KerberosGetAFSToken no

# GSSAPI options
#GSSAPIAuthentication no
#GSSAPICleanupCredentials yes

# Set this to 'yes' to enable PAM authentication, account processing,
# and session processing. If this is enabled, PAM authentication will
# be allowed through the ChallengeResponseAuthentication and
# PasswordAuthentication. Depending on your PAM configuration,
# PAM authentication via ChallengeResponseAuthentication may bypass
# the setting of "PermitRootLogin without-password".
# If you just want the PAM account and session checks to run without
# PAM authentication, then enable this but set PasswordAuthentication
# and ChallengeResponseAuthentication to 'no'.
UsePAM no

# Accept locale-related environment variables
AcceptEnv LANG LC_CTYPE LC_NUMERIC LC_TIME LC_COLLATE LC_MONETARY LC_MESSAGES
AcceptEnv LC_PAPER LC_NAME LC_ADDRESS LC_TELEPHONE LC_MEASUREMENT
AcceptEnv LC_IDENTIFICATION LC_ALL

#AllowAgentForwarding yes
#AllowTcpForwarding yes
#GatewayPorts no
X11Forwarding yes
#X11DisplayOffset 10
#X11UseLocalhost yes
#PrintMotd yes
#PrintLastLog yes
#TCPKeepAlive yes
#UseLogin no
UsePrivilegeSeparation yes
#PermitUserEnvironment no
#Compression delayed
#ClientAliveInterval 0
#ClientAliveCountMax 3
#UseDNS yes
#PidFile /var/run/sshd.pid
#MaxStartups 10
#PermitTunnel no
#ChrootDirectory none

# no default banner path
#Banner none

# override default of no subsystems
Subsystem sftp /usr/lib/ssh/sftp-server

# Example of overriding settings on a per-user basis
#Match User anoncvs
# X11Forwarding no
# AllowTcpForwarding no
# ForceCommand cvs server

=========================================

Last edited by FredGSanford; 11-21-2009 at 11:12 AM.
 
Old 11-21-2009, 11:16 AM   #11
FredGSanford
Member
 
Registered: Nov 2005
Location: USA
Distribution: Mageia 1
Posts: 907
Blog Entries: 5

Original Poster
Rep: Reputation: 73
From netbook

# netstat -antp | grep :80
tcp 1 0 192.168.1.107:49772 4.23.45.126:80 CLOSE_WAIT 1117/gweather-apple

# $OpenBSD: sshd_config,v 1.80 2008/07/02 02:24:18 djm Exp $

# This is the sshd server system-wide configuration file. See
# sshd_config(5) for more information.

# This sshd was compiled with PATH=/usr/local/bin:/bin:/usr/bin

# The strategy used for options in the default sshd_config shipped with
# OpenSSH is to specify options with their default value where
# possible, but leave them commented. Uncommented options change a
# default value.

Port 22
#AddressFamily any
ListenAddress 192.168.1.102
#ListenAddress ::

# Disable legacy (protocol version 1) support in the server for new
# installations. In future the default will change to require explicit
# activation of protocol 1
Protocol 2

# HostKey for protocol version 1
HostKey /etc/ssh/ssh_host_key
# HostKeys for protocol version 2
HostKey /etc/ssh/ssh_host_rsa_key
HostKey /etc/ssh/ssh_host_dsa_key

# Lifetime and size of ephemeral version 1 server key
#KeyRegenerationInterval 1h
#ServerKeyBits 1024

# Logging
# obsoletes QuietMode and FascistLogging
#SyslogFacility AUTH
#LogLevel INFO

# Authentication:

#LoginGraceTime 2m
PermitRootLogin without-password
#StrictModes yes
#MaxAuthTries 6
#MaxSessions 10

#RSAAuthentication yes
#PubkeyAuthentication yes
#AuthorizedKeysFile .ssh/authorized_keys

# For this to work you will also need host keys in /etc/ssh/ssh_known_hosts
#RhostsRSAAuthentication no
# similar for protocol version 2
#HostbasedAuthentication no
# Change to yes if you don't trust ~/.ssh/known_hosts for
# RhostsRSAAuthentication and HostbasedAuthentication
#IgnoreUserKnownHosts no
# Don't read the user's ~/.rhosts and ~/.shosts files
#IgnoreRhosts yes

# To disable tunneled clear text passwords, change to no here!
#PasswordAuthentication yes
#PermitEmptyPasswords no

# Change to no to disable s/key passwords
#ChallengeResponseAuthentication yes

# Kerberos options
#KerberosAuthentication no
#KerberosOrLocalPasswd yes
#KerberosTicketCleanup yes
#KerberosGetAFSToken no

# GSSAPI options
#GSSAPIAuthentication no
#GSSAPICleanupCredentials yes

# Set this to 'yes' to enable PAM authentication, account processing,
# and session processing. If this is enabled, PAM authentication will
# be allowed through the ChallengeResponseAuthentication and
# PasswordAuthentication. Depending on your PAM configuration,
# PAM authentication via ChallengeResponseAuthentication may bypass
# the setting of "PermitRootLogin without-password".
# If you just want the PAM account and session checks to run without
# PAM authentication, then enable this but set PasswordAuthentication
# and ChallengeResponseAuthentication to 'no'.
UsePAM no

# Accept locale-related environment variables
AcceptEnv LANG LC_CTYPE LC_NUMERIC LC_TIME LC_COLLATE LC_MONETARY LC_MESSAGES
AcceptEnv LC_PAPER LC_NAME LC_ADDRESS LC_TELEPHONE LC_MEASUREMENT
AcceptEnv LC_IDENTIFICATION LC_ALL

#AllowAgentForwarding yes
#AllowTcpForwarding yes
#GatewayPorts no
X11Forwarding yes
#X11DisplayOffset 10
#X11UseLocalhost yes
#PrintMotd yes
#PrintLastLog yes
#TCPKeepAlive yes
#UseLogin no
UsePrivilegeSeparation yes
#PermitUserEnvironment no
#Compression delayed
#ClientAliveInterval 0
#ClientAliveCountMax 3
#UseDNS yes
#PidFile /var/run/sshd.pid
#MaxStartups 10
#PermitTunnel no
#ChrootDirectory none

# no default banner path
#Banner none

# override default of no subsystems
Subsystem sftp /usr/lib/ssh/sftp-server

# Example of overriding settings on a per-user basis
#Match User anoncvs
# X11Forwarding no
# AllowTcpForwarding no
# ForceCommand cvs server
 
Old 11-24-2009, 05:32 AM   #12
jschiwal
Moderator
 
Registered: Aug 2001
Location: Fargo, ND
Distribution: SuSE AMD64
Posts: 15,263

Rep: Reputation: 561Reputation: 561Reputation: 561Reputation: 561Reputation: 561Reputation: 561
It doesn't seem that your sshd service is running. compare:
Code:
 > sudo netstat -tlp
Active Internet connections (only servers)
Proto Recv-Q Send-Q Local Address           Foreign Address         State       PID/Program name
tcp        0      0 *:sunrpc                *:*                     LISTEN      1507/rpcbind
tcp        0      0 *:ssh                   *:*                     LISTEN      1946/sshd
...
Do your computers have more than one network interface? Is the ListenAddress IP address correct?

Last edited by jschiwal; 11-24-2009 at 09:01 AM.
 
Old 11-29-2009, 09:47 AM   #13
FredGSanford
Member
 
Registered: Nov 2005
Location: USA
Distribution: Mageia 1
Posts: 907
Blog Entries: 5

Original Poster
Rep: Reputation: 73
Ok thanks. I now have it working. Everything wasn't running, such as sshd.

I also uninstalled openssh and reinstalled it on both machines. That seems to have got it working.

Last edited by FredGSanford; 11-29-2009 at 09:54 AM.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Learning to connect computers Mol_Bolom Linux - Wireless Networking 4 11-13-2008 08:45 PM
Other computers cant connect to me? empiiricus Linux - Networking 1 05-17-2004 09:31 AM
How to connect 2 SuSE computers? 4levels Linux - Newbie 3 05-12-2004 02:29 AM
Help me..i want to connect to other win XP computers.. pulster2605 Linux - Networking 3 08-09-2003 04:33 AM
Trying to connect to other computers on the network hextex Linux - Networking 1 05-04-2001 08:13 PM


All times are GMT -5. The time now is 10:45 PM.

Main Menu
 
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: @linuxquestions
Open Source Consulting | Domain Registration