Openembedded Core Discussions
 help / color / mirror / Atom feed
From: Laurentiu Palcu <laurentiu.palcu@intel.com>
To: openembedded-core@lists.openembedded.org
Subject: [PATCH] runqemu: fix networking issues
Date: Mon, 20 May 2013 13:09:44 +0300	[thread overview]
Message-ID: <1369044584-6053-1-git-send-email-laurentiu.palcu@intel.com> (raw)

After switching from ifconfig to ip, networking stopped working. This
commit contains the following fixes:

 * set a decent broadcast address for the tap device;
 * bring up the device;

Signed-off-by: Laurentiu Palcu <laurentiu.palcu@intel.com>
---
Apparently, the autobuilder has some magic into it because all the sanity tests
succeeded... So, I don't know why AB tests succeeded but on my machine, and several
others, networking was broken and couldn't connect into the qemu image. If I'm
missing something, please, do not hesitate to correct me. This patch fixes the
issue for me though.

Thanks,
Laurentiu

 scripts/runqemu-ifup |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/scripts/runqemu-ifup b/scripts/runqemu-ifup
index 8948153..108d9a4 100755
--- a/scripts/runqemu-ifup
+++ b/scripts/runqemu-ifup
@@ -100,7 +100,8 @@ if [ ! -x "$IPTABLES" ]; then
 fi
 
 n=$[ (`echo $TAP | sed 's/tap//'` * 2) + 1 ]
-$IFCONFIG addr add 192.168.7.$n/32 dev $TAP
+$IFCONFIG addr add 192.168.7.$n/32 broadcast 192.168.7.255 dev $TAP
+$IFCONFIG link set dev $TAP up
 
 dest=$[ (`echo $TAP | sed 's/tap//'` * 2) + 2 ]
 $ROUTE add -host 192.168.7.$dest $TAP
-- 
1.7.9.5




             reply	other threads:[~2013-05-20 10:28 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-05-20 10:09 Laurentiu Palcu [this message]
2013-05-20 15:35 ` [PATCH] runqemu: fix networking issues Stanacar, StefanX
2013-05-20 15:47   ` Khem Raj
2013-05-20 15:47 ` Khem Raj

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1369044584-6053-1-git-send-email-laurentiu.palcu@intel.com \
    --to=laurentiu.palcu@intel.com \
    --cc=openembedded-core@lists.openembedded.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox