-
Notifications
You must be signed in to change notification settings - Fork 871
/
cluster_event.go
9 lines (5 loc) · 5.54 KB
/
cluster_event.go
1
2
3
4
5
6
7
8
9
package constant
const AbrtAdaptor = " \n {\n \"plugin\": \"journald\",\n \"pluginConfig\": {\n \"source\": \"abrt-notification\"\n },\n \"logPath\": \"/var/log/journal\",\n \"lookback\": \"5m\",\n \"bufferSize\": 10,\n \"source\": \"abrt-adaptor\",\n \"conditions\": [],\n \"rules\": [\n {\n \"type\": \"temporary\",\n \"reason\": \"CCPPCrash\",\n \"pattern\": \"Process \\\\d+ \\\\(\\\\S+\\\\) crashed in .*\"\n },\n {\n \"type\": \"temporary\",\n \"reason\": \"UncaughtException\",\n \"pattern\": \"Process \\\\d+ \\\\(\\\\S+\\\\) of user \\\\d+ encountered an uncaught \\\\S+ exception\"\n },\n {\n \"type\": \"temporary\",\n \"reason\": \"XorgCrash\",\n \"pattern\": \"Display server \\\\S+ crash in \\\\S+\"\n },\n {\n \"type\": \"temporary\",\n \"reason\": \"VMcore\",\n \"pattern\": \"System encountered a fatal error in \\\\S+\"\n },\n {\n \"type\": \"temporary\",\n \"reason\": \"Kerneloops\",\n \"pattern\": \"System encountered a non-fatal error in \\\\S+\"\n }\n ]\n }"
const DockerMonitor = "\n {\n \"plugin\": \"journald\",\n \"pluginConfig\": {\n \"source\": \"dockerd\"\n },\n \"logPath\": \"/var/log/journal\",\n \"lookback\": \"5m\",\n \"bufferSize\": 10,\n \"source\": \"docker-monitor\",\n \"conditions\": [],\n \"rules\": [\n {\n \"type\": \"temporary\",\n \"reason\": \"CorruptDockerImage\",\n \"pattern\": \"Error trying v2 registry: failed to register layer: rename {{ docker_storage_dir }}/image/(.+) {{ docker_storage_dir }}/image/(.+): directory not empty.*\"\n }\n ]\n }"
const KernelMonitor = " \n {\n \"plugin\": \"kmsg\",\n \"logPath\": \"/dev/kmsg\",\n \"lookback\": \"5m\",\n \"bufferSize\": 10,\n \"source\": \"kernel-monitor\",\n \"conditions\": [\n {\n \"type\": \"KernelDeadlock\",\n \"reason\": \"KernelHasNoDeadlock\",\n \"message\": \"kernel has no deadlock\"\n },\n {\n \"type\": \"ReadonlyFilesystem\",\n \"reason\": \"FilesystemIsNotReadOnly\",\n \"message\": \"Filesystem is not read-only\"\n }\n ],\n \"rules\": [\n {\n \"type\": \"temporary\",\n \"reason\": \"OOMKilling\",\n \"pattern\": \"Kill process \\\\d+ (.+) score \\\\d+ or sacrifice child\\\\nKilled process \\\\d+ (.+) total-vm:\\\\d+kB, anon-rss:\\\\d+kB, file-rss:\\\\d+kB.*\"\n },\n {\n \"type\": \"temporary\",\n \"reason\": \"TaskHung\",\n \"pattern\": \"task \\\\S+:\\\\w+ blocked for more than \\\\w+ seconds\\\\.\"\n },\n {\n \"type\": \"temporary\",\n \"reason\": \"UnregisterNetDevice\",\n \"pattern\": \"unregister_netdevice: waiting for \\\\w+ to become free. Usage count = \\\\d+\"\n },\n {\n \"type\": \"temporary\",\n \"reason\": \"KernelOops\",\n \"pattern\": \"BUG: unable to handle kernel NULL pointer dereference at .*\"\n },\n {\n \"type\": \"temporary\",\n \"reason\": \"KernelOops\",\n \"pattern\": \"divide error: 0000 \\\\[#\\\\d+\\\\] SMP\"\n },\n {\n \"type\": \"permanent\",\n \"condition\": \"KernelDeadlock\",\n \"reason\": \"AUFSUmountHung\",\n \"pattern\": \"task umount\\\\.aufs:\\\\w+ blocked for more than \\\\w+ seconds\\\\.\"\n },\n {\n \"type\": \"permanent\",\n \"condition\": \"KernelDeadlock\",\n \"reason\": \"DockerHung\",\n \"pattern\": \"task docker:\\\\w+ blocked for more than \\\\w+ seconds\\\\.\"\n },\n {\n \"type\": \"permanent\",\n \"condition\": \"ReadonlyFilesystem\",\n \"reason\": \"FilesystemIsReadOnly\",\n \"pattern\": \"Remounting filesystem read-only\"\n }\n ]\n }"
const SystemdMonitor = "\n {\n \"plugin\": \"journald\",\n \"pluginConfig\": {\n \"source\": \"systemd\"\n },\n \"logPath\": \"/var/log/journal\",\n \"lookback\": \"5m\",\n \"bufferSize\": 10,\n \"source\": \"systemd-monitor\",\n \"metricsReporting\": true,\n \"conditions\": [],\n \"rules\": [\n {\n \"type\": \"temporary\",\n \"reason\": \"KubeletStart\",\n \"pattern\": \"Started Kubernetes kubelet.\"\n },\n {\n \"type\": \"temporary\",\n \"reason\": \"DockerStart\",\n \"pattern\": \"Starting Docker Application Container Engine...\"\n },\n {\n \"type\": \"temporary\",\n \"reason\": \"ContainerdStart\",\n \"pattern\": \"Starting containerd container runtime...\"\n }\n ]\n }"