Swingbench 博客合集

分享一下我老师大神的人工智能教程!零基础,通俗易懂!http://blog.csdn.net/jiangjunshow

也欢迎大家转载本篇文章。分享知识,造福人民,实现我们中华民族伟大复兴!

               

Swingbench

Dominic Giles Blog

SBUtil inAction (And Some Fixes)

12/03/15 18:44

As a means of demonstrating what you can achieve with SBUtil I’ve createda little test to show it’s possible to trivially change the size of the dataset and rerun the same workload to show how TPS can vary if the SGA/BufferCache is kept consistent.

First the script

1

2

3

4

5

6

7

8

9

10

11

12

13

14

15

16

17

18

19

20

21

22

23

24

25

26

27

28

29

30

31

32

33

34

35

36

37

38

39

40

41

42

#!/bin/bash

 

sqlplus sys/welcome1@//ed2xcomp01/DOMS as sysdba << EOF

create bigfile tablespace SOE datafile size 1000G;

exit;

EOF

 

time ./oewizard -scale 1 -dbap welcome1 -u soe -p soe -cl -cs //ed2xcomp01/DOMS -ts SOE -create

 

time ./charbench -u soe -p soe -cs //ed2xcomp01/DOMS -uc 128 -min -0 -max 0 -stats full -rt 0:10 -bs 0:01 -a -r resscale01.xml

 

time ./sbutil -u soe -p soe -cs //ed2xcomp01/DOMS -soe -parallel 64 -dup 2 

 

time ./charbench -u soe -p soe -cs //ed2xcomp01/DOMS -uc 128 -min -0 -max 0 -stats full -rt 0:10 -bs 0:01 -a -r resscale02.xml

 

time ./sbutil -u soe -p soe -cs //ed2xcomp01/DOMS -soe -parallel 64 -dup 2

 

time ./charbench -u soe -p soe -cs //ed2xcomp01/DOMS -uc 128 -min -0 -max 0 -stats full -rt 0:10 -bs 0:01 -a -r resscale04.xml

 

time ./sbutil -u soe -p soe -cs //ed2xcomp01/DOMS -soe -parallel 64 -dup 2

 

time ./charbench -u soe -p soe -cs //ed2xcomp01/DOMS -uc 128 -min -0 -max 0 -stats full -rt 0:10 -bs 0:01 -a -r resscale08.xml

 

time ./sbutil -u soe -p soe -cs //ed2xcomp01/DOMS -soe -parallel 64 -dup 2

 

time ./charbench -u soe -p soe -cs //ed2xcomp01/DOMS -uc 128 -min -0 -max 0 -stats full -rt 0:10 -bs 0:01 -a -r resscale16.xml

 

time ./sbutil -u soe -p soe -cs //ed2xcomp01/DOMS -soe -parallel 64 -dup 2

 

time ./charbench -u soe -p soe -cs //ed2xcomp01/DOMS -uc 128 -min -0 -max 0 -stats full -rt 0:10 -bs 0:01 -a -r resscale32.xml

 

time ./sbutil -u soe -p soe -cs //ed2xcomp01/DOMS -soe -parallel 64 -dup 2

 

time ./charbench -u soe -p soe -cs //ed2xcomp01/DOMS -uc 128 -min -0 -max 0 -stats full -rt 0:10 -bs 0:01 -a -r resscale64.xml

 

time ./sbutil -u soe -p soe -cs //ed2xcomp01/DOMS -soe -parallel 64 -dup 2

 

time ./charbench -u soe -p soe -cs //ed2xcomp01/DOMS -uc 128 -min -0 -max 0 -stats full -rt 0:10 -bs 0:01 -a -r resscale128.xml

 

time ./sbutil -u soe -p soe -cs //ed2xcomp01/DOMS -soe -parallel 64 -dup 2

 

time ./charbench -u soe -p soe -cs //ed2xcomp01/DOMS -uc 128 -min -0 -max 0 -stats full -rt 0:10 -bs 0:01 -a -r resscale256.xml



I’m hoping it should be fairly obvious what the script does. I create atablespace big enough to accommodate the final data set (In this instance 1TB).This way I’m not constantly auto extending the tablespace. Then I create a seedschema at 1GB in size. Then I run a workload against the schema, this willremain constant through all of the tests. Each of the load tests runs for 10minand collects full stats. After the test has completed I use “sbutil” toreplicate the schema and simply rerun the workload writing the results to a newfile. By the end of the tests and duplication the end schema has roughly ½ aTerabytes worth of data and about the same in indexes. The benefit of thisapproach is that it’s much quicker to expand the data than using the wizard todo it.

The directory will now contain all of the results files which can be processedtrivially using the the “parse_results.py” script in utils directory. In theexample below I simply parse all of the files and write the result to a filecalled res1.csv. Because the python script is so easy to modify you could pullout any of the stats from the file. I’m just using the ones that it collects bydefault

1

$ python ../utils/parse_results.py -r resscale01.xml    resscale02.xml    resscale04.xml    resscale08.xml    resscale16.xml    resscale32.xml    resscale64.xml    resscale9128.xml  resscale9256.xml -o res1.csv


