SlackwareThis Forum is for the discussion of Slackware Linux.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Quick one, I'm finding on this one box (8.1) that when machine is rebooted the IP address changes back to a 192.*
when I run /etc/rc.d/rc.inet1 it again sets it us as intended.
Any ideas where to look to see why this is happening?
rc.inet1 is executable and does indeed set IP as intended when run.
I'm not near the machine but the rc.inet1 config is correct as in when run it sets the IP, NetMask and GW as I expect, but this should happen at boot time, as it does on all my other slackware variants but for some reason on this machine when rebooting, this is not happening and IP remains 192.whatver. Yet, I can login and run rc.inet1 and all is as expected.
What is your normal IP address for the computer? Do you notice any output from dhcpcd when you boot the machine? Has the machine always done this or did it just start happening recently?
Its a process machine, was never networked until recently (didnt need to be). The default IP would have been 192.168.1.1 (I think). The correct entries have been added to the rc.inet1 file (no rc.inet1.conf file on 8.1 I recal)
It is executable, when I run it, IP changes and all works as intended until reboot.
dhcpd not running
can't always be near mahicne when rebooted, part of my issue and dmesg doesnt show much or far enough back to boot.
Does the I ever change? Else why not set it statically (not sure if that's what you did already), and after that even make the relevant files non writable?
Last edited by Didier Spaier; 08-01-2015 at 06:23 AM.
I'm not so sure would be best idea to make rc.inet1 non writable, but guess I could backup and do so.
I'll test rebooting on Mon and see if I can see where it is defaulting back to 192.168. I'm assuming it must be happening after rc.inet1 is run as when I run that manually, it does as expected and sets IP etc.
Maybe you could run a grep in the rc.d directory for 192.168 and see if something else sets it later (like rc.local). Can you also post your rc.inet1 file?
Sorry if I'm not correct on files/folders. I didn't start using Slack until the 10 series, so I have no experience with Slack 8 (and even if I did, it would've been long enough ago I doubt I'd remember it very well).
The box has never been able to mount a usb stick, so getting any files from there isnt so easy, but thats another story. It is networked but not to the outside world so to speak.
That said, I checked all of the rc.d dir and found nothing that looked as though it was changing the IP, nothing in rc.local (related anyway).
My dirty work around was to cron rc.inet1 but that gives me shivers LOL
I had hoped there would be a log somewhere that showed IP changes etc, but never really had the need for such before and been running slack for too many years.
I had hoped there would be a log somewhere that showed IP changes etc
There isn't one, but that doesn't prevent you from making your own. Instead of thinking of the init system as a black box, just think of it as some dodgy shell scripts that need debugging, because that's exactly what it is. Edit rc.M and/or rc.inet1 to write stuff to /tmp. Read, digest, refine, repeat, understand, solve. And then give thanks unto "Bob" that Slackware-8.1 did not feature systemd.
Here's a start to get you thinking. I won't tell you exactly what edits to make because strangely enough I find myself without access to a Slackware-8.1 system this morning.
Code:
echo "rc.inet1 called at $(date)" >> /tmp/inet1-debug.txt
ifconfig -a >> /tmp/inet1-debug.txt
[...]
echo "rc.inet1 finished at $(date)" >> /tmp/inet1-debug.txt
ifconfig -a >> /tmp/inet1-debug.txt
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.