You are not logged in.
Pages: 1
Hi,
I installed my system 4 years ago and it's working fine. Now I would like that the wireless interface is NOT brought up when starting the computer.
I know I could call sudo ip link wlpXsX down from a script to bring it down. But is there a way to avoid bringing it up in the first place?
I use netctl-auto and I would like to keep using it. Just that the interface should be down on boot.
The reason I want this is because I'm testing what happens (to me) when the default state is offline and I need to ask for
permission each time I need Internet access. I wrote this script for that purpose (requires fishshell and the at command) which works
fine. The only problem is that when I start the computer it's already online, which destroys my experiment :)
#!/bin/fish
# Script to request internet access for a number of minutes
if test (count $argv) -eq 2
set timestamp (date +"%F %R")
set minutes $argv[1]
set comment $argv[2]
set logline $timestamp $minutes $comment
echo $logline >> ~/internet.log
sudo ip link set wlpXsX up
echo "ip link set wlpXsX down" | sudo at now + $minutes minutes 2>/dev/null
else
echo "Usage: \$ gimme.fish [minutes] \"[reason]\""
endLast edited by rokidakota (2019-01-07 11:44:58)
Offline
That should be the netctl-auto@<your-interface>.service .
simplest method is probably to disable it, and start / stop the service manually or from your script.
check man 1 netctl-auto for details .
Last edited by Lone_Wolf (2019-01-07 12:19:17)
Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.
clean chroot building not flexible enough ?
Try clean chroot manager by graysky
Offline
Pages: 1