Skip to content

Instantly share code, notes, and snippets.

@fujieda
Created December 2, 2011 12:01
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save fujieda/1422998 to your computer and use it in GitHub Desktop.
Save fujieda/1422998 to your computer and use it in GitHub Desktop.
A dtrace script to investigate the behavior of L2ARC writing to its storages.
#!/usr/sbin/dtrace -qs
l2arc_write_buffers:entry
{
self->guid = ((l2arc_dev_t *)arg1)->l2ad_vdev->vdev_guid;
}
l2arc_write_buffers:return
{
printf("%lu: dev: %llx written: %ld\n", timestamp / 1000000, self->guid, arg1);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment