-   Linux - Newbie (
-   -   Making some commands run everytime I start Linux (Slack 9.1) (

Agna 03-22-2004 03:42 PM

Making some commands run everytime I start Linux (Slack 9.1)
Well I finally solved my problem (after a week trying:D ) regarding my NIC and my ISP rules wich I can not post a link to the thread due to my low post count And I did it this way
Installed new NIC linux drivers, And then

ifconfig eth0 down
macchanger --m= NEW MAC adress
Ifconfig eth0 UP
dhcpcd eth0

now typing all that (I know ain't to much but still) every time I boot into linux its the most comfortable way to get net access to inet. So theres some way to do it? A script? And how can I do it, Maybe Using CRON? And if you can point me to a how to would be cool too:D

Thanx in advance;)

aaa 03-22-2004 03:44 PM

Put it in /etc/rc.d/rc.local

Agna 03-22-2004 09:24 PM

ooops I found a problem, I edited the file and during th start up whe it trys to execute the macchange line it says "command not foun (or somthing pretty similar) and then everything stops. I think its cos Machchanger is a program I installed later and its not part of linux itself, the comand ifconfig hw to change the MAC adress can't change the mac adress on my NIC.
So now I need another idea on how to solve the problem starting up, since I can type but theres no bash, I mean I type and nothing happens. And any idea on how to solve the rc.local script?

If I boot with Slack CD2 I dont have startx, and I dont know how to edit the file since I see the HD but I cant navigete truh them.

Pres 03-22-2004 10:03 PM

Likely this is a PATH problem. Find out where your 'machchanger' binary lives (try 'whereis macchanger') and give the entire path explicitly in your script eg. /usr/local/share/applications ... just for example. You type in the path where it *really* lives .... it could just be a little spelling mistake too in your script - remember, case sensitivity. If the binary is all lower case, having an upper case 'M' will ruin things.

Agna 03-22-2004 10:27 PM

ok thanx gonna try that tomorrow, now could you give me a tip in how to edit the file again? Im stuck I can't get into linux, the booting process stops after the mac change line :(

aaa 03-23-2004 07:01 AM

Try booting in single-user mode by adding the 'single' option on the boot menu. Then use vi or pico to edit.

Agna 03-23-2004 07:35 PM

Great I solved it!!! Thanx for your help guys!

:D :D

jeofrey 08-26-2005 09:38 PM

please share to me your script
hi agna,

can you please share also to me the script that you made for macchanger becuase i have same isue with you.....

Thanks a lot,


All times are GMT -5. The time now is 07:07 AM.