Network at Boot - Does it ever time out?

February 18, 2023, 00:53

stormywaters2021

If I set my Pi to wait for Network at Boot, but for some reason my network goes out, will the Pi never boot at all, or will it timeout and just boot normally after awhile? I have it set to display the IP address on the terminal after boot, but sometimes it's blank after booting, but when I turn on Network at Boot, it works every time. I just don't want it to be completely locked out if the network goes down. Thanks!

illegitimate_egg

.bashrc is only executed when bash loads

illegitimate_egg

wpa_supplicant will have loaded before systemd finishes initializing

stormywaters2021

Once I enabled "Network at Boot", it always displays the IP - rather than only showing when I connect via SSH

illegitimate_egg

wdym Network at Boot?

stormywaters2021

If you go sudo raspi-config and do System Settings > S6: Network at Boot it says "Would you like boot to wait until a network connection is established?"

illegitimate_egg

That doesn't make sense

illegitimate_egg

The bootloader never touches the wifi stack

illegitimate_egg

It loads vmlinuz into memory

illegitimate_egg

The only time it would ever touch the network stack is during a pxe boot

stormywaters2021

When I enable that, then my line in the bash.rc displays the IP address normally. If I don't do that, it's usually a blank line when it runs hostname -I

illegitimate_egg

It has a 10s timeout

illegitimate_egg

Network at boot

stormywaters2021

Oh where did you find that? I've been searching and haven't found any official answers

illegitimate_egg

Someone experimented

stormywaters2021

Ah, okay. I saw that thread, missed that comment.

stormywaters2021

So do you know why it wouldn't be displaying my IP address at boot if it's not waiting?

illegitimate_egg

Because the standard bootloader never touches the network stack?

stormywaters2021

So it connects to network after it finishes booting, normally?

illegitimate_egg

I think you and I have a different definition of booting

stormywaters2021

Well I'm an idiot, so that's entirely likely

illegitimate_egg

Well there are two definitions

illegitimate_egg

I think booting means that the bootloader has completed it's job and the kernel can now start

illegitimate_egg

I think that you think that booting is when the kernel has finished loading

stormywaters2021

My definition of booting is when I get the command prompt lol

illegitimate_egg

Which on linux means you technically never boot ;)

illegitimate_egg

Because linux doesn't have a command prompt

illegitimate_egg

It's called a tty

illegitimate_egg

and you technically have one from the very start

illegitimate_egg

You can input stuff into the tty once the shell has loaded

stormywaters2021

Like I said, I'm an idiot lol

illegitimate_egg

Not really

illegitimate_egg

There's a difference between being an idiot and not needing to know

illegitimate_egg

and also just not knowing something

stormywaters2021

Well thanks for your help. I am running my escape rooms almost entirely through Raspberry Pi's and SSH, so I've learned a lot about Linux over the last couple of years 😅

illegitimate_egg

ah ok

illegitimate_egg

I wrote an OS

illegitimate_egg

so

illegitimate_egg

yk

stormywaters2021

So we're basically the same 🙂

illegitimate_egg

yea

stormywaters2021

lmao okay well thanks for your assistance, I won't tie you up any more. Appreciate the help!

illegitimate_egg

No problem my guy