WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-users

Re: [Xen-users] xen bridge jumbo frame problems starting new DomU

To: Peter Viskup <skupko.sk@xxxxxxxxx>
Subject: Re: [Xen-users] xen bridge jumbo frame problems starting new DomU
From: Fischer Udo Attila <udo@xxxxxx>
Date: Mon, 26 Oct 2009 16:41:39 +0100
Cc: xen-users@xxxxxxxxxxxxxxxxxxx
Delivery-date: Mon, 26 Oct 2009 10:04:41 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <dcfca3400910260729k242cf377m9951f5634f5790db@xxxxxxxxxxxxxx>
List-help: <mailto:xen-users-request@lists.xensource.com?subject=help>
List-id: Xen user discussion <xen-users.lists.xensource.com>
List-post: <mailto:xen-users@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-users>, <mailto:xen-users-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-users>, <mailto:xen-users-request@lists.xensource.com?subject=unsubscribe>
References: <4AE58AA9.7070404@xxxxxx> <dcfca3400910260729k242cf377m9951f5634f5790db@xxxxxxxxxxxxxx>
Sender: xen-users-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Thunderbird 2.0.0.23 (Windows/20090812)
Hi Peter,

I have already programmed it only a little different:
and it works if you want to set it below 1500, but fails if you want to go over 1500.. the domain start fails if it is set over 1500 (RTNETLINK answers: Invalid argument)


Best Regards,
Udo Attila Fischer



PS: Maybe it the following code should not posted here but maybe it is usefull if somebody want to change settings below 1500.

in the /etc/xen/scripts
--- vif-common.sh.orig  2009-10-24 01:15:59.000000000 +0200
+++ vif-common.sh       2009-10-26 16:15:54.000000000 +0100
@@ -63,6 +63,11 @@
  vif="$vifname"
fi

+mtu=$(xenstore_read_default "$XENBUS_PATH/mtu" "")
+if [ "$mtu" ] && [ "$command" == "online" ]
+then
+ ip link set $vif mtu "$mtu"
+fi

frob_iptable()
{


in the xen phyton scripts directory:
--- xm/create.py.orig   2009-10-24 02:19:04.000000000 +0200
+++ xm/create.py        2009-10-24 02:22:07.000000000 +0200
@@ -354,7 +354,7 @@
          keymap overrides the XendD configured default layout file.""")

gopts.var('vif', val="type=TYPE,mac=MAC,bridge=BRIDGE,ip=IPADDR,script=SCRIPT," + \
-          "backend=DOM,vifname=NAME,rate=RATE,model=MODEL,accel=ACCEL",
+ "backend=DOM,vifname=NAME,rate=RATE,model=MODEL,accel=ACCEL,mtu=MTU",
          fn=append_value, default=[],
use="""Add a network interface with the given MAC address and bridge.
          The vif is configured by calling the given configuration script.
@@ -850,7 +850,7 @@
        def f(k):
if k not in ['backend', 'bridge', 'ip', 'mac', 'script', 'type',
                         'vifname', 'rate', 'model', 'accel',
-                         'policy', 'label']:
+                         'policy', 'label', 'mtu']:
                err('Invalid vif option: ' + k)

            config_vif.append([k, d[k]])


--- xend/server/netif.py.orig   2009-01-05 21:27:55.000000000 +0100
+++ xend/server/netif.py        2009-10-24 03:46:17.000000000 +0200
@@ -115,6 +115,7 @@
        model   = config.get('model')
        accel   = config.get('accel')
        sec_lab = config.get('security_label')
+        mtu = config.get('mtu')

        if not mac:
            raise VmError("MAC address not specified or generated.")
@@ -141,6 +142,8 @@
            back['accel'] = accel
        if sec_lab:
            back['security_label'] = sec_lab
+        if mtu:
+            back['mtu'] = mtu

        back['handle'] = "%i" % devid
        back['script'] = os.path.join(xoptions.network_script_dir, script)
@@ -187,7 +190,7 @@

        for x in ( 'script', 'ip', 'bridge', 'mac',
                   'type', 'vifname', 'rate', 'uuid', 'model', 'accel',
-                   'security_label'):
+                   'security_label', 'mtu'):
            if transaction is None:
                y = self.readBackend(devid, x)
            else:
--- xm/main.py.orig     2009-10-24 02:55:52.000000000 +0200
+++ xm/main.py  2009-10-24 03:02:08.000000000 +0200
@@ -188,7 +188,7 @@
'network-attach': ('<Domain> [type=<type>] [mac=<mac>] [bridge=<bridge>] ' '[ip=<ip>] [script=<script>] [backend=<BackDomain>] '
                        '[vifname=<name>] [rate=<rate>] [model=<model>]'
-                        '[accel=<accel>]',
+                        '[accel=<accel>]' '[mtu=<mtu>]',
                        'Create a new virtual network device.'),
    'network-detach':  ('<Domain> <DevId> [-f|--force]',
                        'Destroy a domain\'s virtual network device.'),
@@ -2416,7 +2416,7 @@
    dom = args[0]
    vif = ['vif']
    vif_params = ['type', 'mac', 'bridge', 'ip', 'script', \
-                  'backend', 'vifname', 'rate', 'model', 'accel']
+                  'backend', 'vifname', 'rate', 'model', 'accel', 'mtu']

    if serverType == SERVER_XEN_API:
        vif_record = {
@@ -2465,7 +2465,9 @@
            'model':
                lambda x: None,
            'accel':
-                lambda x: set(['other_config', 'accel'], x)
+                lambda x: set(['other_config', 'accel'], x),
+            'mtu':
+                lambda x: set(['other_config', 'mtu'], x)
            }

        for a in args[1:]:

--- xend/XendDomainInfo.py.orig 2009-10-24 05:05:37.000000000 +0200
+++ xend/XendDomainInfo.py      2009-10-24 05:25:20.000000000 +0200
@@ -3213,7 +3213,8 @@
                    # some point we're going to have to figure out how to
                    # handle that properly.

-            config['MTU'] = 1500 # TODO
+            #config['MTU'] = 1500 # TODO
+            config['MTU'] =   config.get('mtu', 1500) # TODO

            if self._stateGet() not in (XEN_API_VM_POWER_STATE_HALTED,):
                xennode = XendNode.instance()

Attachment: smime.p7s
Description: S/MIME Cryptographic Signature

_______________________________________________
Xen-users mailing list
Xen-users@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-users
<Prev in Thread] Current Thread [Next in Thread>