Bruce Momjian
0a78320057
pgindent run for 9.4
...
This includes removing tabs after periods in C comments, which was
applied to back branches, so this change should not effect backpatching.
12 years ago
Bruce Momjian
f9bb944cd8
pg_test_fsync: add C comment about direct I/O and write size failure
...
Report from Marti Raudsepp
12 years ago
Bruce Momjian
43f6388931
pg_test_fsync: expand ops/sec display
...
Expand ops/sec by two digits to maintain alignment on servers with fast
I/O subsystems, e.g. can now display < 10M ops/sec with consistent
alignment.
12 years ago
Heikki Linnakangas
b5ed21998c
Fix pg_test_fsync, broken by xloginsert scaling patch.
...
I didn't realize that ALIGNOF_XLOG_BUFFER was used in pg_test_fsync.
12 years ago
Bruce Momjian
06b804377c
Remove undocumented -h (help) option
...
The -h option was not supported by many tools, and not documented, so
remove them for consistency from pg_upgrade, pg_test_fsync, and
pg_test_timing.
12 years ago
Bruce Momjian
095018bc32
pg_test_fsync: update output to show usecs/op clearer
13 years ago
Tom Lane
3c07fbf40b
Use pqsignal() in contrib programs rather than calling signal(2) directly.
...
The semantics of signal(2) are more variable than one could wish; in
particular, on strict-POSIX platforms the signal handler will be reset
to SIG_DFL when the signal is delivered. This demonstrably breaks
pg_test_fsync's use of SIGALRM. The other changes I made are not
absolutely necessary today, because the called handlers all exit the
program anyway. But it seems like a good general practice to use
pqsignal() exclusively in Postgres code, now that we have it available
everywhere.
13 years ago
Tom Lane
70ec2f8f43
Improve the documentation about commit_delay.
...
Clarify the docs explaining what commit_delay does, and add a
recommendation about a useful value for it, namely half of the single-page
fsync time reported by pg_test_fsync. This is informed by testing of
the new-in-9.3 implementation of commit_delay; in prior versions it
was far harder to arrive at a useful setting.
In passing, do some wordsmithing and markup-fixing in the same general
area.
Also, change pg_test_fsync's default time-per-test from 2 seconds to 5.
The old value was about the minimum at which the results could be taken
seriously at all, and so seems a tad optimistic as a default.
Peter Geoghegan, reviewed by Noah Misch; some additional editing by me
13 years ago
Bruce Momjian
bd9c8e741b
Move long_options structures to the top of main() functions, for
...
consistency.
Per suggestion from Tom.
13 years ago
Tom Lane
427fd88552
Fix unportable format string.
...
Per compiler warning.
13 years ago
Simon Riggs
82e429794b
Add microsecs/op display to pg_test_fsync utility
...
e.g. fsync 2103.613 ops/sec ( 475 microsecs/op)
Peter Geoghegan
13 years ago
Bruce Momjian
927d61eeff
Run pgindent on 9.2 source tree in preparation for first 9.3
...
commit-fest.
13 years ago
Bruce Momjian
388c2f9325
Fix pg_test_fsync Win32 problems reported by the build farm; add
...
comments about the alarm method used on Win32.
14 years ago
Bruce Momjian
7ae2db1d1e
Try to get pg_test_thread to compile on Windows by using a sleeper
...
thread.
14 years ago
Bruce Momjian
0a8396e35e
Change contrib/pg_test_fsync to control tests in terms of seconds per
...
test, rather than a number of test cycles. Changes -o/cycles option to
-s/seconds.
14 years ago
Bruce Momjian
2bbd88f8f8
Improve labeling of pg_test_fsync open_sync test output.
14 years ago
Robert Haas
ab7d4213f9
If pg_test_fsync is interrupted, clean up the temp file.
...
Marti Raudsepp, with additional paranoia by me.
14 years ago
Peter Eisentraut
3a8dcd9a1f
Put pg_test_fsync --help and --version output in line with conventions
...
Foremost, it should go to stdout.
15 years ago
Peter Eisentraut
001cbb145f
Avoid unused variable warnings for certain configurations
15 years ago
Bruce Momjian
bf50caf105
pgindent run before PG 9.1 beta 1.
15 years ago
Bruce Momjian
303b7fcd10
Modify pg_test_fsync to match the behavior of git head in regards to
...
O_DIRECT behavior.
15 years ago
Bruce Momjian
4fec63f94e
Per Peter E, use 'kB' for kilobyte, not 'K'.
15 years ago
Bruce Momjian
00869024cb
In pg_test_fsync, use K(1024) rather than k(1000) for write size units.
15 years ago
Bruce Momjian
64bc872761
Adjust pg_test_fsync to always do XLOG_BLCKSZ-sized writes, rather than
...
always 8k writes, per suggestion from Tom. Also adjust open_sync output
layout.
15 years ago
Bruce Momjian
9dd7933937
Use XLOG_BLCKSZ in pg_test_fsync, rather than our own define, but verify
...
it is 8k as expected.
15 years ago
Bruce Momjian
9fc0192283
In test_open_sync(), writes kilobytes as intended, not by bytes.
15 years ago
Tom Lane
37eb2cd4ad
More pg_test_fsync fixups.
...
Reduce #includes to minimum actually needed; in particular include
postgres_fe.h not postgres.h, so as to stop build failures on some
platforms.
Use get_progname() instead of hardwired program name; improve error
checking for command line syntax; bring error messages into line with
style guidelines; include strerror result in die() cases.
15 years ago
Tom Lane
3ae28ce8c4
Suppress unused-variables warning when OPEN_SYNC_FLAG isn't defined.
...
Per buildfarm.
15 years ago
Tom Lane
cb38ab6d3b
More pg_test_fsync cleanup.
...
Un-break Windows build (I hope) by making the HAVE_FSYNC_WRITETHROUGH
code match the backend. Fix incorrect program help message. static-ize
all functions.
15 years ago
Tom Lane
bc616703e8
Clean up pg_test_fsync commit.
...
Actually rename the program, rather than just claiming we did. Hook it
into the build system. Get rid of useless dependency on libpq. Clean up
#include list and messy whitespace.
15 years ago
Bruce Momjian
b35bfcae93
Update C banner on new pg_test_fsync file.
15 years ago
Bruce Momjian
606a3d54fc
Move test_fsync to /contrib.
15 years ago
Bruce Momjian
8995440e38
In test_fsync, adjust test headings to match wal_sync_method values;
...
add more test cases for open_sync of different sizes.
15 years ago
Bruce Momjian
08af45f4ff
Add getopt() support to test_fsync; also fix printf() format problem.
15 years ago
Bruce Momjian
e0c274679c
In test_fsync, use #define for printf format of ops/sec.
15 years ago
Bruce Momjian
6dc15e3bef
Use O_DIRECT in O_SYNC test of different size. Restructure O_DIRECT
...
error reporting to be more consistent.
15 years ago
Bruce Momjian
3eebb33ddd
Reverse number of stars used for test_fsync details.
15 years ago
Bruce Momjian
431605f666
In test_fsync, warn about options without o_direct that are not used by
...
Postgres, and cases where o_direct does not work with certain file systems.
15 years ago
Bruce Momjian
001d3664e3
Have test_fsync output details that fdatasync is the default
...
wal_sync_method on Linux.
15 years ago
Bruce Momjian
169516ad93
Restructure test_fync to use modular C so there is less duplicate code
...
and it can be enhanced easier.
15 years ago
Bruce Momjian
3ab80cfe03
Improve output display of test_fsync.
15 years ago
Bruce Momjian
677b06ca46
Apply patch for test_fsync to add tests for O_DIRECT.
...
Adjusted patch by Josh Berkus
15 years ago
Tom Lane
e77f605d43
Remove excess argument to open(2).
...
Many compilers don't complain about this, but some do, and it's certainly
wrong. Back-patch to 8.4 where the error was introduced.
Mark Kirkwood
15 years ago
Magnus Hagander
9f2e211386
Remove cvs keywords from all files.
15 years ago
Bruce Momjian
bae8283557
Print each test_fsync description while test is running, rather than at
...
the end.
15 years ago
Bruce Momjian
239d769e7e
pgindent run for 9.0, second run
15 years ago
Bruce Momjian
2330d9c147
Simplify test_fsync duration computation.
15 years ago
Bruce Momjian
7341a8cab2
Report test_fynsc times in tests per second, instead of total seconds.
15 years ago
Bruce Momjian
65e806cba1
pgindent run for 9.0
16 years ago
Bruce Momjian
017c47bf51
test_fsync:
...
Improve test descriptions displayed during test_fsync; increase default
loops to 5k.
16 years ago