This is a discussion on Process taking most of Logcal Log within the Informix forums, part of the Database Server Software category; --> Version: IDS 10 Is there a way to tell which process on the box is filling up the logs. ...
| |||||||
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| |||
| mohitanchlia@gmail.com wrote: > Version: IDS 10 > > Is there a way to tell which process on the box is filling up the > logs. I was thinking if there is a way to tell which process / thread > is writing the logical logs or filling up the logical logs > It's the lio vp, except when the logical logs are placed in dbspaces on raw devices - then it's cpu vp using kaio. |
| |||
| Claus Samuelsen wrote: > mohitanchlia@gmail.com wrote: > >> Version: IDS 10 >> >> Is there a way to tell which process on the box is filling up the >> logs. I was thinking if there is a way to tell which process / thread >> is writing the logical logs or filling up the logical logs >> > > It's the lio vp, except when the logical logs are placed in dbspaces on > raw devices - then it's cpu vp using kaio. I think what the poster is asking is which session is filling up the logical logs, not what is actually writing to the logical logs. onstat -g tpf will show the number of log records each thread has written : > onstat -g tpf IBM Informix Dynamic Server Version 10.00.FC6 -- On-Line -- Up 6 days 16:22:11 -- 179276 Kbytes Thread profiles tid lkreqs lkw dl to lgrs isrd iswr isrw isdl isct isrb lx bfr bfw lsus lsmx seq So, do this a few times to see which thread is writing all the "lgrs" : onstat -g tpf | sort -rnk 7 | head | awk '{print $1 " " $7}' Once you know the thread, back track it to the session. |
| |||
| On Sep 6, 2:31 am, "TBP (The Big Potato)" <T...@NotHere.Co.Uk> wrote: > Claus Samuelsen wrote: > > mohitanch...@gmail.com wrote: > > >> Version: IDS 10 > > >> Is there a way to tell which process on the box is filling up the > >> logs. I was thinking if there is a way to tell which process / thread > >> is writing the logical logs or filling up the logical logs > > > It's the lio vp, except when the logical logs are placed in dbspaces on > > raw devices - then it's cpu vp using kaio. > > I think what the poster is asking is which session is filling up the logical logs, not what is actually writing to the logical logs. > > onstat -g tpf will show the number of log records each thread has written : > > > onstat -g tpf > > IBMInformixDynamic Server Version 10.00.FC6 -- On-Line -- Up 6 days 16:22:11 -- 179276 Kbytes > > Thread profiles > tid lkreqs lkw dl to lgrs isrd iswr isrw isdl isct isrb lx bfr bfw lsus lsmx seq > > So, do this a few times to see which thread is writing all the "lgrs" : > > onstat -g tpf | sort -rnk 7 | head | awk '{print $1 " " $7}' > > Once you know the thread, back track it to the session. Thanks this is what I was looking for. Is it possible to know the thread that may no longer exist, but which could have written lot of logs. Does informix preserve history of logical log records ? I have another question, for which I think answer is "no", but I'll still ask. Is there a way to tell for a given timeframe how many logs were written and who was writing it. |
| |||
| On Sep 9, 3:11 pm, mohitanch...@gmail.com wrote: > On Sep 6, 2:31 am, "TBP (The Big Potato)" <T...@NotHere.Co.Uk> wrote: > > > > > Claus Samuelsen wrote: > > > mohitanch...@gmail.com wrote: > > > >> Version: IDS 10 > > > >> Is there a way to tell which process on the box is filling up the > > >> logs. I was thinking if there is a way to tell which process / thread > > >> is writing the logical logs or filling up the logical logs > > > > It's the lio vp, except when the logical logs are placed in dbspaces on > > > raw devices - then it's cpu vp using kaio. > > > I think what the poster is asking is which session is filling up the logical logs, not what is actually writing to the logical logs. > > > onstat -g tpf will show the number of log records each thread has written : > > > > onstat -g tpf > > > IBMInformixDynamic Server Version 10.00.FC6 -- On-Line -- Up 6 days 16:22:11 -- 179276 Kbytes > > > Thread profiles > > tid lkreqs lkw dl to lgrs isrd iswr isrw isdl isct isrb lx bfr bfw lsus lsmx seq > > > So, do this a few times to see which thread is writing all the "lgrs" : > > > onstat -g tpf | sort -rnk 7 | head | awk '{print $1 " " $7}' > > > Once you know the thread, back track it to the session. > > Thanks this is what I was looking for. Is it possible to know the > thread that may no longer exist, but which could have written lot of > logs. Does informix preserve history of logical log records ? > > I have another question, for which I think answer is "no", but I'll > still ask. Is there a way to tell for a given timeframe how many logs > were written and who was writing it. Logical logs still on disk are reported by onstat -l and can be viewed using onlog (viewing the 'current' log will suspend activity that needs to update the log so be careful). Once logs are no longer needed (ie they have no more open transactions in them and have been archived, they are eligible to be reused. IDS cycles through the logical logs in order, when it hits the last one it reuses the first one if that's available and so on. You can use onlog to view logical logs archived using onbar or ontape -a or -c directly from the tape/ disk archive. If you are only archiving logs as part of the system archive and are discarding them after use (by setting LTAPEDEV to /dev/ null) then you can only view those logs saved by an archive and only be restoreing the archive to disk somewhere. Art S. Kagel |
| |||
| > I have another question, for which I think answer is "no", but I'll > still ask. Is there a way to tell for a given timeframe how many logs > were written and who was writing it The administartion file, "online.log" or whatever you chose to call it, will have an entry in it with a timestamp every time alogical log is complete eg 14:41:12 Logical Log 29128 Complete, timestamp: 0x56b314f9. 14:41:37 Logical Log 29129 Complete, timestamp: 0x56b4c52f. 14:41:49 Logical Log 29130 Complete, timestamp: 0x56b5bc98. So you can see how quickly the logs are filling up you can then use onstat -l in the manner Art described to see who is writing to them |
| |||
| On Sep 10, 6:18 am, "Art S. Kagel" <art.ka...@gmail.com> wrote: > On Sep 9, 3:11 pm, mohitanch...@gmail.com wrote: > > > > > On Sep 6, 2:31 am, "TBP (The Big Potato)" <T...@NotHere.Co.Uk> wrote: > > > > Claus Samuelsen wrote: > > > > mohitanch...@gmail.com wrote: > > > > >> Version: IDS 10 > > > > >> Is there a way to tell which process on the box is filling up the > > > >> logs. I was thinking if there is a way to tell which process / thread > > > >> is writing the logical logs or filling up the logical logs > > > > > It's the lio vp, except when the logical logs are placed in dbspaces on > > > > raw devices - then it's cpu vp using kaio. > > > > I think what the poster is asking is which session is filling up the logical logs, not what is actually writing to the logical logs. > > > > onstat -g tpf will show the number of log records each thread has written : > > > > > onstat -g tpf > > > > IBMInformixDynamic Server Version 10.00.FC6 -- On-Line -- Up 6 days 16:22:11 -- 179276 Kbytes > > > > Thread profiles > > > tid lkreqs lkw dl to lgrs isrd iswr isrw isdl isct isrb lx bfr bfw lsus lsmx seq > > > > So, do this a few times to see which thread is writing all the "lgrs" : > > > > onstat -g tpf | sort -rnk 7 | head | awk '{print $1 " " $7}' > > > > Once you know the thread, back track it to the session. > > > Thanks this is what I was looking for. Is it possible to know the > > thread that may no longer exist, but which could have written lot of > > logs. Doesinformixpreserve history of logical log records ? > > > I have another question, for which I think answer is "no", but I'll > > still ask. Is there a way to tell for a given timeframe how many logs > > were written and who was writing it. > > Logical logs still on disk are reported by onstat -l and can be viewed > using onlog (viewing the 'current' log will suspend activity that > needs to update the log so be careful). Once logs are no longer > needed (ie they have no more open transactions in them and have been > archived, they are eligible to be reused. IDS cycles through the > logical logs in order, when it hits the last one it reuses the first > one if that's available and so on. You can use onlog to view logical > logs archived using onbar or ontape -a or -c directly from the tape/ > disk archive. If you are only archiving logs as part of the system > archive and are discarding them after use (by setting LTAPEDEV to /dev/ > null) then you can only view those logs saved by an archive and only > be restoreing the archive to disk somewhere. > > Art S. Kagel onlog commands give different information about COMMIT, DELETE etc. with the transaction id. Is there a way to tell on which tables these transactions are working on or something which gives more information about the data in logical log. I was thinking that onlog would show the data in the logical log, may be it does and I am just not aware of displaying the data in logical log. I was thinking something that tells me what data got deleted or inserted and which table was affected. |
| |||
| mohitanchlia@gmail.com wrote: > > onlog commands give different information about COMMIT, DELETE etc. > with the transaction id. Is there a way to tell on which tables these > transactions are working on or something which gives more information > about the data in logical log. I was thinking that onlog would show > the data in the logical log, may be it does and I am just not aware > of displaying the data in logical log. I was thinking something that > tells me what data got deleted or inserted and which table was > affected. Output from onlog: 2ec044 76 HINSERT 6 0 2ec018 20004c 135 17 Column 7 (20004c) is the table's partnumber (in decimal: 2097228). You can use the decimal value to find the table in the systables catalog table. |
| ||||
| Claus Samuelsen wrote: > mohitanchlia@gmail.com wrote: >> >> onlog commands give different information about COMMIT, DELETE etc. >> with the transaction id. Is there a way to tell on which tables these >> transactions are working on or something which gives more information >> about the data in logical log. I was thinking that onlog would show >> the data in the logical log, may be it does and I am just not aware >> of displaying the data in logical log. I was thinking something that >> tells me what data got deleted or inserted and which table was >> affected. > > Output from onlog: > > 2ec044 76 HINSERT 6 0 2ec018 20004c 135 17 > > Column 7 (20004c) is the table's partnumber (in decimal: 2097228). You > can use the decimal value to find the table in the systables catalog table. No need to convert to decimal: where partnum = "0x20004c" .... will work fine. |