On completing this step I can use my favourite spread sheet tool to loadres1.csv and take a look at the data. In this instance I’m using “Numbers” onOS X but Excel would work equally as well. 



The resulting chart shows pretty much what we’d expect .That doubling the sizeof the datasets but keeping the workload and SGA constant results in areduction of the TPS. Which tails off quickly as the data set quickly outgrowsthe buffer cache and we are forced to perform physical IOs, but declines lessslowly after this impact is felt. It’s something we would expect but it’s niceto able to demonstrate it.



So the next obvious question is how easy is it to rerun the test but to enablea feature like partitioning. Really easy. Simply ask oewizard to create theschema using hash partitioning i.e. change

1

time ./oewizard -scale 1 -dbap welcome1 -u soe -p soe -cl -cs //ed2xcomp01/DOMS -ts SOE -create


to

1

time ./oewizard -scale 1 -hashpart -dbap welcome1 -u soe -p soe -cl -cs //ed2xcomp01/DOMS -ts SOE -create


and rerun the tests to produce the following results




Or even enabling compression and partitioning by simply replacing the firstsbutil operation with

1

time ./sbutil -u soe -p soe -cs //ed2xcomp01/DOMS -soe -parallel 64 -dup 2 -ac






During the testing of this I fixed up a few bugs which I wasn’t aware of soit’s worth downloading a new build which you can find here. I also released Ineeded a few more options on the utility to round it out. These were

·        “seqs” : thisrecreates the sequences used by the schemas

·        “code” : rebuilds anystored procedures


I’ll most likely add a few more over the coming weeks.

Just a word of caution… I’ve noticed that my stats collection is broken. Idon’t cater for all of the possible version/configurations in my script and soit can break on large stats collections and go serial. I’ll try and fix thisnext week.


2 Comments

SwingbenchUtil... Going Big...

07/03/15 16:55

I’ve added a utility to swingbench that perhaps I should’ve done a longtime ago. The idea behind it is that it enables you to validate, fix orduplicate the data created by the wizards. I’m often contacted by people askingme how to fix an install of “Order Entry” or the “Sales History” benchmarkafter they’ve been running for many hours only to find they run out of tempspace for the index creation. I’m also asked how they can make a really big“Sales History” schema when they only have relatively limited compute power andto create a multi terabyte data set might take days. Well the good news is thatnow, most of this should be relatively easy. The solution is a little programcalled “subtil” and you can find it in your bin or win bin directory. 

Currently sbutil is command line only and requires a number of parameters toget it to do anything useful. The main parameters are

·        “-dup” indicates the number of times youwant data to be duplicated within the schema. Valid values are 1 to n. Data iscopied and new primary keys/foreign keys generated where necessary. It’srecommended that you first increase/extend the tablespace before beginning theduplication. The duplication process will also rebuild the indexes and updatethe metadata table unless you specifically ask it not to with the “-nic”option. This is useful if you know you’ll be reduplicated the data again at a laterstage.

·        “-val” validates the tables and indexesin the specified schema. It will list any missing indexes or invalid code.

·        “-stats” will create/recreate statisticsfor the indicated schema

·        “-delstats” will delete all of thestatistics for the indicated schema

·        “-tables” will list all of the tablesand row counts (based on database statistics) for the indicated schema

·        “-di” will drop all of the indexes forthe indicated schema

·        “-ci” will recreate all of the indexesfor the indicated schema

Alongside of these verb based parameters are a number of associatedattributes

·        “-u” : required. the username of theschema

·        “-p” : required. the password of theschema

·        “-cs” : required. the connect string ofthe schema. Some examples might be “localhost:1521:db12c”, “//oracleserver/soe”“//linuxserver:1526/orcl” etc.

·        “-parallel” the level of parallelism touse to perform operations. Valid values are 1 to n.

·        “-sort” sort the seed data beforeduplicating it.

·        “-nic” don’t create indexes orconstraints at the end of a duplication

·        “-ac” convert the “main” tables toadvanced compression

·        “-hcc” convert the main tables to HybridColumnar Compression

·        “-soe” : required. the target schemawill be “Order Entry”

·        “-sh” : required. the target schema willbe “Sales History”

So lets take a look at a few examples.

1

sbutil -u soe -p soe -cs //oracleserver/soe -dup 2 -parallel 32 -sort -soe


will duplicate the data in the soe schema but will first sort the seed data.You should see output similar to this

1

2

3

4

5

6

7

8

9

10

11

12

13

14

15

16

17

18

19

20

21

22

23

24

25

26

Getting table Info

Got table information. Completed in : 0:00:26.927

Dropping Indexes

Dropped Indexes. Completed in : 0:00:05.198

Creating copies of tables

Created copies of tables. Completed in : 0:00:00.452

Begining data duplication

Completed Iteration 2. Completed in : 0:00:32.138                                                  

Creating  Constraints

Created  Constraints. Completed in : 0:04:39.056

Creating  Indexes

Created  Indexes. Completed in : 0:02:52.198

