StartupLOG:: ->record = ReadCheckpointRecord(xlogreader,Controlfile->checkPoint,1,true) ->record = ReadRecord(xlogreader,LOG,true) ->record = XLogReadRecord(xlogreader,&errormsg); ->readOff = ReadPageInternal(state,Controlfile->checkPoint - (Controlfile->checkPoint % XLOG_BLCKSZ),Min(ontrolfile->checkPoint % XLOG_BLCKSZ + SizeOfXLogRecord,XLOG_BLCKSZ)); ->|--pageptr=Controlfile->checkPoint - (Controlfile->checkPoint % XLOG_BLCKSZ) |--targetPageOff = (pageptr % XLogSegSize);//段文件偏移 |--targetSegmentPtr = pageptr - targetPageOff; |--readLen = state->read_page(state,targetSegmentPtr(0?),XLOG_BLCKSZ,state->readBuf,&state->readPageTli); ->WaitForWALToBecomeAvailable(targetSegmentPtr(0?) + XLOG_BLCKSZ,private->randAccess,targetRecPtr) ->readfile = XLogfileReadAnyTli(targetSegmentPtr/XLogSegSize,DEBUG2,currentSource == XLOG_FROM_ARCHIVE ? XLOG_FROM_ANY :currentSource) ->fd = XLogfileRead(segno,emode,tli,XLOG_FROM_ARCHIVE或者XLOG_FROM_PG_WAL,true) ->fd = Basicopenfile(path,O_RDONLY | PG_BINARY,0); ->fd = open(filename,fileFlags,fileMode)
总结 以上是内存溢出为你收集整理的PostgreSQL启动恢复通过checkpoint open wal文件全部内容,希望文章能够帮你解决PostgreSQL启动恢复通过checkpoint open wal文件所遇到的程序开发问题。
如果觉得内存溢出网站内容还不错,欢迎将内存溢出网站推荐给程序员好友。
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)