All of lore.kernel.org
 help / color / mirror / Atom feed
* [meta-networking][PATCH:V3] vlan: Add vlan recipe
@ 2013-06-27  9:51 lei.yang
  2013-06-27 11:00 ` Paul Barker
  0 siblings, 1 reply; 5+ messages in thread
From: lei.yang @ 2013-06-27  9:51 UTC (permalink / raw)
  To: lei.yang, Joe.MacDonald, openembedded-devel

From: Lei Yang <lei.yang@windriver.com>

A 802.1q vlan support program,which can be used by virt-test

Signed-off-by: Lei Yang <lei.yang@windriver.com>
---
 meta-networking/recipes-support/vlan/vlan_1.9.bb |   23 ++++++++++++++++++++++
 1 files changed, 23 insertions(+), 0 deletions(-)
 create mode 100755 meta-networking/recipes-support/vlan/vlan_1.9.bb

diff --git a/meta-networking/recipes-support/vlan/vlan_1.9.bb b/meta-networking/recipes-support/vlan/vlan_1.9.bb
new file mode 100755
index 0000000..dea3306
--- /dev/null
+++ b/meta-networking/recipes-support/vlan/vlan_1.9.bb
@@ -0,0 +1,23 @@
+SUMMARY = "802.1q vlan support program"
+HOMEPAGE = "http://www.candelatech.com/~greear/vlan.html"
+LICENSE = "GPLv2"
+SECTION = "console/network"
+
+SRC_URI = "http://www.candelatech.com/~greear/vlan/vlan.${PV}.tar.gz"
+SRC_URI[md5sum] = "5f0c6060b33956fb16e11a15467dd394"
+SRC_URI[sha256sum] = "3b8f0a1bf0d3642764e5f646e1f3bbc8b1eeec474a77392d9aeb4868842b4cca"
+LIC_FILES_CHKSUM = "file://macvlan_config.c;beginline=4;endline=62;md5=dc0660d77e4313e8ccdf256fbe436a63"
+
+S = "${WORKDIR}/${PN}"
+
+CCFLAGS = "-g -D_GNU_SOURCE -Wall -I${STAGING_INCDIR}"
+
+do_compile() {
+	${CC} ${CCFLAGS} -c vconfig.c
+	${CC} ${CCFLAGS} ${LDFLAGS} -o vconfig vconfig.o 
+}
+
+do_install() {
+	install -d "${D}${sbindir}"
+	install -m 755 "${S}/vconfig" "${D}${sbindir}/vconfig"
+}
-- 
1.7.1



^ permalink raw reply related	[flat|nested] 5+ messages in thread

* Re: [meta-networking][PATCH:V3] vlan: Add vlan recipe
  2013-06-27  9:51 [meta-networking][PATCH:V3] vlan: Add vlan recipe lei.yang
@ 2013-06-27 11:00 ` Paul Barker
  2013-06-27 12:38   ` Joe MacDonald
  0 siblings, 1 reply; 5+ messages in thread
From: Paul Barker @ 2013-06-27 11:00 UTC (permalink / raw)
  To: Openembedded Discussion; +Cc: Joe.MacDonald

On 27 June 2013 10:51,  <lei.yang@windriver.com> wrote:
> From: Lei Yang <lei.yang@windriver.com>
>
> A 802.1q vlan support program,which can be used by virt-test
>
> Signed-off-by: Lei Yang <lei.yang@windriver.com>

Just took a quick look at this out of interest. What's using the
vconfig program once it's installed on the target?

vlan-1.9 was released in 2005 and there hasn't been an update since.
The ArchWiki suggests that the modern 'ip' command can do what vconfig
used to do (https://wiki.archlinux.org/index.php/VLAN).

If we can avoid a dependency on such legacy code that would probably
be good. Though I may be missing something as I haven't followed all
the discussion around this patch and I don't know your use case.

Thanks,

--
Paul Barker

Email: paul@paulbarker.me.uk
http://www.paulbarker.me.uk


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [meta-networking][PATCH:V3] vlan: Add vlan recipe
  2013-06-27 11:00 ` Paul Barker
@ 2013-06-27 12:38   ` Joe MacDonald
  2013-06-28  3:39     ` lei yang
  0 siblings, 1 reply; 5+ messages in thread
From: Joe MacDonald @ 2013-06-27 12:38 UTC (permalink / raw)
  To: Paul Barker, lei.yang; +Cc: Openembedded Discussion

[-- Attachment #1: Type: text/plain, Size: 1993 bytes --]

[Re: [oe] [meta-networking][PATCH:V3] vlan: Add vlan recipe] On 13.06.27 (Thu 12:00) Paul Barker wrote:

> On 27 June 2013 10:51,  <lei.yang@windriver.com> wrote:
> > From: Lei Yang <lei.yang@windriver.com>
> >
> > A 802.1q vlan support program,which can be used by virt-test
> >
> > Signed-off-by: Lei Yang <lei.yang@windriver.com>
> 
> Just took a quick look at this out of interest. What's using the
> vconfig program once it's installed on the target?
> 
> vlan-1.9 was released in 2005 and there hasn't been an update since.
> The ArchWiki suggests that the modern 'ip' command can do what vconfig
> used to do (https://wiki.archlinux.org/index.php/VLAN).
> 
> If we can avoid a dependency on such legacy code that would probably
> be good. Though I may be missing something as I haven't followed all
> the discussion around this patch and I don't know your use case.

That's a good point.  Seeing something like this hasn't changed since
2005 is a little concerning, but frankly I'm not completely shocked when
I find out some piece of networking infrastructure has stabilized to the
point where it isn't undergoing much development anymore.  Particularly
if it's something not everyone uses (and sometimes even if it is:
http://comments.gmane.org/gmane.linux.network/238858).

That said, I remember vconfig coming up a bit when I was working with
the CGL workgroup and at the time we'd thought that ip was able to do
everything vconfig was doing, but we were looking at it in the more
narrow context of the requirements definition.

So I guess my question is the same, is there even a use-case for vlan
now that cannot be addressed by existing, already integrated tools?
Lei?  Your comment is specifically saying "can be used by virt-test",
does that mean that virt-test (or something else in meta-virtualization)
requires vconfig to do 802.1q testing or simply that it hasn't been
ported to use other tools (like ip)?

-- 
-Joe MacDonald.
:wq

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 205 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [meta-networking][PATCH:V3] vlan: Add vlan recipe
  2013-06-27 12:38   ` Joe MacDonald
@ 2013-06-28  3:39     ` lei yang
  2013-06-28  7:45       ` Paul Barker
  0 siblings, 1 reply; 5+ messages in thread
From: lei yang @ 2013-06-28  3:39 UTC (permalink / raw)
  To: openembedded-devel

On Thu, Jun 27, 2013 at 8:38 PM, Joe MacDonald
<Joe.MacDonald@windriver.com>wrote:

> [Re: [oe] [meta-networking][PATCH:V3] vlan: Add vlan recipe] On 13.06.27
> (Thu 12:00) Paul Barker wrote:
>
> > On 27 June 2013 10:51,  <lei.yang@windriver.com> wrote:
> > > From: Lei Yang <lei.yang@windriver.com>
> > >
> > > A 802.1q vlan support program,which can be used by virt-test
> > >
> > > Signed-off-by: Lei Yang <lei.yang@windriver.com>
> >
> > Just took a quick look at this out of interest. What's using the
> > vconfig program once it's installed on the target?
> >
> > vlan-1.9 was released in 2005 and there hasn't been an update since.
> > The ArchWiki suggests that the modern 'ip' command can do what vconfig
> > used to do (https://wiki.archlinux.org/index.php/VLAN).
> >
> > If we can avoid a dependency on such legacy code that would probably
> > be good. Though I may be missing something as I haven't followed all
> > the discussion around this patch and I don't know your use case.
>
> That's a good point.  Seeing something like this hasn't changed since
> 2005 is a little concerning, but frankly I'm not completely shocked when
> I find out some piece of networking infrastructure has stabilized to the
> point where it isn't undergoing much development anymore.  Particularly
> if it's something not everyone uses (and sometimes even if it is:
> http://comments.gmane.org/gmane.linux.network/238858).
>
> That said, I remember vconfig coming up a bit when I was working with
> the CGL workgroup and at the time we'd thought that ip was able to do
> everything vconfig was doing, but we were looking at it in the more
> narrow context of the requirements definition.
>
> So I guess my question is the same, is there even a use-case for vlan
> now that cannot be addressed by existing, already integrated tools?
> Lei?  Your comment is specifically saying "can be used by virt-test",
> does that mean that virt-test (or something else in meta-virtualization)
> requires vconfig to do 802.1q testing or simply that it hasn't been
> ported to use other tools (like ip)?
>
>
Yes, it use vconfig not ip, I can post the log fragment in virt-test


/usr/bin/qemu-kvm -name 'vm2' -nodefaults -vga std -monitor
unix:'/tmp/monitor-humanmonitor1-20120315-015344-Damx',server,nowait
-serial unix:'/tmp/serial-20120315-015344-Damx',server,nowait -device
ich9-usb-uhci1,id=usb1 -drive
file='/root/test.img.qcow2',index=0,if=scsi,cache=none,snapshot=on -device
e1000,netdev=idxcDeLE,mac='9a:18:1b:f3:d1:c6',id='id6KMAxt' -netdev
tap,id=idxcDeLE,fd=22 -m 1024 -smp 2 -device
usb-tablet,id=usb-tablet1,bus=usb1.0 -kernel '/root/kernel.guest.nic'
-nographic  -append 'root=/dev/sda2 rw console=ttyS0,115200 ip=dhcp'
01:53:45 DEBUG| VM appears to be alive with PID 9021
01:53:45 DEBUG| (monitor humanmonitor1) Sending command 'info cpus'
01:53:45 DEBUG| (monitor humanmonitor1) Response to 'info cpus'
01:53:45 DEBUG| (monitor humanmonitor1)    * CPU #0: pc=0x00000000000ca1eb
thread_id=9024
01:53:45 DEBUG| (monitor humanmonitor1)      CPU #1: pc=0x00000000000f6404
(halted) thread_id=9025
01:53:45 DEBUG| Starting screendump thread
01:53:45 DEBUG| Attempting to log into 'vm1' (timeout 360s)
01:53:45 DEBUG| No DHCP lease for MAC 9a:18:1b:f3:76:58
01:54:04 DEBUG| (address cache) DHCP lease OK: 00:15:17:bb:5e:88 -->
128.224.165.205
01:54:21 DEBUG| (address cache) DHCP lease OK: 9a:18:1b:f3:76:58 -->
128.224.165.252
01:54:21 DEBUG| Login command: 'ssh -o UserKnownHostsFile=/dev/null -o
PreferredAuthentications=password -p 22 root@128.224.165.252'
01:54:23 INFO | Logged in
01:54:23 DEBUG| Sending command: ifconfig -a
01:54:23 DEBUG| Sending command: dd if=/dev/urandom of=file bs=1024k
count=10
01:54:24 DEBUG| Sending command: echo $?
01:54:25 DEBUG| Sending command: md5sum file
01:54:25 DEBUG| Sending command: echo $?
01:54:25 DEBUG| Sending command: /etc/init.d/iptables stop
01:54:25 DEBUG| Sending command: modprobe 8021q
01:54:25 DEBUG| Sending command: echo $?
01:54:25 DEBUG| Attempting to log into 'vm2' (timeout 360s)
01:54:25 DEBUG| No DHCP lease for MAC 9a:18:1b:f3:d1:c6
01:54:29 DEBUG| (address cache) DHCP lease OK: 9a:18:1b:f3:d1:c6 -->
128.224.165.247
01:54:29 DEBUG| Login command: 'ssh -o UserKnownHostsFile=/dev/null -o
PreferredAuthentications=password -p 22 root@128.224.165.247'
01:54:31 INFO | Logged in
01:54:31 DEBUG| Sending command: ifconfig -a
01:54:31 DEBUG| Sending command: dd if=/dev/urandom of=file bs=1024k
count=10
01:54:33 DEBUG| Sending command: echo $?
01:54:33 DEBUG| Sending command: md5sum file
01:54:33 DEBUG| Sending command: echo $?
01:54:33 DEBUG| Sending command: /etc/init.d/iptables stop
01:54:33 DEBUG| Sending command: modprobe 8021q
01:54:33 DEBUG| Sending command: echo $?
01:54:34 DEBUG| Sending command: vconfig add eth0 1
01:54:34 DEBUG| Sending command: echo $?
01:54:34 DEBUG| Sending command: ifconfig eth0.1 192.168.1.1
01:54:34 DEBUG| Sending command: echo $?
01:54:34 DEBUG| Sending command: vconfig add eth0 2
01:54:34 DEBUG| Sending command: echo $?
01:54:34 DEBUG| Sending command: ifconfig eth0.2 192.168.2.1
01:54:34 DEBUG| Sending command: echo $?
01:54:34 DEBUG| Sending command: vconfig add eth0 3



> --
> -Joe MacDonald.
> :wq
>
> _______________________________________________
> Openembedded-devel mailing list
> Openembedded-devel@lists.openembedded.org
> http://lists.openembedded.org/mailman/listinfo/openembedded-devel
>
>


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [meta-networking][PATCH:V3] vlan: Add vlan recipe
  2013-06-28  3:39     ` lei yang
@ 2013-06-28  7:45       ` Paul Barker
  0 siblings, 0 replies; 5+ messages in thread
From: Paul Barker @ 2013-06-28  7:45 UTC (permalink / raw)
  To: lei yang; +Cc: Openembedded Discussion

On 28 June 2013 04:39, lei yang <yanglei.fage@gmail.com> wrote:
> 01:54:34 DEBUG| Sending command: vconfig add eth0 1

This is definitely a candidate for a short shell script which maps
this to the correct invocation of 'ip'.

To quote the upstream webpage for vlan-1.9:

    It is very unlikely that you need to download anything from this
site, the packages are left here for posterity's sake.

    802.1Q VLANs and MAC-VLANs can be created with the 'ip' utility
(vconfig works for vlans, but is crufty and deprecated).

If upstream says it's crufty and deprecated, I wouldn't want to depend on it.

--
Paul Barker

Email: paul@paulbarker.me.uk
http://www.paulbarker.me.uk


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2013-06-28  7:45 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-06-27  9:51 [meta-networking][PATCH:V3] vlan: Add vlan recipe lei.yang
2013-06-27 11:00 ` Paul Barker
2013-06-27 12:38   ` Joe MacDonald
2013-06-28  3:39     ` lei yang
2013-06-28  7:45       ` Paul Barker

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.