Updating Metadata and Recompiling Code

Updated Metadata. Completed in : 0:00:02.032

Determining New Row Counts

Got New Row Counts. Completed in : 0:00:05.606

Completed Data Duplication in 0 hour(s) 9 minute(s) 44 second(s) 964 millisecond(s)

----------------------------------------------------------------------------------------------------------

|Table Name          |  Original Row Count|       Original Size|       New Row Count|            New Size|

----------------------------------------------------------------------------------------------------------

|ORDER_ITEMS         |         172,605,912|             11.7 GB|         345,211,824|             23.2 GB|

|CUSTOMERS           |          40,149,958|              5.5 GB|          80,299,916|             10.9 GB|

|CARD_DETAILS        |          60,149,958|              3.4 GB|         120,299,916|              6.8 GB|

|ORDERS              |          57,587,049|              6.7 GB|         115,174,098|             13.3 GB|

|ADDRESSES           |          60,174,782|              5.7 GB|         120,349,564|             11.4 GB|

----------------------------------------------------------------------------------------------------------



The following example validates a schema to ensure that the tables and indexesinside a schema are all present and valid

1

./sbutil -u soe -p soe -cs //ed2xcomp01/DOMS -soe -val


The output of the command will look similar to to this

1

2

3

4

5

6

7

8

9

10

11

The Order Entry Schema appears to be valid.

 

--------------------------------------------------

|Object Type    |     Valid|   Invalid|   Missing|

--------------------------------------------------

|Table          |        10|         0|         0|

|Index          |        26|         0|         0|

|Sequence       |         5|         0|         0|

|View           |         2|         0|         0|

|Code           |         1|         0|         0|

--------------------------------------------------



The next command lists the tables in a schema

1

2

3

4

5

6

7

8

9

10

11

12

13

14

15

16

17

18

./sbutil -u soe -p soe -cs //ed2xcomp01/DOMS -soe -tables

 

Order Entry Schemas Tables

----------------------------------------------------------------------------------------------------------------------

|Table Name                  |                Rows|              Blocks|           Size|   Compressed?|  Partitioned?|

----------------------------------------------------------------------------------------------------------------------

|ORDER_ITEMS                 |          17,157,056|             152,488|         11.6GB|              |           Yes|

|ORDERS                      |           5,719,160|              87,691|          6.7GB|              |           Yes|

|ADDRESSES                   |           6,000,000|              75,229|          5.7GB|              |           Yes|

|CUSTOMERS                   |           4,000,000|              72,637|          5.5GB|              |           Yes|

|CARD_DETAILS                |           6,000,000|              44,960|          3.4GB|              |           Yes|

|LOGON                       |                   0|                   0|        101.0MB|              |           Yes|

|INVENTORIES                 |                   0|                   0|         87.0MB|      Disabled|            No|

|PRODUCT_DESCRIPTIONS        |                   0|                   0|         1024KB|      Disabled|            No|

|WAREHOUSES                  |                   0|                   0|         1024KB|      Disabled|            No|

|PRODUCT_INFORMATION         |                   0|                   0|         1024KB|      Disabled|            No|

|ORDERENTRY_METADATA         |                   0|                   0|         1024KB|      Disabled|            No|

----------------------------------------------------------------------------------------------------------------------



To drop the indexes in a schema use the following command

1

2

3

./sbutil -u sh -p sh -cs //oracle12c2/soe -sh -di

Dropping Indexes

Dropped Indexes. Completed in : 0:00:00.925



To recreate the indexes in a schema use the following command

1

2

3

./sbutil -u sh -p sh -cs //oracle12c2/soe -sh -ci

Creating Partitioned Indexes and Constraints

Created  Indexes and Constraints. Completed in : 0:00:03.395


You can download the new version of the software here.

Tags: swingbenchutilscaleout

0 Comments

And now a fixto the fixes...

16/01/15 18:36

Just realised I uploaded the last build with Oracle Database 12c Release 1(12.1.0.1) jdbc drivers. I’ve fixed that (now 12.1.0.2 drivers) and so feelfree to download again.

Thanks 

Dom.

0 Comments

Fixes toswingbench

14/01/15 12:01

Happy new year….

I’ve updated swingbench with some fixes. Most of these are to do with the newresults to pdf functionality. But at this point I’m giving fair warning thatthe following releases will be available on Java 8 only.

I’m also removing the “3d” charts from swingbench and replacing them with a richerselection of charts build using JavaFX. 

Also I’ve added some simple code to the jar file to tell you which version itis… You can run this with the command

1

2

$ java -jar swingbench.jar

Swingbench Version 2.5.955


As always you can download it here. Please leave comments below if you run into any problems.

18 Comments

ApplicationContinuity in Oracle Database 12c (12.1.0.2)

19/11/14 13:53

In this entryI’ll try and detail the steps required to get application continuity workingwith swingbench. I’ll create a video with a complete walk through of the build.It’s also possible this blog is likely to be updated regularly as I getfeedback

Assumptions


The following assumptions are made

·        You have a working Oracle RAC Database12c ideally running at version 12.1.0.2 (Database and Clusterware)

