Ylianst / MeshCentral

A complete web-based remote monitoring and management web site. Once setup you can install agents and perform remote desktop session to devices on the local network or over the Internet.
https://meshcentral.com
Apache License 2.0
4.12k stars 553 forks source link

Raspberry Pi OS Lite (Legacy) Won't Connect With Static IP #4658

Closed UFOTyler closed 1 year ago

UFOTyler commented 1 year ago

I use Raspberry Pi 4's as SBC's (Session Border Controllers) for VoIP phone installations using 3CX. I install Meshcentral in order to SSH into them for maintenance reasons, or as relays for remote support. I haven't deployed a new one in some time, but recently I did and when I set a static IP in the "dhcpcd.conf" file, upon reboot the Pi will not connect back to the Meshcentral Server. As soon as I set it to DHCP (comment out the lines) , it connects backup after reboot. 3cx only supports the older Debian Buster Raspberry Pi OS, so that's why I use that version. I've tested with both the Lite version and the full GUI version.

Steps to reproduce the behavior:

  1. install Raspberry Pi OS (Legacy) with Raspberry Pi Imager
  2. Install meshcentral with Linux command
  3. set static IP in /etc/dhcpcd.conf
  4. Reboot

Example of what to put at the end of the conf file for static IP

interface [INTERFACE] static_routers=[ROUTER IP] static domain_name_servers=[DNS IP] static ip_address=[STATIC IP ADDRESS YOU WANT]/24

Server:

Remote Device:

si458 commented 1 year ago

i believe you might have a miss config in dhcpcd.conf - https://www.makeuseof.com/raspberry-pi-set-static-ip/

static_routers=[ROUTER IP] should be static routers=[ROUTER IP]

UFOTyler commented 1 year ago

Oh my, you would be correct. That's what I get for copy and pasting from a note I made years ago. I totally glanced over that when I was searching for solutions. Thank you. Problem seems to be solved.