In response to "sathiya psql" <sathiya(dot)psql(at)gmail(dot)com>:
> Dear Friends,
> I have a table with 32 lakh record in it. Table size is nearly 700 MB,
> and my machine had a 1 GB + 256 MB RAM, i had created the table space in
> RAM, and then created this table in this RAM.
> So now everything is in RAM, if i do a count(*) on this table it returns
> 327600 in 3 seconds, why it is taking 3 seconds ????? because am sure that
> no Disk I/O is happening. ( using vmstat i had confirmed, no disk I/O is
> happening, swap is also not used )
> Any Idea on this ???
Yes. It takes your hardware about 3 seconds to read through 700M of ram.
Keep in mind that you're not just reading RAM. You're pushing system
requests through the VFS layer of your operating system, which is treating
the RAM like a disk (with cylinder groups and inodes and blocks, etc) so
you have all that processing overhead as well. What filesystem did you
format the RAM disk with?
Why are you doing this? If you have enough RAM to store the table, why
not just allocate it to shared buffers?
Collaborative Fusion Inc.
In response to
pgsql-performance by date
|Next:||From: Ivan Voras||Date: 2008-03-25 13:16:43|
|Subject: Re: what is the maximum number of rows in a table in postgresql 8.1|
|Previous:||From: Craig Ringer||Date: 2008-03-25 13:09:34|
|Subject: Re: what is the maximum number of rows in a table in postgresql