·        You have downloaded the very latest version of swingbench

·        You’ve installed the SOE benchmark usingthe oewizard

·        You’re running on a Physical or VirtualMachine (Virtual Box)

·        You are using the thin jdbcdriver with swingbench

 

My configuration


In this example I’m using a 2 node RAC cluster for simplicity but I’vevalidated the configuration on an 8 node cluster as well. My configuration

OS : Linux 6
Nodes : RAC1, RAC2
SCAN : racscan
CDB : orcl
PDB : soe
schema : soe

So after you’ve confirmed that the soe benchmark has been installed correctlythe next step is to define the services. I created two new ones to show thedifference between Application Continuity and standard Fast ApplicationFailover. First a non Application Continuity Service

1

2

3

4

5

srvctl add service -d orcl -s soepdb -pdb soe -preferred orcl1,orcl2

srvctl modify service -db orcl -service soepdb -failoverdelay 5

srvctl modify service -db orcl -service soepdb -failoverretry  60

srvctl modify service -db orcl -service soepdb -clbgoal SHORT

srvctl modify service -db orcl -service soepdb -rlbgoal SERVICE_TIME



Now a service defined for Application Continuity

1

2

3

4

5

6

7

srvctl add service -db orcl -service soepdb_ac -commit_outcome TRUE -retention 86400 -preferred orcl1,orcl2

srvctl modify service -db orcl -service soepdb_ac -failovertype TRANSACTION

srvctl modify service -db orcl -service soepdb_ac -failoverdelay 5

srvctl modify service -db orcl -service soepdb_ac -failoverretry  60

srvctl modify service -db orcl -service soepdb_ac -session_state STATIC

srvctl modify service -db orcl -service soepdb_ac -clbgoal SHORT

srvctl modify service -db orcl -service soepdb_ac -rlbgoal SERVICE_TIME


Then grant access to the Application Continuity package to the SOE use

1

SYS@//rac1/soepdb > GRANT EXECUTE ON DBMS_APP_CONT TO SOE;


And thats it for the database/grid. All we need to do now is to configureswingbench to connect to the services. You can do this either in the commandline, swingbench GUI or by editing the config file. The connect string shouldlook similar to this (for application continuity)

1

2

3

4

5

6

7

8

9

10

11

12

13

14

(DESCRIPTION=

  (TRANSPORT_CONNECT_TIMEOUT=5)

  (RETRY_COUNT=6)

  (FAILOVER=ON)

  (ADDRESS =

    (PROTOCOL = TCP)

    (HOST = racscan)

    (PORT = 1521)

  )

  (CONNECT_DATA=

    (SERVER = DEDICATED)

    (SERVICE_NAME = soepdb_ac)

  )

)



NOTE : EZConnect strings won’t work for this.

We’ll also need to use connection pooling. The pool definition is only exampleand should reflect the total number of threads you plan to run with. If you’veedited the definition in the config file you should end up with somethingsimilar to

1

2

3

4

5

6

7

8

9

<connectionpooling>

            <pooledinitiallimit>40</pooledinitiallimit>

            <pooledminlimit>20</pooledminlimit>

            <pooledmaxlimit>60</pooledmaxlimit>

            <pooledinactivitytimeout>50</pooledinactivitytimeout>

            <pooledconnectionwaittimeout>45</pooledconnectionwaittimeout>

            <pooledpropertycheckinterval>10</pooledpropertycheckinterval>

            <pooledabandonedconnectiontimeout>120</pooledabandonedconnectiontimeout>

</connectionpooling>


Or if you modify it via the GUI.



The final step is to enable the application continuity driver and FAN you canagain do this in the config file with the following settings 

1

2

3

4

5

6

7

<properties>

            <property key="StatementCaching">50</property>

            <property key="FastFailover">true</property>

            <property key="FetchSize">20</property>

            <property key="OnsConfiguration">nodes=rac1:6200,rac2:6200</property>

            <property key="AppContinuityDriver">true</property>

</properties>


or via the GUI



For my test I used the following Load configuration

1

2

3

4

5

6

7

8

9

10

11

12

13

14

15

16

17

<load>

        <numberofusers>60</numberofusers>

        <mindelay>0</mindelay>

        <maxdelay>0</maxdelay>

        <intermindelay>50</intermindelay>

        <intermaxdelay>500</intermaxdelay>

        <querytimeout>120</querytimeout>

        <maxtransactions>-1</maxtransactions>

        <runtime>0:0</runtime>

        <logongroupcount>5</logongroupcount>

        <logondelay>1000</logondelay>

        <logoutposttransaction>false</logoutposttransaction>

        <waittillalllogon>false</waittillalllogon>

        <statscollectionstart>0:0</statscollectionstart>

        <statscollectionend>0:0</statscollectionend>

        <connectionrefresh>0</connectionrefresh>

</load>


Or via the GUI



My complete config file is available here for reference

I’d initially suggest running with swingbench to enable the monitoring oferrors. Start swingbench




You should see a balanced number of users logged on across your instances.Although though may fluctuate depending on a number of factors.



