Linux - NetworkingThis forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.
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.
I 'm running Mandrake 6.1 kernel 2.2.13-7 and did not install any networking packages. I've installed the dhcpcd rpm package 1.3.17p19-3mdk. but every time i boot into Mandrake 6.1 i run the ifconfig eth0 command and its shows the ethernet information but no IP. I have to run the dhcpcd in order to get a dhcp assigned ip.
Maybe you shold try something like running as root "rc-update add net.eth0 default " that way the net will automatically start at boot time.
Hope this helps
In some configuration file you'll probably have to say it needs to use DHCP to start the interface.. now I am not familiar with mandrake of that age, so the best thing to do is find out how to configure your network
(on Redhat it has been /etc/sysconfig/network-scripts/ifcfg-eth0 for ages, but I am not sure if Mandrake is using this same structure).
aeruzcar, i'll try the rc-update command when i get home tonight. i was initially trying the update-rc command but I could not find it part of the distribution.
rhoekstra i did take a look at that script file, in fact my head is spinning from checking som many different scipt files. Can anyone of you please give me an overview or URL of how the linux startups and how these scripts are processed ? That would be greatly appreciated.
provided that the dhcpcd packages installed successfully. Hope that was some help...
Craig.
Thanks for the reply. But that does work. I don't get an IP but when linux boots thats the problem. you have to run the command you suggested to get an IP.
Last edited by justmehere; 07-29-2005 at 08:39 AM.
It's probably /etc/rc.d/init.d/networking that processes all network interfaces.. if you are able to follow what the scripts do, you can find out what scripts or configuration files are accessed at boot time for 'networking' to find out what it has to do.
Unfortunately, I do not have a URL for you...
I do have a question, though... Mandrake 2.2.13 ? for a reason? sounds really old to me. Is that referring to the kernel version? or is it a new version numbering of the Mandrake distros??
I did edit the network file /etc/rc.d/init.d/networking you mentioned but the issue still persist. i'm trying to pickup Linux using a user friendly version like Mandrake 6.1 kernel 2.2.13-7. I do have later distros like RedHat 7/8/9 and Slackware 8/9.
Thanks for the info on reading these script files any good tutorials on picking up the language ? is this command along the lines of C/Java ?
the problem was EXACTLY as you mentioned knowing how these scripts work. I misunderstood the documentation on editing the /etc/rc.d/init.d/network script. i had changed a comparison statement involving network variable back to what the documentation said and it works now. linux brings up the lo + eth0 on boot up with a DHCP assigned IP.
I suppose I'll have to read up on scripting...is that what they call shell scripting in all of those rc.* files ?
is that what they call shell scripting in all of those rc.* files ?
yup! and it's awesome, in my humble opinion. that's one reason i use slackware, because it forces me to do everything that way, and i end up learning so much about how my computer works.
here are a couple good resources for beginners:
RUTE User's Guide
- this is an excellent guide for any linux beginner, the section i linked to is on basic commands but i suggest picking up a copy for your shelf
mcd, thanks for the scripting resources. thats the reason i wanted to try out Mandrake 6.1 because I was told way back that its the distribution for beginners like me. I'll agree this is ONE way to learn linux by just trying out things. Though in my case I've been trying Linux on and off for the past 1-2 years but for some reason its starting to sink in now.
Notably it REALLY helps to have knowledgable Linux users here @ LQ
justmehere, I didn't tell to alter the script, and luckily I read that you have restored that script (if I understood you correctly).. it was just for you to analyse what you system 'does' at boot time to determine if the system is starting up... it compares variables and if . . . then . . . and so on.. If you see the dhcpcd command anywhere, you can see what it is comparing to determine whether or not to start dhcpcd... in that case you see which variable has to be set in your ifcfg-eth0 file for it to be started with dhcpcd... that is basically what I was referring at.. But I reckon you got that when you responded later on . . . That's good.. that's the best way to learn about the system....
I have had this often in the past... 'How do I make my system do . . .'.. I went to my /etc/init.d and went to look at the corresponding startup script to see how it determines what to do... works great!...
By the way, those files are all BASH scripts.
Also, the distro you are using or referring to are pretty old...
Distros are mostly freely downloadable... and the 2.2 kernel is very old, and as such is the construction of the script files and stuff...
I'd suggest moving to a new OS.. as not only you'll be having a newer kernel, the scripts are more and more developed to handle more sophisticated actions.
I am using Fedora... now Fedora, as well as SuSE, have a graphicly interfaced configuration tools to configure your Linux, but you are NOT forced to use those. You could decide (like me) to stay on the command line and find out about all the scripts like above...
But as newer distros use newer tools and scripts, I recommend moving to a newer OS...
Good luck!
what i have found is that the /etc/rc.d/rc* script file runs the script /etc/rc.d/init.d/network which checks for the presence of a /etc/sysconfig/network if there AND Network var is set to "yes" the susequent scripts are run (i.e. /etc/sysconfig/network-scripts/ifcfg-eth0.
I know that this distribution is quite old but I find that its easy naviagating around and installing RPM packages. Maybe its because I installed a barebone installation making it really simple for navigating the filesystem. I do plan to move on to a later distribution but for now I'm having fun playing around this configuration.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.