Hi
I just subjected postgres7.2 for some preliminary benchmarks and here are
results. The tests were performed on an ordinary gatesway PC with 256MB RAM.
I agree that test are not consistent but it was sure great to feel how fast
postgres is.
And it was real nice to see postgres shifting to multiple process model..
Help yourself...
Shridhar
Database:- Postgres7.2
OS:- MDK8.1, 2.4.8-26mdk
Hardware Spec:
500MHz P-II/256MB/12GB IDE disk
1)10M Row test.
Database optimisation option :- -F
ShmMax :- 128MB (Default configured by MDK8.1.
Database load time :- Not recorded
[shridhar@perth dbs]$ time pgbench -c10 -t1000 test
starting vacuum...end.
transaction type: TPC-B (sort of)
scaling factor: 100
number of clients: 10
number of transactions per client: 1000
number of transactions actually processed: 10000/10000
tps = 22.410772(including connections establishing)
tps = 22.418829(excluding connections establishing)
3.41user 3.70system 7:26.70elapsed 1%CPU (0avgtext+0avgdata 0maxresident)k
0inputs+0outputs (208major+81minor)pagefaults 0swaps
[shridhar@perth dbs]$ du -h
1.7M ./base/1
1.7M ./base/16555
1.6G ./base/116979
1.6G ./base
109k ./global
8.5k ./pg_clog
257M ./pg_xlog
1.8G .
[shridhar@perth dbs]$ psql test
Welcome to psql, the PostgreSQL interactive terminal.
Type: \copyright for distribution terms
\h for help with SQL commands
\? for help on internal slash commands
\g or terminate with semicolon to execute query
\q to quit
test=# select count(*) from accounts;
count
----------
10000000
(1 row)
test=# \d accounts
Table "accounts"
Column | Type | Modifiers
----------+---------------+-----------
aid | integer | not null
bid | integer |
abalance | integer |
filler | character(84) |
Primary key: accounts_pkey
test=# delete from accounts; //It took exact 15 minutes to delete all those
rows.
DELETE 10000000
test=#
2)Default Configuration test
Database optimisation option :- -F
ShmMax :- 128MB (Default configured by MDK8.1.
[shridhar@perth dbs]$ time pgbench -i test
NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index 'branches_pkey'
for table 'branches'
NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index 'tellers_pkey'
for table 'tellers'
NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index 'accounts_pkey'
for table 'accounts'
creating tables...
10000 tuples done.
20000 tuples done.
30000 tuples done.
40000 tuples done.
50000 tuples done.
60000 tuples done.
70000 tuples done.
80000 tuples done.
90000 tuples done.
100000 tuples done.
vacuum...done.
0.40user 0.06system 0:39.90elapsed 1%CPU (0avgtext+0avgdata 0maxresident)k
0inputs+0outputs (202major+47minor)pagefaults 0swaps
[shridhar@perth dbs]$
starting vacuum...end.
transaction type: TPC-B (sort of)
scaling factor: 1
number of clients: 1
number of transactions per client: 10
number of transactions actually processed: 10/10
tps = 112.120193(including connections establishing)
tps = 137.788495(excluding connections establishing)
[shridhar@perth dbs]$ du -h
1.7M ./base/1
1.7M ./base/16555
18M ./base/116979
21M ./base
109k ./global
8.5k ./pg_clog
129M ./pg_xlog
149M .
[shridhar@perth dbs]$
3)Default configuration with optimised parameters
Database optimisation option :- -F -B8192
ShmMax :- 128MB (Default configured by MDK8.1.
[shridhar@perth dbs]$ time pgbench -i test
NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index 'branches_pkey'
for table 'branches'
NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index 'tellers_pkey'
for table 'tellers'
NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index 'accounts_pkey'
for table 'accounts'
creating tables...
10000 tuples done.
20000 tuples done.
30000 tuples done.
40000 tuples done.
50000 tuples done.
60000 tuples done.
70000 tuples done.
80000 tuples done.
90000 tuples done.
100000 tuples done.
vacuum...done.
0.38user 0.01system 0:38.55elapsed 1%CPU (0avgtext+0avgdata 0maxresident)k
0inputs+0outputs (202major+47minor)pagefaults 0swaps
[shridhar@perth dbs]$ time pgbench test
starting vacuum...end.
transaction type: TPC-B (sort of)
scaling factor: 1
number of clients: 1
number of transactions per client: 10
number of transactions actually processed: 10/10
tps = 112.121450(including connections establishing)
tps = 141.394717(excluding connections establishing)
0.01user 0.01system 0:00.13elapsed 15%CPU (0avgtext+0avgdata 0maxresident)k
0inputs+0outputs (208major+50minor)pagefaults 0swaps
[shridhar@perth dbs]$
4)10M rows test with optimised parameters
Database optimisation option :- -F -B8192
ShmMax :- 128MB (Default configured by MDK8.1
With these parameters, typical memory usage of machine grew from 35MB in
default configuration to 90MB.
[shridhar@perth dbs]$ time pgbench -i -s100 test
NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index 'branches_pkey'
for table 'branches'
NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index 'tellers_pkey'
for table 'tellers'
NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index 'accounts_pkey'
for table 'accounts'
creating tables...
10000 tuples done.
...... //Skipped the output of number of tuples since it would be too long..
9990000 tuples done.
10000000 tuples done.
vacuum...done.
40.59user 0.67system 1:12:03elapsed 0%CPU (0avgtext+0avgdata 0maxresident)k
0inputs+0outputs (202major+74minor)pagefaults 0swaps
[shridhar@perth dbs]$ time pgbench -c10 -t1000 test
starting vacuum...end.
transaction type: TPC-B (sort of)
scaling factor: 100
number of clients: 10
number of transactions per client: 1000
number of transactions actually processed: 10000/10000
tps = 29.505421(including connections establishing)
tps = 29.520318(excluding connections establishing)
3.50user 3.73system 5:39.05elapsed 2%CPU (0avgtext+0avgdata 0maxresident)k
0inputs+0outputs (208major+80minor)pagefaults 0swaps
[shridhar@perth dbs]$ du -h
1.7M ./base/1
1.7M ./base/16555
1.6G ./base/116979
1.6G ./base
109k ./global
17k ./pg_clog
129M ./pg_xlog
1.7G .
Misc.
[shridhar@perth dbs]$ ps -ef |grep -i post
shridhar 14428 32460 0 13:35 pts/1 00:00:00
/usr/local/postgres/bin/postmast
shridhar 14430 14428 0 13:35 pts/1 00:00:00 postgres: stats buffer process
shridhar 14431 14430 0 13:35 pts/1 00:00:00 postgres: stats collector
proces
shridhar 14918 32460 0 15:01 pts/1 00:00:00 grep -i post
[shridhar@perth dbs]$
_______________________________________________
linux-india-help mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/linux-india-help