Hi,
I'm trying to establish a communication between several L4Linux instances on fiasco.oc kernel with L4Re on the beagle board, preferable through a virtual network. I found out that the outdated L4env provided a virtual netwok switch, ORe and the l4ore driver in L4Linux for that purpose. Is there something similar available for L4Re and how can I setup a connection between two L4Linux instances?
Thanks, Michael
Hi,
On Thu Sep 16, 2010 at 16:33:10 +0200, Michael Weiß wrote:
I'm trying to establish a communication between several L4Linux instances on fiasco.oc kernel with L4Re on the beagle board, preferable through a virtual network. I found out that the outdated L4env provided a virtual netwok switch, ORe and the l4ore driver in L4Linux for that purpose. Is there something similar available for L4Re and how can I setup a connection between two L4Linux instances?
Ankh is the new Ore. Unfortunately the l4ore-driver in L4Linux hasn't been converted yet. But there's the l4shmnet driver which connects two Linuxes via shared memory. I haven't used that one in a while so things might be unstable but it basically works by creating an l4re namespace in the start script and giving it to both Linuxes via l4shmnet.add=shmns,0x12 (and one with an additional ',create'). Then there should be a network device in each Linux...
HTH, Adam
On 09/16/2010 10:22 PM, Adam Lackorzynski wrote:
Hi,
On Thu Sep 16, 2010 at 16:33:10 +0200, Michael Weiß wrote:
I'm trying to establish a communication between several L4Linux instances on fiasco.oc kernel with L4Re on the beagle board, preferable through a virtual network. I found out that the outdated L4env provided a virtual netwok switch, ORe and the l4ore driver in L4Linux for that purpose. Is there something similar available for L4Re and how can I setup a connection between two L4Linux instances?
Ankh is the new Ore. Unfortunately the l4ore-driver in L4Linux hasn't been converted yet. But there's the l4shmnet driver which connects two Linuxes via shared memory. I haven't used that one in a while so things might be unstable but it basically works by creating an l4re namespace in the start script and giving it to both Linuxes via l4shmnet.add=shmns,0x12 (and one with an additional ',create'). Then there should be a network device in each Linux...
HTH, Adam
Thanks for the replay Adam,
I compiled the l4linux kernel with the l4shm driver, and tried to follow your advise to create a namespace and give it to the two l4linux instances. However, I have difficulties to understand the whole lua stuff. So I might did the namespace creation wrong, because the l4shm driver is complaining about that it cannot find the namespace:
First l4linux instance with create: shmns: Requesting, role Creator, Shmsize 1024 Kbytes shmns: Failed to establish communication
Second l4linux instance: shmns: Requesting, role User, Shmsize 1024 kbytes l4linux1| shm: did not find 'shmns' namespace
I tired to create the namespace like that: shmns = L4.default_loader:create_namespace("shmns");
Could you tell me, how to create the L4Re namespace right and maybe needed capability settings.
Thanks, Michael
Hi Michael,
On Mon Sep 20, 2010 at 14:38:28 +0200, Michael Weiß wrote:
I compiled the l4linux kernel with the l4shm driver, and tried to follow your advise to create a namespace and give it to the two l4linux instances. However, I have difficulties to understand the whole lua stuff. So I might did the namespace creation wrong, because the l4shm driver is complaining about that it cannot find the namespace:
First l4linux instance with create: shmns: Requesting, role Creator, Shmsize 1024 Kbytes shmns: Failed to establish communication
Second l4linux instance: shmns: Requesting, role User, Shmsize 1024 kbytes l4linux1| shm: did not find 'shmns' namespace
I tired to create the namespace like that: shmns = L4.default_loader:create_namespace("shmns");
Could you tell me, how to create the L4Re namespace right and maybe needed capability settings.
That's already good but probably missing to give the shmns cap more rights. Do it like this for the Linux launch: ...:start({ caps = { shmns = shmns:mode("rw"), ...
So the ':mode("rw")' is important here so that the Linuxes can put something in the namespaces. Used without 'mode' they are defaulting to just be 'read-only'.
Unfortunately there's some rough spot in the shm-lib currently so that the synchronization between the two parties doesn't work. I'm working on a fix though...
Adam
On Tue Sep 21, 2010 at 23:06:18 +0200, Adam Lackorzynski wrote:
Hi Michael,
On Mon Sep 20, 2010 at 14:38:28 +0200, Michael Weiß wrote:
I compiled the l4linux kernel with the l4shm driver, and tried to follow your advise to create a namespace and give it to the two l4linux instances. However, I have difficulties to understand the whole lua stuff. So I might did the namespace creation wrong, because the l4shm driver is complaining about that it cannot find the namespace:
First l4linux instance with create: shmns: Requesting, role Creator, Shmsize 1024 Kbytes shmns: Failed to establish communication
Second l4linux instance: shmns: Requesting, role User, Shmsize 1024 kbytes l4linux1| shm: did not find 'shmns' namespace
I tired to create the namespace like that: shmns = L4.default_loader:create_namespace("shmns");
Could you tell me, how to create the L4Re namespace right and maybe needed capability settings.
That's already good but probably missing to give the shmns cap more rights. Do it like this for the Linux launch: ...:start({ caps = { shmns = shmns:mode("rw"), ...
With the following way it just works (right now). Create the namespace like this: local shmns = L4.default_loader:create_namespace({ shm = "placeholder" });
Adam
On 09/22/2010 10:58 AM, Adam Lackorzynski wrote:
On Tue Sep 21, 2010 at 23:06:18 +0200, Adam Lackorzynski wrote:
On Mon Sep 20, 2010 at 14:38:28 +0200, Michael Weiß wrote:
I compiled the l4linux kernel with the l4shm driver, and tried to follow your advise to create a namespace and give it to the two l4linux instances. However, I have difficulties to understand the whole lua stuff. So I might did the namespace creation wrong, because the l4shm driver is complaining about that it cannot find the namespace:
First l4linux instance with create: shmns: Requesting, role Creator, Shmsize 1024 Kbytes shmns: Failed to establish communication
Second l4linux instance: shmns: Requesting, role User, Shmsize 1024 kbytes l4linux1| shm: did not find 'shmns' namespace
I tired to create the namespace like that: shmns = L4.default_loader:create_namespace("shmns");
Could you tell me, how to create the L4Re namespace right and maybe needed capability settings.
That's already good but probably missing to give the shmns cap more rights. Do it like this for the Linux launch: ...:start({ caps = { shmns = shmns:mode("rw"), ...
With the following way it just works (right now). Create the namespace like this: local shmns = L4.default_loader:create_namespace({ shm = "placeholder" });
Thanks, that worked. In your last mail you said somthing about a bug in the lib-shm. Could this bug cause the following error?
KERNEL0: alignment error at 01637e62 (PC: 012a93b4, SP: 0137bde0, FSR: 410001)
This occurs when I'm trying to send a ping from one l4lx instance to the other l4lx instance. I used the newest version of l4re fiasco and l4linux which are available through svn.
Michael
Hi,
On Thu Sep 23, 2010 at 10:03:29 +0200, Michael Weiß wrote:
In your last mail you said somthing about a bug in the lib-shm. Could this bug cause the following error?
KERNEL0: alignment error at 01637e62 (PC: 012a93b4, SP: 0137bde0, FSR: 410001)
This occurs when I'm trying to send a ping from one l4lx instance to the other l4lx instance. I used the newest version of l4re fiasco and l4linux which are available through svn.
No, this has nothing to do with this particular thing. Alignment errors happen when one tries to access memory unaligned, i.e. not with addresses which are multiples of 4. I'll look into it.
Adam
Hi Michael,
On Thu Sep 23, 2010 at 10:03:29 +0200, Michael Weiß wrote:
KERNEL0: alignment error at 01637e62 (PC: 012a93b4, SP: 0137bde0, FSR: 410001)
This fixes it:
--- drivers/net/l4shmnet.c +++ drivers/net/l4shmnet.c @@ -188,6 +188,7 @@ else l = rph->size;
+ skb_reserve(skb, NET_IP_ALIGN); p = skb_put(skb, rph->size); memcpy(p, priv->rx_ring_start + offs, l); if (l != rph->size)
Thanks, Adam
On 09/26/2010 10:54 PM, Adam Lackorzynski wrote:
On Thu Sep 23, 2010 at 10:03:29 +0200, Michael Weiß wrote:
KERNEL0: alignment error at 01637e62 (PC: 012a93b4, SP: 0137bde0, FSR: 410001)
This fixes it:
--- drivers/net/l4shmnet.c +++ drivers/net/l4shmnet.c @@ -188,6 +188,7 @@ else l = rph->size;
p = skb_put(skb, rph->size); memcpy(p, priv->rx_ring_start + offs, l); if (l != rph->size)skb_reserve(skb, NET_IP_ALIGN);
Indeed, the patch worked. I can now successfully ping through the shmnet device.
Thanks, Michael
l4-hackers@os.inf.tu-dresden.de