LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 08-18-2015, 06:02 PM   #16
MattFly
Member
 
Registered: Apr 2015
Posts: 98

Original Poster
Rep: Reputation: Disabled

Is there anyway to test and determine where's the trouble?
 
Old 08-18-2015, 06:34 PM   #17
michaelk
Moderator
 
Registered: Aug 2002
Posts: 25,703

Rep: Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896
I assume you were successful with connecting on the LAN side using another computer?

Post the output of the command:

nmap -p 22 your-external-IP-address
 
Old 08-18-2015, 07:02 PM   #18
MattFly
Member
 
Registered: Apr 2015
Posts: 98

Original Poster
Rep: Reputation: Disabled
Yes I was! heres's the output of the requested command:

Code:
Starting Nmap 6.47 ( http://nmap.org ) at 2015-08-18 21:01 BRT
Nmap scan report for ***************.xd-dynamic.algartelecom.com.br (**********)
Host is up (0.0093s latency).
PORT   STATE    SERVICE
22/tcp filtered ssh

Nmap done: 1 IP address (1 host up) scanned in 1.07 seconds
When I try to connect it gives me connection timed out, as it allways was.

Last edited by MattFly; 08-18-2015 at 07:06 PM.
 
Old 08-18-2015, 07:41 PM   #19
michaelk
Moderator
 
Registered: Aug 2002
Posts: 25,703

Rep: Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896
The state should be opened versus filtered. It looks like the router's firewall is still blocking port 22. I assumed you saved the settings in the router. I might reboot it just to make sure it loads the new configuration.
 
Old 08-18-2015, 07:48 PM   #20
frankbell
LQ Guru
 
Registered: Jan 2006
Location: Virginia, USA
Distribution: Slackware, Ubuntu MATE, Mageia, and whatever VMs I happen to be playing with
Posts: 19,324
Blog Entries: 28

Rep: Reputation: 6142Reputation: 6142Reputation: 6142Reputation: 6142Reputation: 6142Reputation: 6142Reputation: 6142Reputation: 6142Reputation: 6142Reputation: 6142Reputation: 6142
Maybe someone has addressed this, but I skimmed through the posts and, if it was there, I missed it.

If I remember correctly, Ubuntu does not include the ssh server by default, only the client. sshd needs to be installed from the repos. Once it is installed, you can check whether it is running by

Code:
$ ps -A | grep sshd
 1239 ?        00:00:00 sshd   <---returned if the ssh server is running.
If this is superfluous, my apologies.
 
Old 08-18-2015, 07:52 PM   #21
michaelk
Moderator
 
Registered: Aug 2002
Posts: 25,703

Rep: Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896
Code:
 ps ax | grep sshd
  430 ?        Ss     0:00 /usr/sbin/sshd -D
Its running...
 
Old 08-18-2015, 08:03 PM   #22
MattFly
Member
 
Registered: Apr 2015
Posts: 98

Original Poster
Rep: Reputation: Disabled
Now I tweaked a little bit and found something called dmz where I placed my notebook stable ip. I definitelly disabled my firewall. Not working yet:

Code:
root@matt-Vostro-5470:/home/matheus# nmap -p 22 ***.***.***.***

Starting Nmap 6.47 ( http://nmap.org ) at 2015-08-18 21:59 BRT
Nmap scan report for 191-054-216-231.xd-dynamic.algartelecom.com.br (***.***.***.***)
Host is up (0.0071s latency).
PORT   STATE    SERVICE
22/tcp filtered ssh

Nmap done: 1 IP address (1 host up) scanned in 0.71 seconds
root@matt-Vostro-5470:/home/matheus# ssh sshclient@***.***.***.*** -p 22 -vvv
OpenSSH_6.7p1 Ubuntu-5ubuntu1, OpenSSL 1.0.1f 6 Jan 2014
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: /etc/ssh/ssh_config line 19: Applying options for *
debug2: ssh_connect: needpriv 0
debug1: Connecting to ***.***.***.*** [***.***.***.***] port 22.
debug1: connect to address ***.***.***.*** port 22: Connection timed out
ssh: connect to host ***.***.***.*** port 22: Connection timed out
root@matt-Vostro-5470:/home/matheus#
Any Ideas left?

Last edited by MattFly; 08-18-2015 at 08:04 PM.
 
Old 08-18-2015, 08:15 PM   #23
michaelk
Moderator
 
Registered: Aug 2002
Posts: 25,703

Rep: Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896
Does not look like the router's port forwarding is working assuming everything else is. That is why I suggest rebooting it.
 
Old 08-18-2015, 08:24 PM   #24
MattFly
Member
 
Registered: Apr 2015
Posts: 98

Original Poster
Rep: Reputation: Disabled
Now I did rebooted and it stills the same problem.
 
Old 08-18-2015, 08:27 PM   #25
MattFly
Member
 
Registered: Apr 2015
Posts: 98

Original Poster
Rep: Reputation: Disabled
I saw somewhere that I can try connecting to my router using telnet and then trying to configure it. It was something useful for the d-link wireless where I read it. But when I tryied "telnet 192.168.0.1 80" It just took a while and returned conection closed by a unkown host ????
 
Old 08-18-2015, 08:32 PM   #26
MattFly
Member
 
Registered: Apr 2015
Posts: 98

Original Poster
Rep: Reputation: Disabled
Don't now if have something to do with that, provided that I can connect from my internal wlan, but here's one more thing:
Code:
$ sudo iptables -L -v -n --line-numbers
Chain INPUT (policy ACCEPT 99 packets, 10801 bytes)
num   pkts bytes target     prot opt in     out     source               destination         

Chain FORWARD (policy ACCEPT 0 packets, 0 bytes)
num   pkts bytes target     prot opt in     out     source               destination         

Chain OUTPUT (policy ACCEPT 109 packets, 10061 bytes)
num   pkts bytes target     prot opt in     out     source               destination
 
Old 08-18-2015, 10:08 PM   #27
MattFly
Member
 
Registered: Apr 2015
Posts: 98

Original Poster
Rep: Reputation: Disabled
Something else?
 
Old 08-19-2015, 08:13 AM   #28
michaelk
Moderator
 
Registered: Aug 2002
Posts: 25,703

Rep: Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896
Something is blocking the port but I can not tell if it is your router.
 
Old 08-19-2015, 08:52 AM   #29
MattFly
Member
 
Registered: Apr 2015
Posts: 98

Original Poster
Rep: Reputation: Disabled
I`ll make a test connecting my laptop directlly to my modem throught Lan (wired), then I'll test if ssh from my public ip. If that works the problem is with my router, if that don't there might be something wrong about my Isp, which i hope is not the case. I'm I right? I mean, provided all the situation that I did, this could locate where the throuble is going? Did i think right?
 
Old 08-19-2015, 09:18 AM   #30
michaelk
Moderator
 
Registered: Aug 2002
Posts: 25,703

Rep: Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896
Yes. I would turn on the laptop's firewall as a precautionary measure and as you posted have configured it for ssh. I would also recycle power on the MODEM first since many ISPs will only allow on IP address based on the devices MAC.

Last edited by michaelk; 08-19-2015 at 09:21 AM.
 
  


Reply



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



Similar Threads
Thread Thread Starter Forum Replies Last Post
How do you run graphical programs on the server, displayed on the server, with ssh? yellowbounder Linux - Newbie 4 10-13-2008 04:04 PM
Wireless Conection CaptainPugwash Linux - Newbie 1 07-27-2007 08:34 PM
ssh setting up port 22 conection refused TheBrick Linux - Networking 3 02-22-2007 08:57 AM
Fedora Core 6 doesn't detect the wireless conection as a wireless conection...? santiagosilva Linux - Wireless Networking 33 02-04-2007 08:07 AM
Slow wireless g conection sniff Linux - Wireless Networking 7 01-04-2005 10:50 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 05:38 PM.

Main Menu
Advertisement
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
Open Source Consulting | Domain Registration