Closed mathie closed 9 years ago
does linux run echo hello world
do anything?
It doesn't output anything, but it exits cleanly:
> linux run echo hello world
> echo $?
0
sshing manually does have the desired effect:
> ssh -i $(pwd)/linux/id_rsa tc@$(linux ip) echo hello world
hello world
Would that suggest it's something to do with node wiring up the tty?
yes i think so - let me add some debugging output to ssh real quick
could try upgrading to 2.6.0 (latest) and run linux ssh --debug
? that should print the ssh command it is trying to spawn. maybe that will help us
Ah, now that's interesting. The problem appears to be down to my ssh configuration. I have ssh configured to multiplex sessions over a single connection -- mostly because it speeds up interaction with GitHub a little bit. Here's my configuration:
Host *
# Multiplex several connections to the same host over the same channel.
ControlMaster auto
ControlPersist 600
ControlPath ~/.ssh/control/%r@%h:%p.sock
If I disable that, then linux ssh
works. With it enabled, running linux ssh --debug
gives me:
> linux ssh --debug
spawning ssh [ '-v',
'-i',
'/Users/mathie/Development/Personal/linux/linux/id_rsa',
'-o',
'StrictHostKeyChecking=no',
'-o',
'LogLevel=ERROR',
'tc@192.168.64.4' ]
OpenSSH_6.9p1, LibreSSL 2.1.7
debug1: Reading configuration data /Users/mathie/.ssh/config
debug1: /Users/mathie/.ssh/config line 12: Applying options for *
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: /etc/ssh/ssh_config line 21: Applying options for *
debug1: auto-mux: Trying existing master
debug1: mux_client_request_session: master session id: 2
(I took the liberty of adding -v
to the ssh flags, too.) However, running exactly the same ssh command directly from the command line works:
> ssh -v -i /Users/mathie/Development/Personal/linux/linux/id_rsa -o StrictHostKeyChecking=no -o LogLevel=ERROR tc@$(linux ip)
OpenSSH_6.9p1, LibreSSL 2.1.7
debug1: Reading configuration data /Users/mathie/.ssh/config
debug1: /Users/mathie/.ssh/config line 12: Applying options for *
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: /etc/ssh/ssh_config line 21: Applying options for *
debug1: auto-mux: Trying existing master
debug1: mux_client_request_session: master session id: 2
__ __ __
/ \__/ \__/ \__ Welcome to HyperOS Linux! (Based on TinyCore Linux)
\__/ \__/ \__/ \ hyperos.io tinycorelinux.net
\__/ \__/ \__/
tc@boots-felix-buddy-peanut:~$
Weird, huh? I think that's enough to help me work around the problem, and we can probably put it down to a weird edge case configuration that's unlikely to trip anyone else up! Thank you for your prompt assistance! :smile:
@mathie nice sleuthing. we have talked about shipping our own ssh client for this reason, might get around to it someday!
This is probably the least useful bug report ever, but I thought I'd throw it out there, see if anyone else was seeing the same symptoms. Running on the GM seed of El Capitan, I've got a VM booting and it appears to be running (
ps
,status
, etc work fine). Howeverlinux ssh
just ... hangs -- doesn't exit, and doesn't give me a shell on the VM. I'm intuiting that the ssh connection has been established, since hittingctrl-c
doesn't do anything, but typing the ssh escape sequence (`\n~.') closes the ssh connection and exits.Interestingly, if I run the following:
it works, and I get a shell on the VM! Curious, eh?
Is there something I can do to furnish you with a more helpful bug report?