From owner-freebsd-arm@FreeBSD.ORG Fri May 15 08:25:59 2015 Return-Path: Delivered-To: freebsd-arm@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 68B0BB11 for ; Fri, 15 May 2015 08:25:59 +0000 (UTC) Received: from mail-ie0-f182.google.com (mail-ie0-f182.google.com [209.85.223.182]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 37A891973 for ; Fri, 15 May 2015 08:25:58 +0000 (UTC) Received: by ieczm2 with SMTP id zm2so27096678iec.1 for ; Fri, 15 May 2015 01:25:57 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:date :message-id:subject:from:to:content-type; bh=ewL0NgySa6h/015ciSUn0VL9TytwZxdPvYAdk/sj/LE=; b=m7nEdTnVAFLQ3OJ2e8Au1AXqZfWoXVdoeHqt23b4euMGR8sIHB5Fq4F+S1IFE75XEH IM4MrJTSNHilkBlZSZftRxPRWddWf2dTC35xgIBDz/5YzYvxQ8/SED3gEGCaFpR1vTTc lrns4Jt/FF+KY6GgNjvkFLk0Ap3xO2N7cxCEMyO1eBJH2sMCE0CbFbE+dl/Z1j8AAFDt JhFbtkmpy/1jX4hcTzvD8o4+TzkscI5Pchm76INYTPX5TzNMU1kNU7jMegj57IQPzFcD NXZ9uDKX1VRvHqQkywndSUdybH08MpgWRAAqJX620cGl1FzeZ2CqwOpY3XlvntM/bMGv fu0Q== X-Gm-Message-State: ALoCoQlXfJ2uk/R6auc8JzFrPXhtLFXGXrrvWlbG0bmbEq+6/dH32+OqPNKywSdvhP0Um35NOnyI MIME-Version: 1.0 X-Received: by 10.50.178.133 with SMTP id cy5mr5718096igc.5.1431678357544; Fri, 15 May 2015 01:25:57 -0700 (PDT) Received: by 10.36.28.201 with HTTP; Fri, 15 May 2015 01:25:57 -0700 (PDT) In-Reply-To: References: <3AB5ECCF20894591B4DF5FCBA8CA49BB@ad.peach.ne.jp> Date: Fri, 15 May 2015 10:25:57 +0200 Message-ID: Subject: Re: Performance issues with raspberry pi 2 From: Andreas Andersson To: freebsd-arm@freebsd.org Content-Type: text/plain; charset=UTF-8 X-Content-Filtered-By: Mailman/MimeDel 2.1.20 X-BeenThere: freebsd-arm@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: "Porting FreeBSD to ARM processors." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 15 May 2015 08:25:59 -0000 Still getting very low results ab -n 10000 -c 100 -T "application/json" -p postfile http://172.16.0.9:8888/api/v1/alarm/ This is ApacheBench, Version 2.3 <$Revision: 655654 $> Copyright 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/ Licensed to The Apache Software Foundation, http://www.apache.org/ Benchmarking 172.16.0.9 (be patient) Completed 1000 requests Completed 2000 requests Completed 3000 requests Completed 4000 requests Completed 5000 requests Completed 6000 requests Completed 7000 requests Completed 8000 requests Completed 9000 requests Completed 10000 requests Finished 10000 requests Server Software: TornadoServer/4.1 Server Hostname: 172.16.0.9 Server Port: 8888 Document Path: /api/v1/alarm/ Document Length: 16 bytes Concurrency Level: 100 Time taken for tests: 123.976 seconds Complete requests: 10000 Failed requests: 0 Write errors: 0 Total transferred: 1590000 bytes Total POSTed: 2650000 HTML transferred: 160000 bytes Requests per second: 80.66 [#/sec] (mean) Time per request: 1239.759 [ms] (mean) Time per request: 12.398 [ms] (mean, across all concurrent requests) Transfer rate: 12.52 [Kbytes/sec] received 20.87 kb/s sent 33.40 kb/s total Connection Times (ms) min mean[+/-sd] median max Connect: 1 17 225.3 1 6205 Processing: 17 1218 461.1 1057 2782 Waiting: 17 1214 460.8 1053 2761 Total: 26 1235 521.9 1059 7131 Percentage of the requests served within a certain time (ms) 50% 1059 66% 1194 75% 1294 80% 1495 90% 2006 95% 2164 98% 2428 99% 2621 100% 7131 (longest request) The corresponding result for raspbian is around 250 req/s. One thing I've noticed when comparing the consumer for the same project (reads from rabbitmq, gets and acks the messages and then discards them) it works perfectlly with raspbian. The number of get's corresponds with the number of acks from the queue in rabbitmq. Whereas freebsd 11 on rpi2 does not do this. It has a rather high number of rabbitmq (4-500 get/s), but almost no ACKs (1-1.5 ACK/s). on raspbian this number is ~250/s for both GET and ACK. I am running powerd with these settings: powerd_flags="-M 900" 2015-05-15 8:27 GMT+02:00 Andreas Andersson : > I just set debug.cpufreq.lowest=900 in sysctl.conf (Would it be better to > have this set in /boot/loader.conf?) and enabled powerd. INVARIANTS is also > disabled in this kernel. > > Will come back with results. > > 2015-05-15 4:38 GMT+02:00 Daisuke Aoyama : > >> Hi, >> >> But freebsd 11 on rpi2 suffers permance issues. Severely. >>> >>> For instance, the same code I am running (tornado project which inserts >>> stuff to rabbitmq) is running at ~190 req/s or 190 publishments/sec (to >>> rabbitmq) on raspbian. >>> >>> On FreeBSD 11 this is at around 85/s. >>> >> >> Did you enable powerd? >> RPi2 firmware boot up with 600MHz(power saved mode). It's slower than >> RPi1 such as model B+. >> The maximum rated frequency(900MHz in RPi2 case) can be used when you >> enable powerd or set sysctl value. >> powerd is requirement on RPi2, not an option like RPi1 anymore. >> >> I suggest that you enable powerd in FreeBSD official image and/or crochet >> for RPi2. >> >> Regards, >> -- >> Daisuke Aoyama >> >> >> >