From: Haijin Y. <ya...@cs...> - 2002-10-02 19:10:41
|
> > Yes, it is only place where OVWRTN_REC appears. > The LKST_OVWRTN_REC event type means it is an invalid event information. > The event type is read when following situations. > (1) Overwrite was occurred during the reading the event, so it cannot be > assured that the event is right information. > (2) Reading empty event information in a buffer. > You can ignore the events. And you can filter them by using > "lkstbuf print -e \!overwritten_record" option(see "man lkstbuf"). > Currently, changing maskset cannot filter the event, supporting > this function is under consideration. > But appearing 99% of the event in a log file is very strange. > It is under investigation about this problem. > Could you tell me more detail about them? > The situation happened when my kernel is smp version and seems the two cpus content on each other for logging under lkstlogd, so wired. right now, I recompiled the kernel without SMP support, seems better. only the begging and the ending parts of the trace contains these overwritten_records. > > #lkst stop /* stop lkst */ > #lkstbuf creat -s buffer_size /* create new buffer has enough size */ What is the max buffer size can you create if RAM is plenty, say, 1G? > #lkstbuf shift /* shift to the new buffer */ when I shift to the last buffer, I can not shift back(ioctl error), Does this mean I can only use the current buffer under "lkst start" while I can use buffer in a ring manner under "lkstlogd"? If so, for example, like this, buffer 0 is a waste of mem while I can not delete it. id cpu size prev_id next_id readp writep wrap 0 0 65536 NUL NUL 4096 4480 0 1 0* 65536 NUL NUL 4096 256 1 root@sunshine: lkstbuf del -b 0 ioctl() error: Invalid argument > #lkst start /* start lkst */ > #<command or procedure what you want to trace> How long can you log the kernel with you max capacity using "lksk"? I guess I am stupid, if buffer overflow, you just overwrite it and continue the logging, you are not going to stop when buffer overflow, right? > #lkst stop /* stop lkst */ > #lkstbuf read -f filename /* read the buffer */ > > > "lkst start" starts writing events records into a buffer in the memory. > "lkstlogd" starts writing the records in the buffer to a file. > It depends on a user's intention which is used. > "lkstlogd" causes overhead for writing a file, and "lkst start" > causes overwriting as said above. > If I want to log disk activities, because lkstlogd itself involves lots of disk writes, the measurement itself is not correctly. I can only log to memory and dump them to disk after monitor is over. My major concern is that how big the memory should I create and how long can I log before memory overflow? Your help is of great help and highly appreciated! Best regards, -Haijin Yan |