The next step is to cause an unexpected termination of one of the resources.I’d suggest killing PMON i.e. 

[oracle@rac2 ~]$ ps -def | grep pmon

oracle    4345     1  0 05:00 ?        00:00:00 asm_pmon_+ASM2

oracle   18093     1  0 08:11 ?        00:00:00 ora_pmon_orcl2

oracle   25847  6655  0 08:37 pts/1    00:00:00 grep pmon

[oracle@rac2 ~]$ kill -9 18093


You should see a little disruption in the TPS as you kill the instance. Howlong will depend on your RAC configuration and power of machine. The followingscreen shot is from 2 VMs running on my mac. But the important point is thatswingbench won’t get any errors.




To try and see what happens without application continuity try changing theconnect string to point at the non application continuity service.



Then delete the property that forces swingbench to use the ApplicationContinuity Driver.



Rerunning and terminating the instance should result in something like this.



The important point here is the errors which normally an application developerwould need to handle without the guarantee of transactions not being appliedmore than once.




3 Comments

Ever soslightly embarassing

31/07/14 18:00

I’ve had toupdate swingbench again. I thought I made a minor refactoring update andmanaged to break more than I’d bargained for. Please use this version Buildnumber 932.

You can download it here 


11 Comments

Minor driverupdate to swingbench and dbtimemonitor

30/07/14 12:42

I’ve posted aminor update to swingbench and dbtimemonitor to bring them up to the latestversions of the jdbc drivers and fix a “few” niggling bugs. Please refresh tothese builds particularly if you plan to do any 12.1.0.2 testing in the future.

You can as always download them from here

7 Comments

New jdbcdrivers for swingbench

23/07/14 12:07

With the launchof Oracle Database 12c Release 1 (12.1.0.2) I’ve taken the opportunity toupdate the jdbc drivers that swingbench uses. If you’re testing UCP or FAN Istrongly recommend using these new drivers.

You can download it here

1 Comment

New build ofswingbench with improved stats

13/07/14 09:23

I’ve uploaded anew build of swingbench that fixes a number of bugs but also improves on thestats being produced.

One problem with using averages when analysing results is that they hide amultitude of evils. This is particularly true for response times where thereare likely to be big skews hidden if just the average is considered. You cansee this in the chart below where response times are mapped into 100 buckets.The response time range from 2 to 6274 milliseconds. The average is 257ms.



It might be that in many instances the average is adequate for your needs butif your interested in the spread of results and the impact metrics like usercounts, IO, memory etc have on the responsiveness of your system it might alsobe useful to model the spread of response so you can look for outliers.

In the latest build of swingbench when you now specify full stats collectionyou end up with a more complete set of results as shown below

257.86816475601097 2 6274 117.80819459762236 276.682001642648676552.9300329826 7.96379726468569 1.7844202125604447 14 25 43 87 170 257 354466 636 21495, 5260, 4380, 4084, 3929, 3798, 3266, 2756, 2303, 1801, 1465,1138, 889, 632, 499, 381, 259, 201, 140, 105, 102, 55, 43, 21, 21, 21, 17, 12,9, 4, 5, 3, 12, 1, 6, 3, 7, 5, 1, 1, 6, 1, 2, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0,0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1 59142 0 0

I’ve included a complete set of percentiles and some additional metrics forconsideration (variance, Kurtosis, Skewness, Geometric Mean). Over the comingweeks I’ll be attempting to process a results file into a more useful document.

You can enable stats collection in the UI from the preferences tab i.e.



You can also set it from the command line. i.e.

./charbench -bg -s -stats full -rt 0:04 -cs //oracle12c2/orcl -a -uc 25-com "Test of full stats collection" -intermin 2 -intermax 2 -bs 0:01-be 0:04 &

One thing to watch out for is that you may need to change the metric thattransactions are measure in i.e. from milliseconds to microseconds to model abetter spread of response times.

Along side the improvements to stats I’ve also fixed the following

·        Fixed windowed stats collection (-be -bs) and full stats(-stats full) working together

·        Fixed the -bg (background) option so it works on Solaris

·        Numerous stability fixes


You can download the code front he usual place here

Tags: swingbench

11 Comments

New build ofswingbench

22/05/14 17:17

I’ve justfinished a new build of swingbench and the command line got a little bit oflove. I’ve added the following new functionality


·        Added new transactions to sh benchmark

·        Percentiles now report 10th to 90th percentiles insteadof just 25th,50th and 75th percentile

·        Added a new command line option to allow users to changestats collection target.

·        Fixed the command line option “-bg” so it’s possible tobackground charbench

·        Added new commands to coordinator to make it simpler touse

·         

o   Changed -stop to -kill to better indicate what it does

·         

o   Changed -halt to -stop to indicate what it does

·         

o   Added -stopall to stop all attached clients

·         

o   Added -runall to start all attached clients

·         

o   Added -stats to enable all display aggregated transactionrates of all attached clients

·        Included python script to parse the one or more resultsfiles into csv format (located in $SWINGHOME/utils)

