weaveworks / scope

Monitoring, visualisation & management for Docker & Kubernetes

Home Page:https://www.weave.works/oss/scope/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

I can't get it working

YouveGotMeowxy opened this issue · comments

commented

It says zero config, but for the life of me I can't get it working, lol..

Here's my Compose file:

version: '3'
services:
  scope:
    image: weaveworks/scope
    container_name: scope
    hostname: scope
    network_mode: "host"
    ports:
      - "4040:4040/tcp"
    pid: "host"
    privileged: true
    labels:
      - "works.weave.role=system"
    volumes:
      - "/var/run/docker.sock:/var/run/docker.sock:rw"
    command:
      - "--probe.docker=true"
      - "--weave=false"

When I run it, I can't get to the page; nothing but:

This site can’t be reached

and looking at my open ports on the machine, port 4040 isn't open.

Here's the log shown in Portainer once the container is up:

<app> INFO: 2019/11/01 20:07:38.902524 app starting, version 1b78a035, ID 49a322caaa5b0c7c

<app> INFO: 2019/11/01 20:07:38.902608 command line args: --mode=app --probe.docker=true --weave=false

<app> INFO: 2019/11/01 20:07:38.903132 Basic authentication disabled

time="2019-11-01T20:07:38Z" level=info msg="publishing to: 127.0.0.1:4040"

<probe> INFO: 2019/11/01 20:07:38.907016 Basic authentication disabled

<probe> INFO: 2019/11/01 20:07:38.913714 command line args: --mode=probe --probe.docker=true --weave=false

<probe> INFO: 2019/11/01 20:07:38.913847 probe starting, version 1b78a035, ID 565e04044aa1ece7

<app> INFO: 2019/11/01 20:07:38.920779 listening on :4040

<probe> INFO: 2019/11/01 20:07:38.965455 Control connection to 127.0.0.1 starting

<probe> WARN: 2019/11/01 20:07:39.034244 Error setting up the eBPF tracker, falling back to proc scanning: cannot open kprobe_events: open /sys/kernel/debug/tracing/kprobe_events: no such file or directory

<probe> ERRO: 2019/11/01 20:07:39.035159 plugins: problem loading: no such file or directory

<probe> INFO: 2019/11/01 20:07:39.082050 Publish loop for 127.0.0.1 starting

<probe> ERRO: 2019/11/01 20:07:43.943914 DNSSnooper: error decoding packet: qname '0x40' - RFC 2673 unsupported yet (data=6c index=12)

<probe> ERRO: 2019/11/01 20:07:43.943944 DNSSnooper: error decoding packet: qname '0x40' - RFC 2673 unsupported yet (data=6c index=12)

<probe> ERRO: 2019/11/01 20:07:43.948047 DNSSnooper: error decoding packet: qname '0x40' - RFC 2673 unsupported yet (data=6c index=12)

<probe> ERRO: 2019/11/01 20:07:43.948066 DNSSnooper: error decoding packet: qname '0x40' - RFC 2673 unsupported yet (data=6c index=12) (reached 4 occurrences, silencing)

<probe> WARN: 2019/11/01 20:08:04.553488 background /proc reader: full pass took 15.5041334s: 50% more than expected (10s)

For the record, I added the --weave=false to my compose file because previously the logs showed a bunch of errors about it, and said "if you're not running weave.net you can add the flag", and I thought I had read on the website that weave.net isn't required, so I did that to mute the errors.

What's wrong?

I'm running the latest versions on Scope, as well as Docker Desktop on Win 10 x64.

I also have some questions:

  • Does Scope NEED to be run in Host mode? Can it be run in Bridged mode instead?
  • Can I change the port from 4040 to something else?
  • When it's running, it doesn't show any published ports in Portainer?
  • The log shows it running on 127.0.0.1, does tit need to be running on 0.0.0.0 instead?

Sorry for the newbie questions, but I am a Docker newbie, lol.

Thanks for any help!
Kacey

When I run it, I can't get to the page; nothing but:

What URL did you use? On Windows you need to put the IP of the Docker VM in the browser.

Does Scope NEED to be run in Host mode? Can it be run in Bridged mode instead?

I think that is the same question as #3340. "Probably, with a little tweaking".

Can I change the port from 4040 to something else?

Yes. https://www.weave.works/docs/scope/latest/faq/#using-a-different-port

When it's running, it doesn't show any published ports in Portainer?

Since scope runs in the host network namespace, effectively all ports are published.

The log shows it running on 127.0.0.1, does tit need to be running on 0.0.0.0 instead?

It is.

<app> INFO: 2019/11/01 20:07:38.920779 listening on :4040

The references to 127.0.0.1 in the log are the probe talking to the app, and in the single-machine case that is fine.

I know this issue is for windows but if anyone has the same problem on Mac this may help you.
The trick is to remove network_mode: "host" which does not work on Mac docker/for-mac#1031

I also had to add the ports section "0.0.0.0:4040:4040", this enabled me to see weave in http://localhost:4040

Here is what works for me now

services:
  scope:
    image: weaveworks/scope:1.13.1
    pid: "host"
    privileged: true
    labels:
      - "works.weave.role=system"
    volumes:
      - "/var/run/docker.sock:/var/run/docker.sock:rw"
    command:
      - "--probe.docker=true"
    ports:
      - "0.0.0.0:4040:4040"

Sadly, if you follow the official documentation you will not be able to get it to work on Mac and go on a wild goose chase to fix it.

@jordotech please file a bug report noting what is wrong in the documentation.

Closing this as answered.

@jordotech please file a bug report noting what is wrong in the documentation.

Closing this as answered.

It was brought up in 2017 and contributors were made aware:
#2842 (comment)

But I will make a new issue

OK, I'll reopen #2842, thanks.

@jordotech would you like to make a PR to update the docs?

@bboreham sure thing

@bboreham correct me if I'm wrong but these docs do not appear to be part of this repo? https://www.weave.works/docs/scope/latest/installing/#using-docker-compose