1 Star2 Stars3 Stars4 Stars5 Stars (还没有评分)
Loading...

“dynamic variable drops”错误解析

DTrace中关联数组(associative array)所占据的内存容量是由可调节参数dynvarsize决定的。由于每次DTrace脚本运行时,内存都会根据dynvarsize分配好。因此一旦耗尽,就会报出“dynamic variable drops”的错误。以下列程序为例:

dtrace -n 'int t[int]; tick-1ms { t[timestamp] = timestamp }'  

运行结果如下:

# dtrace -n 'int t[int]; tick-1ms { t[timestamp] = timestamp }'
dtrace: description 'int t[int]' matched 1 probe
dtrace: 972 dynamic variable drops
dtrace: 1001 dynamic variable drops
dtrace: 1000 dynamic variable drops
......

参考资料:
Safety and errors

Leave a Reply

Your email address will not be published. Required fields are marked *