Rohit Jnagal
33c2cac71d
Compute smoothed cpu load for containers.
2015-01-27 20:21:53 +00:00
Rohit Jnagal
67af1a1bbd
Add scheddebug based cpuload reader.
...
Prefer netlink based reader when available as it provides stats for
processes in state other than running (sleep, diskio, uninterruptible).
2015-01-26 18:46:29 +00:00
Rohit Jnagal
1375f451b2
Refactor netlink implementation.
...
This allows us to plug in a scheddebug based interface.
2015-01-23 23:07:50 +00:00
Victor Marmol
909fa133e1
Merge pull request #445 from rjnagal/docker
...
Add task load stats to containers.
2015-01-16 16:00:50 -08:00
Rohit Jnagal
cbdd96a554
Add task load stats to containers.
...
The stats are only populated when cAdvisor is running outside network namespaces.
We'll add a different backend to retrieve the same data from within namespaces.
2015-01-16 23:25:22 +00:00
Vish Kannan
308f03f9b9
Merge pull request #440 from rjnagal/docker
...
Remove duplicate assignment.
2015-01-14 16:07:27 -08:00
Rohit Jnagal
bcd46d13cd
Remove duplicate assignment.
2015-01-14 23:30:47 +00:00
Rohit Jnagal
ed155019ac
Verify and fix error message nit :)
2015-01-14 01:15:13 +00:00
Victor Marmol
62b8382921
Handle initial zero value of lastError.
...
Also reduce logging to once every minute.
2015-01-08 10:31:32 -08:00
Vish Kannan
64f42cf686
Merge pull request #415 from rjnagal/diskinfo
...
Fix reading cache info for machines with unused packages.
2015-01-03 22:13:02 -08:00
Rohit Jnagal
1d26484681
Fix reading cache info for machines with unused packages.
...
Use thread ids instead of core-ids to identify caches.
2015-01-04 02:43:36 +00:00
Rohit Jnagal
aee5c36313
Fix vet errors
2015-01-01 22:41:55 +00:00
Rohit Jnagal
3836d1e2ec
Refactor common methods out of sysfs package and add tests.
2014-12-29 17:09:27 +00:00
Rohit Jnagal
496ee65cc2
Add ethernet devices information to machine endpoint.
2014-12-25 21:15:21 +00:00
Rohit Jnagal
b0462e3e94
Log one error message per hour for failing containers.
2014-12-23 00:49:48 +00:00
Rohit Jnagal
5994c17b1e
Add cache info to machine topology
2014-12-22 17:54:36 +00:00
Rohit Jnagal
8fa6389c64
Add per-node memory information to machine endpoint.
2014-12-21 01:37:13 +00:00
Rohit Jnagal
22cee3a89c
Add cpu topology information to machine endpoint.
2014-12-20 00:53:48 +00:00
Rohit Jnagal
c37f3865d9
Add cpu frequency to machine info.
2014-12-18 18:05:09 +00:00
Katie Knister
cd8a7923ae
Caches container info for 5 seconds before updating it
2014-12-16 17:32:01 -08:00
Rohit Jnagal
e5200948f5
Add a disk map to machine info.
...
This is read once at start of cAdvisor. We can use this to report
machine state as well as return logical name for block devices in UI.
Signed-off-by: Rohit Jnagal <jnagal@google.com> (github: rjnagal)
2014-12-17 00:15:50 +00:00
Victor Marmol
e3ab15417c
Ignore update errors for dead containers.
...
This adds an Exists() interface to detect when the container is dead.
Before reporting an update error we check is Exists() is true.
Some documentation was added as well.
2014-11-22 05:31:11 +08:00
Victor Marmol
4b9861246f
Remove unused code.
2014-11-20 15:22:47 +08:00
Victor Marmol
181e12dda2
Refactoring and fixes of /docker API endpoint.
...
This canges the output of the Docker endpoint to be a map so that it is
more consistent from single to multiple returns. It also refactors
internally how we handle both types of requests.
Without this PR the /docker API endpoint is broken completely so this
change in format has no effect anyways.
These changes are tested by the upcoming integration tests.
2014-11-19 03:36:18 -08:00
Victor Marmol
742bb8c724
Do not duplicate Docker container output.
...
Since Docker containers are known by more than one name we were
returning them once for every name they're known by. This change makes
the returned containers unique.
2014-11-17 10:40:28 -08:00
Victor Marmol
f97e57df88
Simplify how the Docker containers are handled.
...
This is done by introducting the concept of "namespaces" of container
names. The aliases of a container are under this namespace. Namespace
names are of the form:
//<namespace>/<alias>
This allows us to (within cAdvisor) query all docker containers as
//docker regardless of whether this is a systemd or a non-systemd system.
This does break our ability to handle Docker aliases with the /container
endpoint. I think this is acceptable as our support there was not
consistent between system types.
2014-11-12 18:01:47 -08:00
Vish Kannan
26921c3643
Merge pull request #277 from vmarmol/flat
...
Flatten ContainerStats struct
2014-11-05 11:26:10 -08:00
Victor Marmol
cb80366c6d
Fix logic for deciding if Docker container was not found.
...
This is currently broken for all searches of Docker containers.
2014-10-29 13:32:14 -07:00
Victor Marmol
8aa05b0c39
Add API version v1.2 with /docker endpoint.
...
The /docker endpoint lists all Docker containers under one unified
namespace.
2014-10-20 22:24:01 -07:00
Victor Marmol
add5147769
Flatten ContainerStats struct
2014-10-20 11:17:20 -07:00
Victor Marmol
5e7b1bb6ef
Merge pull request #269 from vmarmol/self-monitor
...
Adding --log_cadvisor_usage flag to log the resource usage of cAdvisor.
2014-10-15 17:21:45 +02:00
Victor Marmol
62b37eca1d
Adding --log_cadvisor_usage flag to log the resource usage of cAdvisor.
...
This helps during performance analysis.
2014-10-15 08:18:38 -07:00
Vishnu Kannan
5e8fecea6a
Adding filesystem usage calculation for docker containers. This patch also includes some internal refactoring.
...
'machine' api now exports a list of all existing 'ext*' filesystems along with the capacity.
2014-10-06 09:51:32 +00:00
Satnam Singh
833feae28b
Fix assignment error in haste.
2014-09-24 11:07:48 -07:00
Satnam Singh
f3c92c381a
More if undos.
2014-09-24 11:07:48 -07:00
Satnam Singh
1bdbb73c0e
And a few more capatalization undos.
2014-09-24 11:07:48 -07:00
Satnam Singh
3f45b35768
Undo changed to Errorf in manager.go re: capatalization.
2014-09-24 10:59:18 -07:00
Satnam Singh
8551d376d8
Undo changes to if statements as requested by vmarmol. Fix typos in my changes.
2014-09-24 10:59:18 -07:00
Satnam Singh
bae82a583d
A few minor Go style suggestions.
2014-09-24 10:53:52 -07:00
Victor Marmol
6f35cf8e6c
Supporting graceful signal shutdown.
...
Adding a signal handler and gracefully shutting down all threads.
2014-09-23 14:13:58 -07:00
Vish Kannan
195772a1bc
Merge pull request #245 from vmarmol/tests
...
Refactor and dependency inject containerData deps
2014-09-22 10:39:55 -07:00
Victor Marmol
e759059a09
Refactor and dependency inject containerData deps
2014-09-22 10:20:54 -07:00
Victor Marmol
e22831f1bd
Flatten ContainerSpec.
2014-09-19 10:14:22 -07:00
Victor Marmol
b63d61ca97
Use inotify to watch for new containers.
...
This reduces cAdvisor CPU usage below 1% in my CoreOS system.
We also reduce global housekeeping to every 60s as a fallback in case we
miss an event.
2014-09-18 12:52:09 -07:00
Vish Kannan
58e019028d
Merge pull request #235 from vmarmol/rm
...
Remove remaining parts of samples and percentiles.
2014-09-17 12:53:34 -07:00
Victor Marmol
621bb22eeb
Make dynamic housekeeping flag configurable
2014-09-16 11:04:45 -07:00
Victor Marmol
9dd8621686
Remove remaining parts of samples and percentiles.
2014-09-15 14:38:51 -07:00
Rohit Jnagal
e4b28d9d78
Merge pull request #233 from vmarmol/master
...
Removing sampling and percentiles from interface.
2014-09-15 14:20:25 -07:00
Victor Marmol
42add2409a
Removing sampling and percentiles from interface.
...
Also removing all implementations.
2014-09-15 14:13:07 -07:00
Victor Marmol
4e028d7995
Make housekeeping interval dynamic, fist signal is resource usage.
...
If no resources are used by the container since the last housekeeping,
we double the housekeeping interval until --max_housekeeping_interval.
If usage was detected, we drop it back to the baseline
(--housekeeping_interval).
From my tests this reduces CPU usage in CoreOS from ~8% to ~3% with no
real loss of accuracy.
Fixes #159
2014-09-10 15:01:54 -07:00