LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
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
  Search this Thread
Old 02-07-2016, 07:02 PM   #1
lucmove
Senior Member
 
Registered: Aug 2005
Location: Brazil
Distribution: Debian
Posts: 1,432

Rep: Reputation: 110Reputation: 110
SSH'ing across machines on a home brew router


I replaced my TP-Link router with a PC running Linux, hostapd, dnsmasq etc.

On the old router, I used to be able to SSH from one AP client to another. On this new router, I can't. They're all inaccessible to each other. How can I recover that feature?

Note #1: I don't have any Windows machines, just Linux and Android, so I assume I don't need Samba to exchange files across machines. I just need SSH. In fact, blocking Windows machines would be a bonus.

Note #2: I am using this firewall script, but I could not SSH across machines even before I installed it. I am just mentioning it because it certainly is blocking something and should probably be taken into consideration for a potential solution to my problem.
 
Old 02-08-2016, 11:58 AM   #2
michaelk
Moderator
 
Registered: Aug 2002
Posts: 25,692

Rep: Reputation: 5894Reputation: 5894Reputation: 5894Reputation: 5894Reputation: 5894Reputation: 5894Reputation: 5894Reputation: 5894Reputation: 5894Reputation: 5894Reputation: 5894
Can we assume your devices are being assigned an IP address using DHCP and can access the internet? Are these all wireless devices or are some of them wired? Can the wireless devices ping the new router and ping other wireless devices?
 
Old 02-08-2016, 01:01 PM   #3
lucmove
Senior Member
 
Registered: Aug 2005
Location: Brazil
Distribution: Debian
Posts: 1,432

Original Poster
Rep: Reputation: 110Reputation: 110
* devices are being assigned an IP address using DHCP - check
* can access the internet - check
* all wireless devices - check
* the wireless devices can ping the new router and ping other wireless devices - check

I've got it all so far. What else do I need?
 
Old 02-08-2016, 01:31 PM   #4
michaelk
Moderator
 
Registered: Aug 2002
Posts: 25,692

Rep: Reputation: 5894Reputation: 5894Reputation: 5894Reputation: 5894Reputation: 5894Reputation: 5894Reputation: 5894Reputation: 5894Reputation: 5894Reputation: 5894Reputation: 5894
Are you trying ssh with a hostname or IP address? Are you using ports other than 22?
What happens when you try:

ssh name@IP_address
 
Old 02-08-2016, 02:03 PM   #5
lucmove
Senior Member
 
Registered: Aug 2005
Location: Brazil
Distribution: Debian
Posts: 1,432

Original Poster
Rep: Reputation: 110Reputation: 110
OK, I have a PC (Linux), a tablet (Android) and a phone (Android).

I just ran an SSH server on the tablet and it all worked. That's something I overlooked. But that's not the way I'm used to. I usually run a file explorer application on the phone and the tablet that can browse network folders. It can use Samba, which I did a long time ago, and it can use SSH. I prefer SSH now and it works on the TP-Link router, but won't work on the home brew router.

Each router assigns different IPs to the PC so I have to have a different configuration depending on which router I am using, but the two configurations are exactly the same except for the IP.

On the home brew router, the application complains:
"failed to connect to 10.40.40.21 (port 220) after 15000ms: isConnnnected failed: ECONNREFUSED (Connection refused)"
 
Old 02-08-2016, 02:04 PM   #6
Emerson
LQ Sage
 
Registered: Nov 2004
Location: Saint Amant, Acadiana
Distribution: Gentoo ~amd64
Posts: 7,661

Rep: Reputation: Disabled
Port 220?
 
Old 02-08-2016, 02:05 PM   #7
lucmove
Senior Member
 
Registered: Aug 2005
Location: Brazil
Distribution: Debian
Posts: 1,432

Original Poster
Rep: Reputation: 110Reputation: 110
Why not?
 
Old 02-08-2016, 02:06 PM   #8
Emerson
LQ Sage
 
