New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Windows: "dial tcp 127.0.0.1:2828: connectex: No connection could be made" #32

Closed
tombh opened this Issue Jun 12, 2018 · 15 comments

Comments

Projects
None yet
10 participants
@tombh
Copy link
Member

tombh commented Jun 12, 2018

I don't how popular running Browsh on Windows is? But we might as well have it working if it's possible. At the moment Firefox crashes during boot, I don't know why.

Of course Windows users, as I suspect most users, will use Browsh over Mosh/SSH, where Browsh runs on a Linux VM.

@tombh tombh added the bug label Jun 12, 2018

@tombh

This comment has been minimized.

Copy link
Member

tombh commented Jul 9, 2018

As a user on Twitter reports, the issue seems to be;

dial tcp 127.0.0.1:2828: connectex: No connection could be made because the target machine actively refused it.

Which is Firefox's Marionette RPC. So this could be a port permissions error on Windows?

@dertuxmalwieder

This comment has been minimized.

Copy link

dertuxmalwieder commented Jul 9, 2018

For me, browsh starts fine but crashes instantly after Firefox has been started:

panic: runtime error: invalid memory address or nil pointer dereference◙[signal 0xc0000005 code=0x0 addr=0x8 pc=0x4b4cdd]◙◙goroutine 19 [running]:◙os.(*Process).signal(0x0, 0x7cd560, 0x91c3c8, 0xc0422b4070, 0x0)◙    .go:58 +0x2d◙(0x0, , :◙
C:\>

Sometimes it manages to display the "waiting for Firefox to connect" screen, at least.

Windows 10, Firefox 64 Bit.

@tombh

This comment has been minimized.

Copy link
Member

tombh commented Jul 10, 2018

Thanks for extra info

@janmechtel

This comment has been minimized.

Copy link

janmechtel commented Jul 10, 2018

Same herein Windows 10, Firefox 64 Bit.

  1. I kill all firefox processes
  2. Run browsh_1.2.3_windows_amd64

dial tcp 127.0.0.1:2828: connectex: No connection could be made because the target machine actively refused it.

  1. Run browsh_1.2.3_windows_amd64 again:
panic: runtime error: invalid memory address or nil pointer dereference
[signal 0xc0000005 code=0x0 addr=0x8 pc=0x4b4cdd]

goroutine 19 [running]:
os.(*Process).signal(0x0, 0x7d2540, 0x9233c8, 0xc042354070, 0x0)
	/home/travis/.gimme/versions/go1.10.3.linux.amd64/src/os/exec_windows.go:58 +


@jamespeace

This comment has been minimized.

Copy link

jamespeace commented Jul 10, 2018

I have the same problem like @janmechtel on Windows7

@ParasDPain

This comment has been minimized.

Copy link

ParasDPain commented Jul 10, 2018

Same here! And as a windows user I'd prefer running it natively than wrapped in mosh tbh

@Structed

This comment has been minimized.

Copy link

Structed commented Jul 10, 2018

Same here. I was using the -firefox option to specify the path for the x64 firefox executable.

When starting browsh via powershell, it opens a new Firefox window, spits out above panic message and the powershell process hangs. See screenshot
image

@tombh tombh changed the title Windows build doesn't seem to start Firefox very well Windows: "dial tcp 127.0.0.1:2828: connectex: No connection could be made" Jul 13, 2018

@tombh

This comment has been minimized.

Copy link
Member

tombh commented Jul 13, 2018

@janmechtel Thanks for clarifying. (1) is really the main problem, (2) is just the fact that Browsh was unable to close Firefox in the first attempt.

I'm afraid this isn't a top priority for me to fix. Mainly as Browsh's main target is to be run on a remote server (in order to get the bandwidth savings for people on slow/expensive bandwidth locally). Also I haven't used windows in nearly 20 years now, so I'm not at all familiar with how to start debugging this.

But I'll certainly leave this issue open. I'd love to see this fixed. Maybe there's someone else that has more Windows experience that can help?

@tombh

This comment has been minimized.

Copy link
Member

tombh commented Jul 13, 2018

We may have found a fix! @morrah discovered that after seeing the "dial tcp" error Firefox was indeed running in the background. So he tried running Browsh again but this time with the -use-existing-ff.

In which we have a workaround. The idea being that you need to have headless Firefox running before starting Browsh. You can do this in 1 of 2 ways:

  1. Manually start your Firefox from the CLI with these arguments --marionette --headless.
  2. Run Browsh as you normally would so it starts Firefox, then wait for it crash.

You should now be able to run Browsh with the -use-existing-ff argument.

@tombh tombh referenced this issue Jul 13, 2018

Closed

windows10 error #108

@tombh

This comment has been minimized.

Copy link
Member

tombh commented Jul 20, 2018

This should be formally fixed with a non-hacked solution as of v1.4.0. I'll reopen if this exact problem is reported again.

@tombh tombh closed this Jul 20, 2018

@Some-T

This comment has been minimized.

Copy link

Some-T commented Jul 28, 2018

Was having a look at this on Windows to see if I could get it working, noticed on virustotal.com it indicates the following:

https://i.gyazo.com/b2510770f2475e95af63c30a41e8fd64.png

Can anyone confirm if this is a false positive, please?

@tobimensch

This comment has been minimized.

Copy link
Collaborator

tobimensch commented Jul 28, 2018

@Some-T
It definitely is a false positive. Please post in #67 about this and not here though.

@MarioColuzzi

This comment has been minimized.

Copy link

MarioColuzzi commented Oct 1, 2018

  1. Opened CLI as Admin
  2. Run browsh_1.4.13_windows_amd64.exe

I got this error:

Error reading Windows registry: The system cannot find the file specified.

@tobimensch

This comment has been minimized.

Copy link
Collaborator

tobimensch commented Oct 2, 2018

@MarioColuzzi
Looks more like issue #217 than this one! Please post there.

@sergeevabc

This comment has been minimized.

Copy link

sergeevabc commented Dec 16, 2018

So sad it does not work on Windows 7.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment