The Internet of Things has the potential to disrupt all industries, not just consumer, as businesses leverage the new insights and capabilities enabled by new devices / things, automation, integration and analytics, etc., to transform how they do business.
One industry ripe for disruption is higher education. Colleges and universities are being challenged with serving more students and at the same time ensuring successful student outcomes.
In his session at @ThingsExpo, Chris Witeck, Principa...| By Sematext Blog | Article Rating: |
|
| January 26, 2016 08:45 PM EST | Reads: |
296 |
Docker Swarm: Collecting Metrics, Events and Logs
By Stefan Thies
Docker Swarm is a cluster manager for Docker. When accessed via the Docker API by Docker API Clients or Docker command line tools, a Docker Swarm cluster looks just like a single Docker Host. Docker Swarm distributes containers to multiple nodes using various deployment strategies in the cluster scheduler.
Having in mind that a Swarm cluster looks like a single Docker Host from the API point of view, it should be very easy to monitor Docker Swarm with existing Docker monitoring tools! Connecting a monitoring agent to the Swarm Master API endpoint should do the job, right? The Sematext Docker Agent could simply collect all container metrics, events and all logs from the Swarm Master - should be a piece of cake. Hmm, but could there a gotcha? It turns out there is more than one:
- If we deploy a single monitoring agent to the master node, it would miss host metrics for all other nodes because the Docker API doesn't provide any host metrics. We could also not see how much memory, disk space or CPU the Docker Swarm node itself consumes. Solution: deploy the monitoring agents to each node for collecting the metrics locally.
- Assuming a larger cluster with a high volume of logs, events and metrics to collect, a single monitoring agent connected to the the master node would need to handle all operational data of the cluster. This would work for a small cluster but such an architecture would obviously be destined for failure on larger clusters. Guess what the solution is? It's much better having an agent running on each node and distributing the monitoring and logging work over all nodes. If you do it right from the beginning, there is no need to change the deployment strategy later, when the cluster scales out.

Monitoring container running on each Docker node
In the following example we assume that the master and agent nodes have the UNIX socket enabled in Docker daemon settings. This can be achieved by using -engine-env ‘DOCKER_OPTS="-H unix:///var/run/docker.sock"‘ in the docker-machine create command. Use this Github Gist to create a Docker-Swarm Cluster with with enabled UNIX sockets. Later, we will see this helps simplify the deployment of any tool that needs to connect to the local Docker daemon - including monitoring and logging containers.
Let's see how to deploy Sematext Agent to each node in a Docker Swarm Cluster with UNIX socket enabled in Docker-Daemon as just described.
When we started to work on Swarm Monitoring our first question was "Does Docker Swarm provide a deployment strategy for running exactly one instance of a service on each node?" We checked the documentation, but no dice. We found strategies like "spread, binpack, and random" (see https://docs.docker.com/swarm/scheduler/strategy/), but none of them would guarantee exactly one instance of a service on each node. The "spread" strategy spreads the containers evenly over all hosts. The "binpack" strategy fills up one node after another with containers, while "random" spreads containers randomly to nodes. There was seemingly no strategy suitable for monitoring services running only once on each node.
So how can we distribute the monitoring container to each host using Docker Swarm instead of bash script iterating over all nodes? It turns out it's possible to define an affinity to ensure that containers that should run on the same host are scheduled together. In our case we use "anti-affinity" in the deployment strategy, which instructs Swarm not to deploy the container with Sematext Agent to hosts that already have that container running. In other words, it tells Docker Swarm to run no more than one Sematext Agent container on each Docker host. To do that we define a docker-compose.yml file with the "anti-affinity" specified in the container environment section:
sematext-agent:
image: 'sematext/sematext-agent-docker:latest' environment:
- LOGSENE_TOKEN=3b549a2c-653a-4832-xxx
- SPM_TOKEN=fe31fc3a-4660-47c6-xxx
- affinity:container!=sematext-agent*
privileged: true
restart: always
volumes:
- '/var/run/docker.sock:/var/run/docker.sock'
Finally, we use the docker-compose command to scale out the Sematext Docker Agent and deploy it to all Swarm cluster nodes. To do that we run:
eval $(docker-machine env swarm-master --swarm)
docker-compose up -d
# scale is == num nodes
docker-compose scale sematext-agent=$(docker-machine ls | grep swarm | grep Running | wc -l)
After running the above commands, Sematext Docker Agent will be running on each node and within a minute you will receive Host and Container Metrics for all containers, all their Logs and all Docker events from all nodes in your Docker Swarm cluster. Complete visibility!

Aggregated Metrics from all Docker Swarm nodes
Please note there are many ways to create a Swarm cluster and you might have another setup, such as:
- TLS secured Docker daemon and no possibility to activate the unix socket: In this situation you have to deal with the existing Docker daemon setup, which typically uses TLS and authentication via certificates (for example, if you followed Docker's instructions to create Swarm clusters using Docker-Machine). When the Docker socket is secured with TLS, each client - including Sematext Docker Agent - needs the certificates for authentication. This involves a bunch of parameters such as "DOCKER_HOST", "DOCKER_CERT_PATH", "DOCKER_TLS_VERIFY" and mounting of the certificate into the container. In addition we should know to which Docker daemon the agent should be connected (typically port 2375 for TCP, 2376 for TLS on each node and port 3376 on Swarm Master nodes for the Swarm API). We made this scenario easy with a deployment script for the Sematext Agent with TLS options provided by Docker-Machine.
- You use CoreOS to run Docker Swarm: In this case you could use fleet and systemd to distribute the agent to each node (simply install Sematext Agent with these instructions)
The deployment methods above should work for other monitoring tools or logging containers as well because most of such tools need to run on each node to collect the metrics locally.
If you have questions or special needs for monitoring more complex setups feel free to contact us. The Sematext Docker Agent is a turnkey-solution for Docker Logs, Metrics and Events - sign up here and give it a try (30-days free trial, no credit card needed).
Filed under: Logging, Monitoring Tagged: Containers, devops, docker, docker swarm, log management, logging, performance monitoring
Published January 26, 2016 Reads 296
Copyright © 2016 SYS-CON Media, Inc. — All Rights Reserved.
Syndicated stories and blog feeds, all rights reserved by the author.
More Stories By Sematext Blog
Sematext is a globally distributed organization that builds innovative Cloud and On Premises solutions for performance monitoring, alerting and anomaly detection (SPM), log management and analytics (Logsene), and search analytics (SSA). We also provide Search and Big Data consulting services and offer 24/7 production support for Solr and Elasticsearch.
The Internet of Things has the potential to disrupt all industries, not just consumer, as businesses leverage the new insights and capabilities enabled by new devices / things, automation, integration and analytics, etc., to transform how they do business.
One industry ripe for disruption is higher education. Colleges and universities are being challenged with serving more students and at the same time ensuring successful student outcomes.
In his session at @ThingsExpo, Chris Witeck, Principa...Jan. 27, 2016 02:15 AM EST Reads: 829 |
By Elizabeth White Most people haven’t heard the word, “gamification,” even though they probably, and perhaps unwittingly, participate in it every day.
Gamification is “the process of adding games or game-like elements to something (as a task) so as to encourage participation.” Further, gamification is about bringing game mechanics – rules, constructs, processes, and methods – into the real world in an effort to engage people.
In his session at @ThingsExpo, Robert Endo, owner and engagement manager of Intrepid D...Jan. 26, 2016 10:45 PM EST Reads: 482 |
By Elizabeth White When it comes to IoT in the enterprise, namely the commercial building and hospitality markets, a benefit not getting the attention it deserves is energy efficiency, and IoT’s direct impact on a cleaner, greener environment when installed in smart buildings. Until now clean technology was offered piecemeal and led with point solutions that require significant systems integration to orchestrate and deploy. There didn't exist a 'top down' approach that can manage and monitor the way a Smart Buildi...Jan. 26, 2016 09:45 PM EST Reads: 1,002 |
By Elizabeth White Jan. 26, 2016 04:45 PM EST Reads: 521 |
By Pat Romanski Jan. 26, 2016 04:45 PM EST Reads: 393 |
By Elizabeth White As the Internet of Things becomes more capable, moving from an initial ad hoc bundle of chaos to an optimized set of interconnected assets, we will need to ensure it performs and is reliable.
But this means the tools measuring the performance and reliability of the IoT will also need to mature as the need for timely, understandable, quality, business-critical information becomes paramount. Sensors that are malfunctioning, devices that are offline, data that’s little more than noise can all scut...Jan. 26, 2016 03:15 PM EST Reads: 536 |
By Elizabeth White For manufacturers, the Internet of Things (IoT) represents a jumping-off point for innovation, jobs, and revenue creation. But to adequately seize the opportunity, manufacturers must design devices that are interconnected, can continually sense their environment and process huge amounts of data.
As a first step, manufacturers must embrace a new product development ecosystem in order to support these products. Jan. 26, 2016 03:00 PM EST Reads: 565 |
By Liz McMillan WebRTC has had a real tough three or four years, and so have those working with it. Only a few short years ago, the development world were excited about WebRTC and proclaiming how awesome it was.
You might have played with the technology a couple of years ago, only to find the extra infrastructure requirements were painful to implement and poorly documented. This probably left a bitter taste in your mouth, especially when things went wrong.Jan. 26, 2016 02:30 PM EST Reads: 614 |
By Elizabeth White SYS-CON Events announced today that Fusion, a leading provider of cloud services, will exhibit at SYS-CON's 18th International Cloud Expo®, which will take place on June 7-9, 2016, at the Javits Center in New York City, NY.
Fusion, a leading provider of integrated cloud solutions to small, medium and large businesses, is the industry's single source for the cloud. Fusion's advanced, proprietary cloud service platform enables the integration of leading edge solutions in the cloud, including clou...Jan. 26, 2016 01:45 PM EST Reads: 496 |
By Elizabeth White Jan. 26, 2016 01:15 PM EST Reads: 310 |
By Elizabeth White Contextual Analytics of various threat data provides a deeper understanding of a given threat and enables identification of unknown threat vectors.
In his session at @ThingsExpo, David Dufour, Head of Security Architecture, IoT, Webroot, Inc., discussed how through the use of Big Data analytics and deep data correlation across different threat types, it is possible to gain a better understanding of where, how and to what level of danger a malicious actor poses to an organization, and to determ...Jan. 26, 2016 01:15 PM EST Reads: 1,036 |
By Elizabeth White Jan. 26, 2016 01:15 PM EST Reads: 549 |
By Elizabeth White The Internet of Things is in the early stages of mainstream deployment but it promises to unlock value and rapidly transform how organizations manage, operationalize, and monetize their assets. IoT is a complex structure of hardware, sensors, applications, analytics and devices that need to be able to communicate geographically and across all functions. Once the data is collected from numerous endpoints, the challenge then becomes converting it into actionable insight.Jan. 26, 2016 01:00 PM EST Reads: 658 |
By Liz McMillan Jan. 26, 2016 01:00 PM EST Reads: 280 |
By Elizabeth White Jan. 26, 2016 01:00 PM EST Reads: 564 |
By Elizabeth White Jan. 26, 2016 12:00 PM EST Reads: 315 |
By Liz McMillan SYS-CON Events announced today that Interface Masters Technologies, a leading vendor in the network monitoring and high speed networking markets, will exhibit at the 18th International CloudExpo®, which will take place on June 7-9, 2016, at the Javits Center in New York City, New York, and the 19th International Cloud Expo, which will take place on November 1–3, 2016, at the Santa Clara Convention Center in Santa Clara, CA.Jan. 26, 2016 12:00 PM EST Reads: 579 |
By Pat Romanski Jan. 26, 2016 11:30 AM EST Reads: 278 |
By Pat Romanski The IoT's basic concept of collecting data from as many sources possible to drive better decision making, create process innovation and realize additional revenue has been in use at large enterprises with deep pockets for decades. So what has changed?
In his session at @ThingsExpo, Prasanna Sivaramakrishnan, Solutions Architect at Red Hat, discussed the impact commodity hardware, ubiquitous connectivity, and innovations in open source software are having on the connected universe of people, thi...Jan. 26, 2016 11:00 AM EST Reads: 515 |
By Pat Romanski Jan. 26, 2016 10:00 AM EST Reads: 274 |

Most people haven’t heard the word, “gamification,” even though they probably, and perhaps unwittingly, participate in it every day.
Gamification is “the process of adding games or game-like elements to something (as a task) so as to encourage participation.” Further, gamification is about bringing game mechanics – rules, constructs, processes, and methods – into the real world in an effort to engage people.
In his session at @ThingsExpo, Robert Endo, owner and engagement manager of Intrepid D...
When it comes to IoT in the enterprise, namely the commercial building and hospitality markets, a benefit not getting the attention it deserves is energy efficiency, and IoT’s direct impact on a cleaner, greener environment when installed in smart buildings. Until now clean technology was offered piecemeal and led with point solutions that require significant systems integration to orchestrate and deploy. There didn't exist a 'top down' approach that can manage and monitor the way a Smart Buildi...
As the Internet of Things becomes more capable, moving from an initial ad hoc bundle of chaos to an optimized set of interconnected assets, we will need to ensure it performs and is reliable.
But this means the tools measuring the performance and reliability of the IoT will also need to mature as the need for timely, understandable, quality, business-critical information becomes paramount. Sensors that are malfunctioning, devices that are offline, data that’s little more than noise can all scut...
For manufacturers, the Internet of Things (IoT) represents a jumping-off point for innovation, jobs, and revenue creation. But to adequately seize the opportunity, manufacturers must design devices that are interconnected, can continually sense their environment and process huge amounts of data.
As a first step, manufacturers must embrace a new product development ecosystem in order to support these products.
WebRTC has had a real tough three or four years, and so have those working with it. Only a few short years ago, the development world were excited about WebRTC and proclaiming how awesome it was.
You might have played with the technology a couple of years ago, only to find the extra infrastructure requirements were painful to implement and poorly documented. This probably left a bitter taste in your mouth, especially when things went wrong.
SYS-CON Events announced today that Fusion, a leading provider of cloud services, will exhibit at SYS-CON's 18th International Cloud Expo®, which will take place on June 7-9, 2016, at the Javits Center in New York City, NY.
Fusion, a leading provider of integrated cloud solutions to small, medium and large businesses, is the industry's single source for the cloud. Fusion's advanced, proprietary cloud service platform enables the integration of leading edge solutions in the cloud, including clou...
Contextual Analytics of various threat data provides a deeper understanding of a given threat and enables identification of unknown threat vectors.
In his session at @ThingsExpo, David Dufour, Head of Security Architecture, IoT, Webroot, Inc., discussed how through the use of Big Data analytics and deep data correlation across different threat types, it is possible to gain a better understanding of where, how and to what level of danger a malicious actor poses to an organization, and to determ...
The Internet of Things is in the early stages of mainstream deployment but it promises to unlock value and rapidly transform how organizations manage, operationalize, and monetize their assets. IoT is a complex structure of hardware, sensors, applications, analytics and devices that need to be able to communicate geographically and across all functions. Once the data is collected from numerous endpoints, the challenge then becomes converting it into actionable insight.
SYS-CON Events announced today that Interface Masters Technologies, a leading vendor in the network monitoring and high speed networking markets, will exhibit at the 18th International CloudExpo®, which will take place on June 7-9, 2016, at the Javits Center in New York City, New York, and the 19th International Cloud Expo, which will take place on November 1–3, 2016, at the Santa Clara Convention Center in Santa Clara, CA.
The IoT's basic concept of collecting data from as many sources possible to drive better decision making, create process innovation and realize additional revenue has been in use at large enterprises with deep pockets for decades. So what has changed?
In his session at @ThingsExpo, Prasanna Sivaramakrishnan, Solutions Architect at Red Hat, discussed the impact commodity hardware, ubiquitous connectivity, and innovations in open source software are having on the connected universe of people, thi...
All eyes appeared to be on the Consumer Electronics Show (CES) 2016 in Las Vegas since last week, as more than 3,600 companies unveiled the IoT and IIoT innovations we can all expect to see in the coming year. This year's CES showcased plans to make the car a complete mobile office-with technology in place to allow Skype calls and the use of Microsoft 365 from the car. The other hot theme at CES was drones - not a surprise since these unmanned crafts have pulled us in like a tracker-beam to the mother ship. The autonomous ‘copter drone was one of the most impressive releases with the reality t...
Hello Barbie™! is an IoT-enabled (Internet of Things) Barbie Doll with blonde hair, blue eyes and a built-in surveillance system. She’s not the first of her kind (and she won’t be the last), but here’s what you should know about bringing it, or any connected device, into your home.
Everything that connects to the public Internet is vulnerable. Encryption does not solve the problem. While it is true that you need about 6.4 billion years to crack a 2048-bit PGP encrypted file, I can probably socially engineer you out of your encryption key by attaching a little piece of malware to an email that...
I often write about the Internet of Things, or the soon-to-be-cliché IoT. You know, the smart-fridges, smart-cars, smart-thermostats, healthcare devices, wearables and any of those connected devices that have a sensor, gathers data and reports back to some entity. You are able to control these devices (and see the data) with mobile apps or even your own voice and gestures. They are all the rage and sitting at the top of the Gartner Hype Cycle.
But it’s all the various sensors inside those devices that are doing the actual measuring, calculating, tracking and reporting. Each has its own spec...
Instead of writing yet another “Big Data Predictions for the Next Year” blog, I thought I’d do something a bit different. Instead of predicting – like everyone else – what’s going to happen in 2016, let’s instead look out a few years and see how data and analytics might transform our lives and the lives of those around us. Probably a silly exercise, but a fun way to wrap up 2015 nonetheless.
My wellness band actually woke me up about 15 minutes before my alarm because it had used data about my sleep patterns to determine that I was ready to get up (it automatically turns off my alarm so that...
Printed electronics are being touted as the next best thing in Internet of Things (IoT), the technology that is rightly regarded as a boon of advancing technology. Silicon-based sensors are the first that have been associated with IoT technology. These sensors have numerous applications, such as track data from airplane, wind turbines, engines, and medical devices, among other internet connected devices.
Digital transformation has increased the speed at which organizations must adapt. As they do so, it’s more important than ever to be able to choose solutions that will give them a comprehensive, real-time view of the network. Several factors contribute to this new priority:
Root causes and threats must be quickly identified, so network and security ops personnel must have the ability to view and share real-time data from multiple network environments.
IoT depends to a large part on the availability of custom hardware of sensors that can be efficiently manufactured with exacting tolerances in its specifications. Smart Parts manufacturing will be one of the key technologies required to address the IoT 3D Sensors and 3D Antennae.
Optomec which manfuactures production grade 3D printers can manufacture parts both in plastics and metals.
In the late 1990's Tom Standage released the first edition of a book that would sweep across the tech community because of its incredible analogies to the rise of the Internet hitting the world at that time. The "Victorian Internet", first released in 1998, was updated and re-released again in 2013. It provided a well written history and meaningful assessment of the rise of the Telegraph, and made very interesting observations about how the remarkable impact of the Telegraph could help us all think through what may happen as the Internet progressed.
It’s that time of year that I review everything that I’ve written over the past year and share my favorite blogs. As many of you know, I travel frequently and because I’ve continuously seen every airline movie, I have plenty of time to write. And according to the commentary, every now and then I have a good one. So here are my Top 10 Blogs from 2015!
Most of us can relate to the frustration of when the Wi-Fi is down, or running slowly, or if we travel away from an established network and aren't able to connect to another one nearby. The lack of Wi-Fi makes it impossible to check our emails, look up something on the internet, connect with others, or get our work done efficiently. In short, it makes us feel a little helpless and a whole lot of cranky because we've become way too accustomed to getting the information we want - when we want it - and staying in 24/7 connection with our world.
Shivon Zilis is an investor at Bloomberg Beta, a very interesting early stage venture capital fund. I knew I would like Bloomberg Beta when I saw how they do their website. It is smart and reflects very well on their leadership team: They decided to leverage GitHub for their site. Doing so puts them one step closer to the creators that a VC in their space needs to know and is a great way to step out in a trust-based relationship. It is also a great way to be more transparent- they use GitHub to provide their entire operating manual for all to see.
Fresh off the Vegas-style hypefest that is the Consumer Electronics Show, fitness wearables darling Fitbit is already in hot water. Numerous customers, furious at the inaccuracies of Fitbit’s devices, filed a national class-action lawsuit on January 5.
“Plaintiffs and many consumers like them have experienced—and testing confirms—that the [Fitbit] PurePulse Trackers consistently mis-record heart rates by a very significant margin, particularly during exercise,” the lawsuit alleges. “Far from ‘counting every beat,’ the PurePulse Trackers do not and cannot consistently and accurately record wea...

