·        forced users to specify either -create, -drop or-generate when specify character mode (-c)


The functionality enabling you to background and the changes to the coordinatormight need a little more explaining. The idea is that you might want to run upmore than one load generator either because you want to create a trulytremendous load you want to run different load generators at differentdatabases. To do this you might want to use a combination of backgrounding theload generators and using the coordinator to start,stop and report on them. Forexample

$ ./coordinator &$ ./charbench -cs //oracle12c/pdb1 -bg -s -uc 25 -colocalhost &$ ./charbench -cs //oracle12c/pdb2 -bg -s -uc 25 -co localhost& $ ./charbench -cs //oracle12c/pdb3 -bg -s -uc 25 -co localhost &$./coordinator -runall$ ./coordinator -statsAggregated results for 3 loadgeneratorsUse Ctrl-C to halt stats collection Time Users TPM TPS 17:52:03 753898 460 17:52:06 75 5263 483 17:52:09 75 6669 489. . .. . .$./coordinator-stopall$./coordinator -kill

Note : to background charbench you must specify -bg (it indicatesthe client will no longer be taking input from stdin)

You can download it as usual from here 


9 Comments

Fixes come inthick and fast...

20/11/13 14:15

Yet another fixand some more minor UI changes.

In fixing some code I regressed some basic functionality. In the last build ifyou restarted a benchmark from within the swingbench and minibench GUI it gaveyou an error and you had to restart swingbench to get it going again. This isnow fixed in this new build.

I also took the time to add some functionality to enable you to specify Interand Intra sleep times. You can do this in the “Load” tab as shown below



It gives me the opportunity to explain the difference between inter and intrasleep times. As the name implies intra sleep times occur “inside” of atransaction. Inter sleep times occur between transactions. Many of thetransactions inside of the swingbench “SOE” have sleep times between DMLoperations (select, insert, update). In some situations this better emulateswhat happens in some legacy form based systems, this is what is controlled byintra sleep times. However most systems these days tend to utilise web basedfront ends where DML operations tend to be fired as a single operation when theuser submits a form. This approach results in a more scalable architecture withfewer locks being held and for shorter periods of time. Hopefully the followingdiagram will explain the differences in a clearer fashion.



You can also set the intra and inter sleep time from the command line with the-min (intra min) -max (intramax) -intermin (inter min) -intermax (inter max).

Tags: swingbench

0 Comments

First Updateto Swingbench 2.5

11/11/13 21:14

Just a small update to swingbench... You can download the new build here

It fixes a few of bugs

·        Incorrect partitioning defaultsspecified in the oewizard and shwizards configuration files

·        Incorrect profile of transactions for“sh” benchmark

·        “sh” benchmark transaction generatedqueries for future values that didn’t exist

·        Checks not performed on allowedpartitioning values in configuration files for wizard when run in command line

I’ve also added some functionality that should have been put in a longtime ago. A drop down list of values for the connection properties. In previousversions of swingbench unless you knew the key values for a connection propertyit was impossible to add one. The new drop down list should make it mucheasier.



So the next obvious question is “What are all the connection properties and whydid it take you so long to tell us?”. I have no idea why it took so long totell people what they were. Consider it an over sight but let me try andcorrect that now.



Connection Properties

Description

StatementCaching

This specifies the number of statements to be cached. Valid value is an integer 

DNSLoadBalancing

Force jdbc to connect to more than one scan listener. Valid values are true or false

FastFailover

Activate Oracle’s Fast Failover connection functionality. Valid values are true or false

TcpNoDelay

Sets TCP_NODELAY of a socket. Valid values are true or false

OnsConfiguration

The remote configurations of Oracle Notification Servers (ONS). Valid values are similar to this “nodes=dbserver1:6200,dbserver2:6200”. See Oracle documentation for more details and examples

MaxONSConfiguration

The number of ONS servers that jdbc will randomly select from in the advent of a failure. Valid value is an integer

TcpConnectionTimeout

The time taken between traversals of an “ADDRESS_LIST” in the advent of a failure. Specified in seconds

ReadTimeOut

The time queries wait for results before considering that a failure has occurred. Specified in seconds

BatchUpdates

The number of inserts/updates that are grouped together to improve transaction performance. Valid value is an integer

FetchSize

Number of rows fetched on each round trip to the database. Valid value is an integer




Tags: swingbench

5 Comments

Release ofSwingbench 2.5

22/10/13 17:14

I’m pleased toannounce the release of swingbench 2.5. It has a ton of fixes and newfunctionality in it but most importantly it has full support for OracleDatabase 12c. At this stage I’m going to call it Beta but only because it’sreceived a limited amount of testing inside of Oracle. Obviously let me knowwhat you think. I’ll try and provide fixes as quickly as possible to any thingyou flag up. You can download it here .

Fixes and Enhancements include

·        Fixed a bug where the wizards struggled with some timezones.

·        Fixed a bug where the init() command wasn't calledcorrectly

·        Removed unnecessary stacktrace output when invalidcommand line parameters are used

·        Fixed an integer overflow where some stats were reportedincorrectly

