You are not logged in.

#1 2008-09-19 14:10:18

KimTjik
Member
From: Sweden
Registered: 2007-08-22
Posts: 715

How to increase/stop menu in netcfg on boot?

My farther does at times use an old laptop. I installed Arch on it. It won't be connected to any wireless net, but it's used in our internal network with static addresses at work, and might also be connected to a personal dhcp configured one. Thus I installed and configured netcfg with those two profiles. Now to the question:

- at boot the menu is shown, but only for 2 to 3 seconds; how to increase that time, or even stop until a choice is done?

Offline

#2 2008-09-19 14:17:08

piotrk
Member
From: Raciążek/Poland
Registered: 2008-09-16
Posts: 52
Website

Re: How to increase/stop menu in netcfg on boot?

which menu?Do you mean about grub menu ?if grub then edit :

/boot/grub/menu.lst

and change line with:

timeout

for more seconds

if not grub then use key Pause(break)

Offline

#3 2008-09-19 14:47:38

KimTjik
Member
From: Sweden
Registered: 2007-08-22
Posts: 715

Re: How to increase/stop menu in netcfg on boot?

No, I'm talking about netcfg: http://www.archlinux.org/packages/core/i686/netcfg/

An option is to enable "menu" to manually select your network profile. That's what I'm trying to figure out.

Reason: it's an old laptop so you might want to just start it and leave while it's booting (nothing is optimized so udev is taking it's time). Thus it could be convenient to have it stop at the netcfg-menu. Why? Just to make it easier for my dad, since he then doesn't need to run netcf-menu from a terminal.

Offline

#4 2008-09-21 22:10:45

KimTjik
Member
From: Sweden
Registered: 2007-08-22
Posts: 715

Re: How to increase/stop menu in netcfg on boot?

I start to think my question is stupid and I overlooked something obvious, because I get no suggestions or answers.

Please, tell me at least if there's such an option or not. I will be grateful.

Offline

#5 2008-09-21 23:51:45

Profjim
Member
From: NYC
Registered: 2008-03-24
Posts: 658

Re: How to increase/stop menu in netcfg on boot?

Look at the code for netcfg-menu. It's just a bash script. There's a block of code beginning:

dialog --timeout

What appears after the "--timeout"? On my system it's "$TIMEOUT" and a few lines higher up there's a line:

TIMEOUT="${1:-0}"

Which means set TIMEOUT to paramater 1, if it was supplied and isn't empty, else set it to 0. Calling dialog --timeout 0 has the effect of waiting forever, I think. So you want to get TIMEOUT set to zero.

Your code may be different than mine because you may have a different install of netcfg, and also because I've been hacking around in my netcfg code and so it doesn't match the standard install anymore. But basically, you want to change that script so that TIMEOUT=0. Easiest is to add a line:

TIMEOUT=0

just before the "dialog --timeout..." line.

Offline

#6 2008-09-22 07:59:21

KimTjik
Member
From: Sweden
Registered: 2007-08-22
Posts: 715

Re: How to increase/stop menu in netcfg on boot?

Thank you very much Profjim!

I've been looking at these scripts but since I haven't been able yet to get time, as I plan, to at least learn bash and python (or ruby?) I wasn't able to figure it out. Believe me I do as always try as hard as I can before asking. I understand that many Arch users are quite good in code, but obviously not everyone (pointing all fingers at my self smile ).

Thanks for your explanation I might even learn a bit more.

Offline

#7 2008-09-22 08:56:25

Profjim
Member
From: NYC
Registered: 2008-03-24
Posts: 658

Re: How to increase/stop menu in netcfg on boot?

Bash scripting is a baroque art. There's a "Bash Reference Manual" (I think it's just the "info" pages for bash, but I found it by googling, and the "Advanced Bash Scripting Guide", which together will tell you more than you should ever need to know. But better to start off more gently, with Python. I love Python, it's very clean and I think it'd be a (relatively) easy language to learn first.

Offline

Board footer

Powered by FluxBB