Re: [HACKERS] [PATCHES] serverlog rotation/functions

2004-07-15 Thread Bruce Momjian
Andreas Pflug wrote: > > You do something that splits the value into directory name and file name > > and removes every letter after %. > > > > /var/log > > postgresql.log.%-%-%_%%% > > > > Another idea is to allow filename wildcards in the listing so it > > becomes: > > > > SELECT *

Re: [HACKERS] [PATCHES] serverlog rotation/functions

2004-07-15 Thread Andreas Pflug
Bruce Momjian wrote: I don't see any reason to have a pattern though I suppose if you mix pgsql log files in with other log files it might be a problem. One idea would be for the client-side program to do some processing like this: SELECT * FROM dir_listing('/var/log') AS dir

Re: [HACKERS] [PATCHES] serverlog rotation/functions

2004-07-15 Thread Bruce Momjian
Andreas Pflug wrote: > Bruce Momjian wrote: > > OK, I talked to Tom about this patch and I understand the issues now. > > > > I think the best solution will be to have the postmaster start a child > > process that can read the guc variables and create a log file based on > > it contents. The chil

Re: [HACKERS] [PATCHES] serverlog rotation/functions

2004-07-15 Thread Andreas Pflug
Bruce Momjian wrote: OK, I talked to Tom about this patch and I understand the issues now. I think the best solution will be to have the postmaster start a child process that can read the guc variables and create a log file based on it contents. The child would be responsible to create a new log f

Re: [HACKERS] [PATCHES] serverlog rotation/functions

2004-07-14 Thread Bruce Momjian
OK, I talked to Tom about this patch and I understand the issues now. I think the best solution will be to have the postmaster start a child process that can read the guc variables and create a log file based on it contents. The child would be responsible to create a new log file every X seconds