·        Added normal distribution of data to better model realworld data in the OE and SH benchmarks

·        Added verbose output (-v) to the wizards when run incommand line mode to provide better feedback

·        Increased the maximum heap use by oewizard and shwizardto 2GB in size

·        Updated launch parameters for java to set min and max toavoid unnecessary memory consumption

·        Users can now define their own output date format maskfor charbench via a swingbench environment variable (see FAQ)

·        Wizards in graphical mode now display a warning beforedata generation if there isn't enough temporary space to generate indexes

·        Wizards in graphical mode now display the reason theycan't connect to the database

·        Generated data is more representative of real worldformats

·        Charts in overview now display values when moused over

·        Support of backgrounding charbench, Unix/Linux only.requires the use of both the -bg swinbench option and "&"operator

·        Fixes and improvements to error suppression

·        The maximum number of soft partitions that can bespecified is limited to 48. Values larger than this cause severe performance degradation.This is being looked into.

·        Version 2.0 of the OE benchmark is included (selectablefrom the wizard).

·        Wizards allow you to specify index, compression andpartitioning models where supported (command line and GUI)

·        All scripts and variables used by wizards are listed inthe configuration file

·        Benchmark version can be specified on the command line

·        Fixed an issue where specifying max Y values in chartswas ignored

·        Support for choosing whether commits are executed clientor server side in the SOE Benchmark -D CommitClientSide=true

·        Wizards recommend a default size for the benchmarks basedon the size of the SGA

·        The customers and supplementary_demographics table arenow range partitioned in the SH schema if the range portioned option isspecified

·        New overview chart parameter (config fileonly)  allows you specify what YValue a chart will start at

·        Wizards allow the creation of schemas with or withoutindexes

·        The sh schema now allows a partitioned or non partitionedschema

·        Updated XML infrastructure

·        Removed unneeded libraries and reduced size ofdistribution

·        Errors in transactions can now be reported via the -verrs command line option

·        Tidied up error reporting. Errors should be reportedwithout exception stacks unless running in debug mode

·        Fixed a problem where it wasn't possible to restart abenchmark run when using connection pooling

18 Comments

Using thewizards in comand line mode

15/07/13 16:21

I’ve just beenreminded that not everybody knows that you can run swingbench in command linemode to use nearly all of it’s functionality. Whilst VNC means that you can usethe graphical front end for most operations sometimes you need a little moreflexibility. One area that this is particularly useful is when you’re creatinglarge benchmark schemas for the SOE and SH benchmarks via the wizards (oewizard,shwizard). To find out what commands you can use just use the “-h” option. As you can see below there’s access to nearlyall of the parameters (and a few more) that are available in the graphical userinterface.

usage: parameters: -allindexes build all indexes for schema -bigfile usebig file tablespaces -c wizard config file -cl run in character mode-compositepart use a composite paritioning model if it exisits -compress usedefault compression model if it exists -create create benchmarks schema-cs connectring for database -dba dba username for schema creation-dbap password for schema creation -debug turn on debugging output -debugfturn on debugging output to file (debug.log) -dfdatafile name used to createschema in -drop drop benchmarks schema -dt driver type (oci|thin) -g runin graphical mode (default) -generate generate data for benchmark if available-h,--help print this message -hashpart use hash paritioning model if it exists-hcccompress use HCC compression if it exisits -nocompress don't use anydatabase compression -noindexes don't build any indexes for schema -nopartdon't use any database partitioning -normalfile use normal file tablespaces-oltpcompress use OLTP compression if it exisits -p password for benchmarkschema -part use default paritioning model if it exists -pkindexes only createprimary keys for schema -rangepart use a range paritioning model if it exisits-s run in silent mode -scale mulitiplier for default config -sp thenumber of softparitions used. Defaults to cpu count -tc the number ofthreads(parallelism) used to generate data. Defaults to cpus*2-ts tablespace to create schema in -uusername for benchmark schema -v runin verbose mode when running from command line -version version of thebenchmark to run


Using these parameters its possible to specify a complete install and dropoperation from the command line. For example

./oewizard -scale 10 -cs //oracle12c/orcl -dbap manager -ts SOE -tc 32 -nopart-u soe -p soe -cl -df /home/oracle/app/oracle/oradata/ORCL/datafile/soe.dbf
This will create a 10 GB (Data) schema using 32 threads, use no partitioningand use the soe schema.

You can drop the same schema with the following command 

./oewizard -scale 0.1 -cs //oracle12c/orcl -dbap manager -ts SOE -u soe -p soe-cl -drop

I use this approach to create lots of schemas to automate some form of testing…The following enables me to create lots of schemas o analyse how the SOEbenchmark performs as the size of the data set and index increase.

