From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-qt0-f177.google.com (mail-qt0-f177.google.com [209.85.216.177]) by dpdk.org (Postfix) with ESMTP id 34C4D23B for ; Tue, 23 May 2017 07:16:53 +0200 (CEST) Received: by mail-qt0-f177.google.com with SMTP id t26so118783811qtg.0 for ; Mon, 22 May 2017 22:16:53 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=uSy09bkw3Yrd+xdM9dLffD4q5RwQuMXvs+MMGfEWHHA=; b=sS8RIQIK1HsjV+26pFfxQDzHOuOyXtSXaWJAU0HgeLgQXBccxOZZe4MPgIgryhIZ/F dUz4/qoqvQQkxykKnnoNTQD3FIeBsJbqq1nKIDAx9tAaHH/2Ycrkpup7+zH3ft5r5uJ2 tFsQQa5iNpdurtHu906BQr5porUQqPZvFPN69C1sQBgn4JgYBHupz7BTMRtbhgi+oMCA IQZghJTT9f8hZtB+gf/2JLmxUJqAY/XHHiqMTZYKMwq8q6dRitnlJqHqSrf72kwGCrec 5ho5vhxhQkRqfGtHgN3jiS4N7iUpiFCsT4h7VG4QD2Nc7+4FBvGjmE0AK3lbq/Mfdcjy NcQA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=uSy09bkw3Yrd+xdM9dLffD4q5RwQuMXvs+MMGfEWHHA=; b=tznJz+VffD9OjvDazz5QSzVzXI3M35LHseK8qNAfl9ng2z/fGJ8AMbkNechxlZU5vu ygpXD1rFaBzJI4qA8eaq37Vx2a79JrdjXbVxHsOi20xuXk1cb9iwr2YK4CPkMVevKs38 DncqZiBJrM2RQ9ScPOlFkgtvhDPN0tntJSgolMHLnfDp6SHIl+RjjVyjuAsLck8D8eVw QS/EOi7+Tu7g9QuqajobtJsIikv022udXCvLNx2ZxSf4bE42RoCuuF5tH/AGAqFrIi3c wKwsiJr1BqGIG38Y9ivYNhQ0p1VE2z3Hjr33KBrHyEkUyN1lvrrTy24oEGru9sElCryF a4Pw== X-Gm-Message-State: AODbwcDVQUtv+BZULYBP06V6ZNPHaArh9TQQR9fiRKYo+Aekd+eahZgl y/vAkk+SRrxtRkyRAsEWc0Uotrm/bA== X-Received: by 10.237.39.195 with SMTP id m3mr24392168qtg.164.1495516612652; Mon, 22 May 2017 22:16:52 -0700 (PDT) MIME-Version: 1.0 Received: by 10.12.172.76 with HTTP; Mon, 22 May 2017 22:16:52 -0700 (PDT) In-Reply-To: References: From: Shyam Shrivastav Date: Tue, 23 May 2017 10:46:52 +0530 Message-ID: To: Chris Hall Cc: "users@dpdk.org" Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.15 Subject: Re: [dpdk-users] pktgen - IP address randomness X-BeenThere: users@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK usage discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 23 May 2017 05:16:53 -0000 Sometime back I used lua in moongen to continuously generate ip:tcp packets with random ip src and random tcp src/dst ports. Here is the corresponding lua script fragment, don't know how much useful it can be with pktgen as I have not looked at or used pktgen till now but just in case ... x1 =3D math.random(1,254); x2 =3D math.random(1,254); x3 =3D math.random(1,254); x4 =3D math.random(1,254); p1 =3D math.random(1025,65534); p2 =3D math.random(1025,65534); pkt.ip.src:set(x1*256*256*256 + x2*256*256 + x3*256 + x4) pkt.tcp:setSrcPort(p1); pkt.tcp:setDstPort(p2); On Tue, May 23, 2017 at 5:01 AM, Chris Hall wrote: > Hello, > > pktgen-3.2.4 > > I Looking to get as much randomness out of src ip=E2=80=99s as possible. = Using > this config in lua=E2=80=A6 > > pktgen.src_ip('0', 'start',"0.0.0.1"); > pktgen.src_ip('0', 'min', "0.0.0.1"); > pktgen.src_ip('0', 'max', "255.255.255.254"); > pktgen.src_ip('0', 'inc', "1.1.1.1"); > > running a packet capture of 5Million packets on the receiving host, > parsing the pcap file, based on source ip, seems I can only get about 327= 69 > uniq ip's, (each connected about 150 times). > > As a comparison I used hping3 with --rand-source option (5million packets= ) > I can get about 4942744 uniq ip=E2=80=99s. > > Is there a configure option(s) somewhere that could be tuned for more > randomness or is the above parms just wrong ? > > Thanks much. > > * Chris > > > >