bao-demos icon indicating copy to clipboard operation
bao-demos copied to clipboard

Cannot access Linux host through ssh FreeRTOS+Linux

Open e-nieto opened this issue 1 year ago • 4 comments

Good evening team!

I've been trying to access the Linux guest OS through ssh according to the Linux+FreeRTOS guide (IP 192.168.42.15).

The system is able to boot according to FreeRTOS on UART: FreeRtos_running

When trying to ping or ssh, host appears offline (100% packet drop, not even connection refused). However, nmap is able to detect the RPi4 as being online and being able to connect, but all ports are ignored:

Screenshot_ping_bao

I am on a fresh make from commit e6f1f6f

e-nieto avatar Jul 25 '23 15:07 e-nieto

@e-nieto Now that I've checked the readme files and the steps printed out when running make, I realize that something is not clear: the demo requires you to set up your machine's eth interface IP statically to something in the same private network. For example, 192.168.42.2/24.

Have you tried this?

josecm avatar Jul 25 '23 18:07 josecm

No I didn't, but makes sense. I've been able to connect to Raspbian with an adhoc in the past, so it didn't occur to me to hook it up to the router. I'll try tomorrow and report back :)

e-nieto avatar Jul 25 '23 21:07 e-nieto

I was able to autoassign a static IP to the interface (just as you suggested, I don't know why I tried to complicate myself with DHCP server + router + what have you) and it pings! I was able to log into root.

Nevertheless, is there a way to change the static IP before booting into the machine (through config.txt for example)? It would be great if someone is stuck or wants to integrate it to it's local network before trying to connect to it :)

e-nieto avatar Jul 26 '23 11:07 e-nieto

I'm guessing @yanjiew1 wrongly marked this issue on their PR since this is related to the Linux+FreeRTOS demo, not the Linux+Zephyr.

@e-nieto sorry for not taking a look at this sooner. Were you able to change the static IP? I believe this would be possible by chaing the ip parameter in the kernel command line defined in the device tree's chosen/bootargs property.

josecm avatar Oct 21 '23 11:10 josecm