./oewizard -scale 1 -cs //oracle12c/orcl -dbap manager -ts SOE1 -tc 32 -nopart-u soe1 -p soe1 -cl -df/home/oracle/app/oracle/oradata/ORCL/datafile/soe1.dbf./oewizard -scale 5 -cs//oracle12c/orcl -dbap manager -ts SOE5 -tc 32 -nopart -u soe5 -p soe5 -cl -df/home/oracle/app/oracle/oradata/ORCL/datafile/soe5.dbf./oewizard -scale 10 -cs//oracle12c/orcl -dbap manager -ts SOE10 -tc 32 -nopart -u soe10 -p soe10 -cl-df /home/oracle/app/oracle/oradata/ORCL/datafile/soe10.dbf./oewizard -scale 20-cs //oracle12c/orcl -dbap manager -ts SOE20 -tc 32 -nopart -u soe20 -p soe20-cl -df /home/oracle/app/oracle/oradata/ORCL/datafile/soe20.dbf./oewizard-scale 40 -cs //oracle12c/orcl -dbap manager -ts SOE40 -tc 32 -nopart -u soe40-p soe40 -cl -df /home/oracle/app/oracle/oradata/ORCL/datafile/soe40.dbf./oewizard-scale 80 -cs //oracle12c/orcl -dbap manager -ts SOE80 -tc 32 -nopart -u soe80-p soe80 -cl -df /home/oracle/app/oracle/oradata/ORCL/datafile/soe80.dbf

Tags: schemaswingbenchCommand Line

2 Comments

Changing javalibraries and increasing the heap size used by swingbench

15/01/12 11:57

I’ve been askeda couple of times recently about how to change the infrastructure librariesi.e. the Oracle jdbc driver. I try to always ship the latest jdbc/ons/ucplibraries but its possible that Oracle may realease a patch set whilst I’mworking on something else. Its also possible people may want to investigate abug or performance problem by trying out a selection of drivers. To change thejar files all that is needed is to move the old version out of the libdirectory and copy the new one in, for example

$> cd swingbench$> mv lib/ojdbc6.jar ~/backup/ojdbc6.jar$> cp~/newjdbc/ojcbc6.jar lib

Don’t try and keep multiple versions of the same driver in the lib directory.It can lead to unexpected results. When swingbench starts it looks in the libdirectory for all the libraries (contained in the jar files) to use.

If you need to increase the amount of memory used by swingbench you need toedit a file called launcher.xml in the launcher directory. You might need to dothis if you are planning to run with many thousands of threads. You need tochanged the default value (1024m) to a larger one. For example


to something like


Tags: Configuration

1 Comment

New build ofswingbench 2.4

08/12/11 19:56

I’ve justuploaded a new build of swingbench with the following fixes


·        Wizard now writes output to debug.log correctly with the-debugFile option

·        Fixed bug where partitioning was always installedregardless. This meant the wizards couldn't install against a standard editiondatabase

·        Fixed a bug where swingbench wouldn't start unless allusers were able to log on. Swingbench will now start when it has logged on asmany users as it can.

·        Fixed a bug where users were incorrectly counted as beinglogged on

·        Fixed a bug where logging wasn't correctly written to adebug file

·        Changed -debugFile to -debugf to provide consistency withother tools

·        Changed to way users logged on is reported in verbosemode of charbench 

·        Updated the secure shell libraries to support Solaris 11


You can find it here. Let me know if you find any problems.

Tags: swingbench new release

0 Comments

2.4 makes itto stable status

08/11/11 16:02

At last I feelthat I’ve fixed enough bugs and had enough feed back to change 2.4 to stablestatus. This means that this should be the default client most groups use.Based on the feedback I get I’ll remove 2.3 from the downloads page.

There has been a few changes in this release. These include

·        Improvements to the Overviewchart to provide dynamicYXAxis and floating legends

·        The overview chart now uses a 5 second rolling window forresponse time metrics as opposed to a meaningless average

·        “Minibench” has been made a little bigger 

·        Numerous fixes to the wizards

·        Numerous fixes to Universal Connection Pooling

·        New command line options


The new Overview chart is show below


As per usual you can download it here

3 Comments

New Build ofswingbench 2.4

06/05/11 18:43

It’s been 2 or 3months since the last drop of swingbench and so it will come as no surprisethat I’ve released another build. This release features

·        Fix to enable the jdbc version of the SOE benchmark towork without errors. I’ll be updating it over the coming week to try and makeit as close as possible to the PL/SQL version

·        A new parameter (and UI change) to support thedisconnect/connection of sessions after a fixed number of transactions

·        Various fixes



0 Comments

New build ofswingbench 2.4

15/02/11 10:22

I’ve justuploaded a new build of swingbench 2.4 it has a number of bug fixes which sortout some of the following issues

§ Unexpected termination due to driver issues

§ Unclear timeline text on the overview chart

§ Numerous UI and java issues


You can download it here
Let me know if you have any problems via the comment page

Tags: swingbench new release

0 Comments

New build ofSwingbench

31/08/10 16:22

After a bit of a delay Im releasing a new build of swingbench. It has alarge number of fixes reflected in the difference in build numbers. Some of thechanges include

·        A new report at the end of wizard driveninstall that details the speed of the install but also whether the objects thathave been created are valid

· &nb

给我老师的人工智能教程打call!http://blog.csdn.net/jiangjunshow
这里写图片描述
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值