The name of the extracted file is the same as the WAL segment file. It consists of 24 hexadecimal digits,that number is always increasing.
For example, if there is a transaction's COMMIT log in a WAL segment file named 000000010000000000001C, then all the transaction's userlog sequence will be output to an extract file named 000000010000000000001C, even if the transaction inserted userlogs in an earlier segment file.
If no completion logs appear in a segment file for transactions that have inserted userlogs, an extract file with the same name as the segment file contains zero bytes.
This file has read permission only to the PostgreSQL user (the user who started the database cluster). This is because the contents of the userlog are equivalent to WAL segment files.
For details on the format of the extracted file, refer to "Appendix A Userlog File Format".
The most recent file that has been extracted can be seen from the latest_extracted_filename column of the pgx_stat_userlog view. For information about the pgx_stat_userlog view, refer to "Appendix B pgx_stat_userlog View"
Note
Files newer than those listed in the latest_extracted_filename column of the pgx_stat_userlog view are still being created and should not be used.
Use the information in the pgx_stat_userlog view of the instance that output the extract file you want to access to determine which extract file you have created. This is because information from views of other instances is staggered and can lead to incorrect decisions.
Once extracted, you can delete the extracted file at any time.
However, do not delete userlog_control and the file named userlog_control.tmp that is created during the creation of userlog_control to control extraction under the directory specified in userlog.directory.
This file contains the information needed to continue extracting across reboots. for example, which files were extracted up to, and where the oldest userlogs were emitted by the transaction that was running when the last extract was created (which archive file should be read over to create the next extract).
This directory also contains a file named pgx_userlog_control.log that contains a history of the extraction control file's init or set mode initialization commands. You can delete this file without any problems, but we recommend that you do not delete it because it may take longer to investigate if something goes wrong.
This file increases by about 50 bytes each time the initialization command is executed.