Code Monkey home page Code Monkey logo

Comments (8)

si458 avatar si458 commented on July 3, 2024

If u go into the device, then console tab.

What's the output of running netinfo (can u share) ?

Does it include ur missing network device?

from meshcentral.

Nick2253 avatar Nick2253 commented on July 3, 2024

No, it doesn't include that device.

> netinfo
{
  Ethernet 2: {
    0: {
      address: "xxx"
      gateway: "xxx"
      fqdn: ""
      family: "IPv6"
      mac: "xxx"
      index: 10
      status: "up"
      type: "ethernet"
    }
    1: {
      address: "xxx"
      gateway: "xxx"
      fqdn: ""
      family: "IPv6"
      mac: "xxx"
      index: 10
      status: "up"
      type: "ethernet"
    }
    2: {
      address: "xxx"
      gateway: "xxx"
      fqdn: ""
      family: "IPv6"
      mac: "xxx"
      index: 10
      status: "up"
      type: "ethernet"
    }
    3: {
      address: "xxx"
      gateway: "xxx"
      fqdn: ""
      family: "IPv6"
      mac: "xxx"
      index: 10
      status: "up"
      type: "ethernet"
    }
    4: {
      address: "xxx"
      fqdn: ""
      family: "IPv4"
      netmask: "255.255.255.0"
      mac: "xxx"
      index: 10
      status: "up"
      type: "ethernet"
    }
  }
  Ethernet 3: {
    0: {
      address: "xxx"
      fqdn: ""
      family: "IPv6"
      mac: "xxx"
      index: 3
      status: "up"
      type: "ethernet"
    }
    1: {
      address: "xxx"
      fqdn: ""
      family: "IPv4"
      netmask: "255.255.255.0"
      mac: "xxx"
      index: 3
      status: "up"
      type: "ethernet"
    }
  }
  Loopback Pseudo-Interface 1: {
    0: {
      address: "::1"
      fqdn: ""
      family: "IPv6"
      mac: "00:00:00:00:00:00"
      index: 1
      status: "up"
      type: "loopback"
    }
    1: {
      address: "127.0.0.1"
      fqdn: ""
      family: "IPv4"
      netmask: "255.0.0.0"
      mac: "00:00:00:00:00:00"
      index: 1
      status: "up"
      type: "loopback"
    }
  }
  vEthernet (WSL): {
    0: {
      address: "xxx"
      fqdn: ""
      family: "IPv6"
      mac: "xxx"
      index: 34
      status: "up"
      type: "ethernet"
    }
    1: {
      address: "xxx"
      fqdn: ""
      family: "IPv4"
      netmask: "255.255.240.0"
      mac: "xxx"
      index: 34
      status: "up"
      type: "ethernet"
    }
  }
}

from meshcentral.

si458 avatar si458 commented on July 3, 2024

You say u have 'disabled all components for that interface' can u share screenshot?

What happens if u enable the IP component for the interface but leave it without an ip address then restart meshagent, does the interface appear?

I have a feeling we look for devices that have the IP component enabled, as I have interfaces with no ip addresses that show no problem?

from meshcentral.

Nick2253 avatar Nick2253 commented on July 3, 2024

You say u have 'disabled all components for that interface' can u share screenshot?
All the boxes are unchecked
image

What happens if u enable the IP component for the interface but leave it without an ip address then restart meshagent, does the interface appear?

You can't simply re-enable the interface without an IP address. It will attempt DHCP to get an IP address unless a static IP is configured (and since I have DHCP on that network, that's a no-go). However, I put a static link-local IP address on the interface, and I was able to see that interface using netinfo from the console.

snip:

  Ethernet 4: {
    0: {
      address: "169.254.20.30"
      fqdn: ""
      family: "IPv4"
      netmask: "255.255.0.0"
      mac: "xxx"
      index: 5
      status: "up"
      type: "ethernet"
    }
  }

After restarting the Mesh Agent, then it populates the info for Ethernet 4 in the Details screen.

I can't put it to sleep right now (it's currently processing), but I should be able to sleep it sometime in the next hour.

from meshcentral.

si458 avatar si458 commented on July 3, 2024

Right that's OK! Thank you!
I will check the code 2moz.
as I said I think it checks for the IP component being enabled and because it was disabled it doesn't find it!

from meshcentral.

Nick2253 avatar Nick2253 commented on July 3, 2024

It's a kludge, but it worked!

I'm going to close this because I can't imagine that this is really a bug for anyone but a very small minority who use 10Gbps network adapters that don't support WoL and want to actually use WoL.

Thank you for your awesome responsiveness! I've opened far more legitimate bug reports on many different projects, and it's usually weeks to months before anyone responds. The fact that we identified the problem and had a simple work-around in a few hours is nothing short of incredible!

from meshcentral.

si458 avatar si458 commented on July 3, 2024

OK no worries! I will still check the code tomorrow anyways just in case it is infact ignoring interfaces without ip addresses!?

from meshcentral.

si458 avatar si458 commented on July 3, 2024

Just had a quick night-time google.
We mimic the nodejs functions but in C with the meshagent https://nodejs.org/docs/latest-v18.x/api/os.html#osnetworkinterfaces
And the raw nodejs function only return interfaces with IP addresses, so I'm guessing it's only interfaces with the IP component enabled!

from meshcentral.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.