Registered: Nov 2004
Location: Saint Amant, Acadiana
Distribution: Gentoo ~amd64
Posts: 7,661

Rep: Reputation: Disabled
It is reserved for IMAP, did you specifically configure your SSH daemon to listen on port 220?
 
Old 02-08-2016, 02:10 PM   #9
lucmove
Senior Member
 
Registered: Aug 2005
Location: Brazil
Distribution: Debian
Posts: 1,432

Original Poster
Rep: Reputation: 110Reputation: 110
Yes, I did. Never had a problem with that. I don't have IMAP. Never have and never will.
 
Old 02-08-2016, 02:11 PM   #10
lucmove
Senior Member
 
Registered: Aug 2005
Location: Brazil
Distribution: Debian
Posts: 1,432

Original Poster
Rep: Reputation: 110Reputation: 110
Is there some kind of security concern?
 
Old 02-08-2016, 02:27 PM   #11
Emerson
LQ Sage
 
Registered: Nov 2004
Location: Saint Amant, Acadiana
Distribution: Gentoo ~amd64
Posts: 7,661

Rep: Reputation: Disabled
Are you attempting root login? An upgrade may have disabled password based root logins.
Re: Port 220. I wouldn't bother changing port on LAN machines. You can always change the port with port forwarding for internet access if you wish.
 
Old 02-08-2016, 02:30 PM   #12
lucmove
Senior Member
 
Registered: Aug 2005
Location: Brazil
Distribution: Debian
Posts: 1,432

Original Poster
Rep: Reputation: 110Reputation: 110
root login is disabled. At any rate, remember that everything works when I associate all the stuff to the old router.
 
Old 02-08-2016, 02:32 PM   #13
lucmove
Senior Member
 
Registered: Aug 2005
Location: Brazil
Distribution: Debian
Posts: 1,432

Original Poster
Rep: Reputation: 110Reputation: 110
About port forwarding, I can't do that. I am very network-illiterate. I also don't know how to assign fixed IPs to each client, like I used to do on the TP-Link router.
 
Old 02-08-2016, 02:33 PM   #14
michaelk
Moderator
 
Registered: Aug 2002
Posts: 25,692

Rep: Reputation: 5894Reputation: 5894Reputation: 5894Reputation: 5894Reputation: 5894Reputation: 5894Reputation: 5894Reputation: 5894Reputation: 5894Reputation: 5894Reputation: 5894
Quote:
On the home brew router, the application complains:
What application? Which device is the server and which is the client?

Quote:
I just ran an SSH server on the tablet and it all worked.
What device was the client?
 
Old 02-08-2016, 02:39 PM   #15
lucmove
Senior Member
 
Registered: Aug 2005
Location: Brazil
Distribution: Debian
Posts: 1,432

Original Poster
Rep: Reputation: 110Reputation: 110
Quote:
Originally Posted by michaelk View Post
On the home brew router, the application complains:
What application? Which device is the server and which is the client?
The client application is called X-plore. It's an Android app. The server is regular sshd (openssh) on a Debian Linux box.

Quote:
Originally Posted by michaelk View Post
I just ran an SSH server on the tablet and it all worked.
What device was the client?
That was a quick test. I ran SSH Server on the tablet and connected to it from the Linux PC. That worked.
 
  


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
linux home router reboot itself when NAT'ing for large number of connections asimov Linux - Networking 8 03-01-2008 09:22 AM
Passwordless SSH on machines which have the same NFS home region cmetelko Linux - Software 1 06-18-2007 09:35 AM
want to ssh/ftp to home machine (Slack) from office through home router fincher69 Linux - Networking 2 09-21-2005 10:55 PM
SSH'ing between two computers through a router kz26 Linux - Networking 6 08-14-2005 11:09 PM
SSH-ing to computer behind router ar1 Linux - Networking 1 01-09-2005 10:15 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 08:54 AM.

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