LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 03-02-2015, 03:25 AM   #1
anon_16
LQ Newbie
 
Registered: Jan 2014
Posts: 14

Rep: Reputation: Disabled
Basic networking in custom initramfs


I have made a custom initramfs with the absolute minimum files required and I have compiled a Centos 7 kernel for it with most of the drivers and options built in. The purpose is to have a minimal OS without switching to a real root and remain in an embedded environment. I need to run simple network applications with very little memory usage.
I used this site for reference : http://wiki.gentoo.org/wiki/Custom_Initramfs
The initramfs boots fine and I am able to use all the utilities using busybox. I have built the ethernet card drivers into the kernel and they are recognized.
When I give a static IP address to the network interface and try to ping my laptop directly connected to it, it doesn't work. Both systems are in the same subnet.
On further inspection using Wireshark I found that the ARP request coming out of my initramfs system is jumbled (the destination IP is in the wrong byte order). If I manually set the MAC addresses of the systems in each other's arp cache table, the ping is successful. This means that there is some problem with the MAC address resolution in the initramfs.
Does anyone have any suggestions?
 
Old 03-02-2015, 06:14 AM   #2
Keith Hedger
Senior Member
 
Registered: Jun 2010
Location: Wiltshire, UK
Distribution: Void, Linux From Scratch, Slackware64
Posts: 3,171

Rep: Reputation: 861Reputation: 861Reputation: 861Reputation: 861Reputation: 861Reputation: 861Reputation: 861
You pobably need to ask this in the networking forum, ask a mod to move it for you
 
Old 03-02-2015, 06:32 AM   #3
anon_16
LQ Newbie
 
Registered: Jan 2014
Posts: 14

Original Poster
Rep: Reputation: Disabled
Alright, I've requested a switch to the Networking forum.
 
Old 03-02-2015, 07:14 AM   #4
michaelk
Moderator
 
Registered: Aug 2002
Posts: 25,926

Rep: Reputation: 6000Reputation: 6000Reputation: 6000Reputation: 6000Reputation: 6000Reputation: 6000Reputation: 6000Reputation: 6000Reputation: 6000Reputation: 6000Reputation: 6000
Moved: This thread is more suitable in Linux-Networkinig and has been moved accordingly to help your thread/question get the exposure it deserves.
 
Old 03-05-2015, 01:54 PM   #5
anon_16
LQ Newbie
 
Registered: Jan 2014
Posts: 14

Original Poster
Rep: Reputation: Disabled
Absolutely non-intuitive solution. I updated my kernel from 3.10.0-123.9.1.el7.x86_64 to 3.10.0-123.20.1.el7.x86_64 and compiled it with the same .config file. That solved the issue.
Note to self - Some problems have a straightforward solution. For all others, consider bashing your head on the keyboard until you chance upon it.
 
  


Reply

Tags
arp, embedded, initramfs, netwoking


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] initramfs genkernel vs custom kernel steve_pa Gentoo 8 01-25-2012 07:58 PM
Error while building initramfs image for custom kernel TDMBG Linux - Software 2 08-01-2008 05:14 PM
basic USB communication to a custom device emiddleton Linux - Hardware 2 07-17-2008 09:00 PM
basic networking Kumado Linux - Networking 9 07-14-2005 10:32 AM
basic networking jbclarkman Mandriva 1 01-17-2005 03:06 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 06:19 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration