mersenneforum.org Connecting to the bash shell in Windows 10
 Register FAQ Search Today's Posts Mark Forums Read

 2018-04-07, 17:12 #1 wombatman I moo ablest echo power!     May 2013 180110 Posts Connecting to the bash shell in Windows 10 I'm trying to set up a CADO-NFS factoring system for set-and-forget runs. I have my desktop, a laptop, and 3 RPis (2 currently on the network). I have CADO-NFS downloaded, built, and confirmed working on each of the individual machines. I want to use the laptop as the server to which all the clients connect. The problem is how to actually connect to the Ubuntu bash shell. I followed EdH's instructions, and they work perfectly if I use one of the RPis as the "server" (only tested the setup, not to completion, for obvious reasons). With the laptop as the server, however, the clients aren't able to successfully connect. Anybody have any ideas how I might tackle this? I'm looking around to see if there's any solutions online, but I'm not seeing anything.
 2018-04-07, 20:52 #2 EdH     "Ed Hall" Dec 2009 Adirondack Mtns 32·523 Posts Are your client machines able to connect with your server via the IP for other tests than CADO-NFS? Is it possible your Win10 OS is masking, firewalling or proxying its IP (and/or the port) that the LAN sees when you use the shell? Is it possibly a permission issue in Win10. I'm reaching and probably asking ignorant questions, but I thought I'd toss them out anyway...
 2018-04-08, 00:15 #3 wombatman I moo ablest echo power!     May 2013 1,801 Posts I think you're right that it's some sort of masking/forwarding issue. For instance, I can use the scp command to transfer files to and from my Pi to my desktop or laptop, but only on the command line of the bash shell on the desktop or laptop. So the bash shell has no trouble making outbound connections--I just need to figure out how to get inbound connections.
2018-04-08, 02:24   #4
EdH

"Ed Hall"
Dec 2009

32×523 Posts

Quote:
 Originally Posted by wombatman I think you're right that it's some sort of masking/forwarding issue. For instance, I can use the scp command to transfer files to and from my Pi to my desktop or laptop, but only on the command line of the bash shell on the desktop or laptop. So the bash shell has no trouble making outbound connections--I just need to figure out how to get inbound connections.
What does hostname -I (that's an upper case i) show in the bash shell?

Is it the same address you're using with scp for inbound traffic?

How does it compare to ipconfig's IPv4 address in Win10?

When you scp out, is there a way to query what the incoming address is at the destination?

I just thought of something. You need an ssh-server on the machine you're trying to send to. It will send scp without the server installed, but it won't accept incoming scp. I use openssh-server on my Ubuntu machines.

2018-04-08, 03:25   #5
wombatman
I moo ablest echo power!

May 2013

70916 Posts

Quote:
 Originally Posted by EdH What does hostname -I (that's an upper case i) show in the bash shell? Is it the same address you're using with scp for inbound traffic? How does it compare to ipconfig's IPv4 address in Win10? When you scp out, is there a way to query what the incoming address is at the destination? I just thought of something. You need an ssh-server on the machine you're trying to send to. It will send scp without the server installed, but it won't accept incoming scp. I use openssh-server on my Ubuntu machines.
hostname gives:
Code:
192.168.1.4 2001:0:9d38:953c:3c3b:3958:9de6:cacd
The 192.168.1.4 matches the ip address assigned by the router and is what I have tried with scp.

Edit: Got openssh installed in the shell and set the port to 2222. I get a "connection timed out" when trying to ssh in from the Pi. I've set an inbound rule for the windows firewall to let connections through on the given port number, but that didn't help any.

I can install openssh-server in the bash shell and see if that helps.

Last fiddled with by wombatman on 2018-04-08 at 03:53

2018-04-08, 03:41   #6
chalsall
If I May

"Chris Halsall"
Sep 2002

3·3,529 Posts

Quote:
 Originally Posted by wombatman I can install openssh-server in the bash shell and see if that helps.
Please forgive me for this, but what part of the client/server model isn't clear?

You will also have to make sure that the standard port 22 is "open" on the server, and that the firewall(s) between them aren't blocking it. (Smart people, of course, map this to other places.)

2018-04-08, 03:55   #7
wombatman
I moo ablest echo power!

May 2013

70916 Posts

Quote:
 Originally Posted by chalsall Please forgive me for this, but what part of the client/server model isn't clear? You will also have to make sure that the standard port 22 is "open" on the server, and that the firewall(s) between them aren't blocking it. (Smart people, of course, map this to other places.)
See my edit in the previous post about open a chosen port and still being unable to connect.

As for what's not clear, I'm confused as to why I can make connections in one direction (Ubuntu/Windows 10 shell to Pi) and not the other (Pi to Ubuntu shell).

2018-04-08, 04:03   #8
chalsall
If I May

"Chris Halsall"
Sep 2002

3×3,529 Posts

Quote:
 Originally Posted by wombatman As for what's not clear, I'm confused as to why I can make connections in one direction (Ubuntu/Windows 10 shell to Pi) and not the other (Pi to Ubuntu shell).
From the Pi, can you "telnet [IP_Address] 22" and get a response such as "SSH-2.0-OpenSSH_7.5"?

If not, you might want to drill down on the firewalls. And perhaps "sniff the traffic" everywhere you can.

Please trust me on this... Been there; done that.

Last fiddled with by chalsall on 2018-04-08 at 04:04

2018-04-08, 05:43   #9
wombatman
I moo ablest echo power!

May 2013

1,801 Posts

Quote:
 Originally Posted by chalsall From the Pi, can you "telnet [IP_Address] 22" and get a response such as "SSH-2.0-OpenSSH_7.5"? If not, you might want to drill down on the firewalls. And perhaps "sniff the traffic" everywhere you can. Please trust me on this... Been there; done that.
Don't worry, I've been around here long enough to know that you know your stuff. I'm willing to try out whatever I need to.

I have to go to bed now, but I'll follow up tomorrow and let you know about telnet.

 2018-04-09, 00:09 #10 wombatman I moo ablest echo power!     May 2013 111000010012 Posts Ok! I got it somewhat figured out. I had something set up incorrectly in the windows firewall inbound rule that was causing the connection to be refused! I'm going to keep working on this, but I'll be back if I hit a speedbump again. Thanks for the telnet suggestion--that tipped off that the firewall wasn't set up properly! Edit: CADO-NFS WORKS! Last fiddled with by wombatman on 2018-04-09 at 00:18
2018-04-09, 02:10   #11
EdH

"Ed Hall"
Dec 2009

10010011000112 Posts

Quote:
 Originally Posted by wombatman Ok! I got it somewhat figured out. I had something set up incorrectly in the windows firewall inbound rule that was causing the connection to be refused! I'm going to keep working on this, but I'll be back if I hit a speedbump again. Thanks for the telnet suggestion--that tipped off that the firewall wasn't set up properly! Edit: CADO-NFS WORKS!
Excellent!!

 Similar Threads Thread Thread Starter Forum Replies Last Post clarkpetri Information & Answers 5 2017-10-15 17:22 henryzz Software 11 2017-07-28 21:24 ewmayer Software 5 2017-07-22 01:52 tinhnho Programming 2 2005-09-21 20:20 Xyzzy Linux 5 2004-01-26 10:31

All times are UTC. The time now is 06:12.

Sun Aug 14 06:12:53 UTC 2022 up 38 days, 1 hr, 2 users, load averages: 0.76, 0.86, 0.89