Hi! I hope this is the right community to ask.

Next week I will be on the road for 5 Days for work. I have quite some spare time, so I thought I would dig up my raspberry project again and hopefully finish it.

I need it with me, because it controls some hardware, so a VPN to home does not work. So only option I could think of, is to connect the pi directly to my laptop via an ethernet cable. As far as I understood from some research is that I would need to install and run an DHCP server on my laptop, which they did not recommend. Alternatively they suggested to just take a router and plug both devices in there. I don’t really have a spare router, so that’s not an option either.

To be hones it confuses me a little, that there does not seem to be a standard for connecting to a device directly over a single cable and login with a user account.

Any recommendations how I can work on the pi like with ssh?

Thanks a lot!

  • lemmyingly@lemm.ee
    link
    fedilink
    English
    arrow-up
    1
    ·
    9 months ago

    Is there an easy method to know the self assigned IP address of the other machine if it’s run as headless?

    The only methods I can think of is using something like Wireguard to see what IP addresses are talking, or ping all 32k IP addresses to see which responds.

    • thecrotch@sh.itjust.works
      link
      fedilink
      English
      arrow-up
      1
      ·
      edit-2
      9 months ago

      The poster you’re replying to is suggesting a static IP in the apipa range, not an apipa assigned ip. You’d already know a static IP because you set it yourself.

    • rtxn@lemmy.world
      link
      fedilink
      English
      arrow-up
      1
      ·
      edit-2
      9 months ago

      Wireguard

      You mean Wireshark? It’s possible. You might even capture the DHCP exchange.

      The two best programs for the job are nmap and arp-scan.

      Nmap is like ping on steroids. You can use it for network discovery, port scanning, fingerprinting, and basic pentesting. As long as the pi can talk to the computer, nmap will sniff it out.

      ARP-scan works on the data link layer to identify hosts using ARP. It should be able to return the IP address of all ethernet devices even if they end up in different subnets. It took me a little over two minutes to scan a /16 subnet with one retry and 0.1 second timeout.

      If you are really concerned about the pi’s address, you should run a local DHCP server on the laptop. dnsmasq for Linux and Mac, but I have no idea what to use on Windows (other than a VM bridged to the ethernet interface).