Talk:Cron: Difference between revisions

From Alpine Linux
(gave reply to the query)
No edit summary
 
Line 1: Line 1:
Hello. My name is Grey, I am a beginner with Alpine Linux. I would like to know how I can change mac address on my PC running alpine linux 3.22 std. In Debian, I open the terminal and type "sudo crontab -e", I go to the bottom of the script and I add "@reboot macchanger -r wlan0", I save it, and when I reboot my PC, it changes mac address automatically. How can I do it in Alpine? Thank you very much for your kind help. Grey
Hello. My name is Grey, I am a beginner with Alpine Linux. I would like to know how I can change mac address on my PC running alpine linux 3.22 std. In Debian, I open the terminal and type "sudo crontab -e", I go to the bottom of the script and I add "@reboot macchanger -r wlan0", I save it, and when I reboot my PC, it changes mac address automatically. How can I do it in Alpine? Thank you very much for your kind help. Grey
:Hi [[User:Grey|Grey]], You can use the following command {{ic|$ apk search Cmd:macchanger}} to find the package that contains the command of interest i.e  {{ic|macchanger-1.7.0-r3}} . The output shows that the package name is {{pkg|macchanger}} and it can be installed using {{ic|# apk add macchanger}}. Please refer to [[apk]] page for more info. In future, please consider using other [[Support]] channels like [[IRC]] etc... -  [[User:Prabuanand|Prabuanand]] ([[User talk:Prabuanand|talk]]) 13:43, 15 September 2025 (UTC)
:Hi [[User:Grey|Grey]], You can use the following command {{ic|$ apk search Cmd:macchanger}} to find the package that contains the command of interest i.e  {{ic|macchanger-1.7.0-r3}} . The output shows that the package name is {{pkg|macchanger}} and it can be installed using {{ic|# apk add macchanger}}. Please refer to [[apk]] page for more info. In future, please consider using other [[Support]] channels like [[IRC]] etc... -  [[User:Prabuanand|Prabuanand]] ([[User talk:Prabuanand|talk]]) 13:43, 15 September 2025 (UTC)
:Hi [[User:Grey|Grey]], if you don't want to add an extra apk to your system, and you are using ifupdown-ng (should be default these days), add the following pre-up command to your stanza for your wlan0 interface.  For example:
  auto wlan0
  iface wlan0 inet dhcp
        .
        .
        .
        # **** To get our special mac addr *****
        pre-up ip link set $IFACE addr de:ad:be:ef:ca:fe
        .
        .
        .
       
Just another alternative.

Latest revision as of 16:45, 15 September 2025

Hello. My name is Grey, I am a beginner with Alpine Linux. I would like to know how I can change mac address on my PC running alpine linux 3.22 std. In Debian, I open the terminal and type "sudo crontab -e", I go to the bottom of the script and I add "@reboot macchanger -r wlan0", I save it, and when I reboot my PC, it changes mac address automatically. How can I do it in Alpine? Thank you very much for your kind help. Grey

Hi Grey, You can use the following command $ apk search Cmd:macchanger to find the package that contains the command of interest i.e macchanger-1.7.0-r3 . The output shows that the package name is macchanger and it can be installed using # apk add macchanger. Please refer to apk page for more info. In future, please consider using other Support channels like IRC etc... - Prabuanand (talk) 13:43, 15 September 2025 (UTC)
Hi Grey, if you don't want to add an extra apk to your system, and you are using ifupdown-ng (should be default these days), add the following pre-up command to your stanza for your wlan0 interface. For example:
 auto wlan0
 iface wlan0 inet dhcp
       .
       .
       .
       # **** To get our special mac addr *****
       pre-up ip link set $IFACE addr de:ad:be:ef:ca:fe
       .
       .
       .
       

Just another alternative.