Re: [HACKERS] xlogfilename - Mailing list pgsql-hackers

From DEV_OPS
Subject Re: [HACKERS] xlogfilename
Date
Msg-id a33333a9-a782-b3ec-b38c-8b54b4e4f2bb@ww-it.cn
Whole thread Raw
In response to [HACKERS] xlogfilename  (王刚 <computer_wg@163.com>)
Responses Re: [HACKERS] xlogfilename
List pgsql-hackers
I think you may reference to function: pg_xlogfile_name   in
src/backend/access/transam/xlogfuncs.c,  it use XLogFileName  defined in
src/include/access/xlog_internal.h

#define XLogFileName(fname, tli, logSegNo)  \   snprintf(fname, MAXFNAMELEN, "%08X%08X%08X", tli,       \
(uint32)((logSegNo) / XLogSegmentsPerXLogId), \            (uint32) ((logSegNo) % XLogSegmentsPerXLogId))
 


hope it's helpful for you

--Tony

On 20/07/2017 16:42, 王刚 wrote:
> I study source code about wal, and have a question about xlog file name . what does 000000010000000000000001 mean?
Someonesays that it means tli logid segno. I don't understand.
 






pgsql-hackers by date:

Previous
From: 王刚
Date:
Subject: [HACKERS] xlogfilename
Next
From: Michael Paquier
Date:
Subject: Re: [HACKERS] xlogfilename