<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Saurav kumar &#8211; Best DevOps</title>
	<atom:link href="https://www.bestdevops.com/author/saurav-kumar/feed/" rel="self" type="application/rss+xml" />
	<link>https://www.bestdevops.com</link>
	<description>Lets Learn, Do it &#38; Share! Thats a Best DevOps!!!</description>
	<lastBuildDate>Tue, 17 Aug 2021 07:33:32 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=7.1.3</generator>
	<item>
		<title>Define a docker image in 10 bullets points</title>
		<link>https://www.bestdevops.com/define-a-docker-image-in-10-bullets-points-2/</link>
		
		<dc:creator><![CDATA[Saurav kumar]]></dc:creator>
		<pubDate>Tue, 17 Aug 2021 07:33:30 +0000</pubDate>
				<category><![CDATA[DevOps]]></category>
		<guid isPermaLink="false">https://www.bestdevops.com/?p=19342</guid>

					<description><![CDATA[Docker image is a collection of filesystems. Each image has a unique UUID assigned via sha-256 algorithm.Each image and a [&#8230;]]]></description>
										<content:encoded><![CDATA[
<p class="wp-block-paragraph">Docker image is a collection of filesystems. Each image has a unique UUID assigned via sha-256 algorithm.<br>Each image and a container has storage device assocaited with it.<br>Each file system represents a layer in the image.<br>The base layer for any image is the rootFS.<br>Every layer comes bundled with it&#8217;s parent layer.<br>All the layers of an image are read only.<br>At the time of container start, a merged layer is created including all the layers of corresponding image and made writable for custimization. Any change to this merged layer, doesn&#8217;t affect the actual image layers.<br>A container is one mounted instance of an image. As many containers from an image will be created, that many merged layers will be created for each container with a unique UUID.<br>The top layer has the highest precedence i.e. in case of duplicate files in multiple layers, the topmost layers file will be final output in the merged layer.<br>The default base directory for docker images and containers is /var/lib/docker.<br>When a container is stopped or killed, the corresponding merged layer will be cleaned from /var/lib/docker folder.</p>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>Assignment Day-2 Answer</title>
		<link>https://www.bestdevops.com/assignment-day-2-answer/</link>
		
		<dc:creator><![CDATA[Saurav kumar]]></dc:creator>
		<pubDate>Tue, 17 Aug 2021 05:33:48 +0000</pubDate>
				<category><![CDATA[DevOps]]></category>
		<guid isPermaLink="false">https://www.bestdevops.com/?p=19275</guid>

					<description><![CDATA[Docker Update command Docker update command is used to change the configurations of one or more docker container dynamically. [root@ip-172-31-7-40 [&#8230;]]]></description>
										<content:encoded><![CDATA[
<h2 class="wp-block-heading">Docker Update command</h2>



<p class="wp-block-paragraph">Docker update command is used to change the configurations of one or more docker container dynamically.</p>



<p class="wp-block-paragraph">[root@ip-172-31-7-40 centos]# docker ps -a<br>CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES<br>15c695103fd0 jenkins/jenkins &#8220;/sbin/tini &#8212; /usr/…&#8221; 19 hours ago Exited (137) 7 minutes ago sharp_albattani<br>e91a38a225ad ubuntu &#8220;bash&#8221; 20 hours ago Up 16 minutes practical_shirley<br>[root@ip-172-31-7-40 centos]#<br>[root@ip-172-31-7-40 centos]# docker inspect 15c695103fd0 | grep -i cpu<br>&#8220;CpuShares&#8221;: 100,<br>&#8220;NanoCpus&#8221;: 1000000000,<br>&#8220;CpuPeriod&#8221;: 0,<br>&#8220;CpuQuota&#8221;: 0,<br>&#8220;CpuRealtimePeriod&#8221;: 0,<br>&#8220;CpuRealtimeRuntime&#8221;: 0,<br>&#8220;CpusetCpus&#8221;: &#8220;&#8221;,<br>&#8220;CpusetMems&#8221;: &#8220;&#8221;,<br>&#8220;CpuCount&#8221;: 0,<br>&#8220;CpuPercent&#8221;: 0,<br>[root@ip-172-31-7-40 centos]#</p>



<p class="wp-block-paragraph">The current CpuShares value for this container is 100. Will update the same using docker update command as below to 10.</p>



<p class="wp-block-paragraph">[root@ip-172-31-7-40 centos]# docker update -c 10 15c695103fd0<br>15c695103fd0<br>[root@ip-172-31-7-40 centos]# docker inspect 15c695103fd0 | grep -i cpu<br>&#8220;CpuShares&#8221;: 10,<br>&#8220;NanoCpus&#8221;: 1000000000,<br>&#8220;CpuPeriod&#8221;: 0,<br>&#8220;CpuQuota&#8221;: 0,<br>&#8220;CpuRealtimePeriod&#8221;: 0,<br>&#8220;CpuRealtimeRuntime&#8221;: 0,<br>&#8220;CpusetCpus&#8221;: &#8220;&#8221;,<br>&#8220;CpusetMems&#8221;: &#8220;&#8221;,<br>&#8220;CpuCount&#8221;: 0,<br>&#8220;CpuPercent&#8221;: 0,<br>[root@ip-172-31-7-40 centos]#</p>



<p class="wp-block-paragraph">Below we will update the pids limit that maximum number of pids we can start in this container.</p>



<p class="wp-block-paragraph">[root@ip-172-31-7-40 centos]# docker inspect e91a38a225ad| grep -i pid<br>&#8220;Pid&#8221;: 2176,<br>&#8220;PidMode&#8221;: &#8220;&#8221;,<br>&#8220;PidsLimit&#8221;: 1,<br>[root@ip-172-31-7-40 centos]# docker update &#8211;pids-limit 25 e91a38a225ad<br>e91a38a225ad<br>[root@ip-172-31-7-40 centos]#<br>[root@ip-172-31-7-40 centos]# docker inspect e91a38a225ad| grep -i pid<br>&#8220;Pid&#8221;: 2176,<br>&#8220;PidMode&#8221;: &#8220;&#8221;,<br>&#8220;PidsLimit&#8221;: 25,<br>[root@ip-172-31-7-40 centos]#</p>



<h2 class="wp-block-heading">Docker WAIT command</h2>



<p class="wp-block-paragraph">Docker wait command is used to block untill one or more containers stop and return with the exit code.</p>



<p class="wp-block-paragraph">Open 2 terminals. Execute docker wait command in 1 terminal with the docker id and it will block. Run docker stop command in other terminal and the waiting terminal should unblock with the exit code.</p>



<p class="wp-block-paragraph">[root@ip-172-31-7-40 centos]# docker ps -a<br>CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES<br>15c695103fd0 jenkins/jenkins &#8220;/sbin/tini &#8212; /usr/…&#8221; 20 hours ago Up 5 seconds 8080/tcp, 50000/tcp sharp_albattani<br>e91a38a225ad ubuntu &#8220;bash&#8221; 20 hours ago Up 2 seconds practical_shirley<br>[root@ip-172-31-7-40 centos]#<br>[root@ip-172-31-7-40 centos]# docker stop 15c695103fd0<br>15c695103fd0<br>[root@ip-172-31-7-40 centos]#</p>



<p class="wp-block-paragraph">[root@ip-172-31-7-40 centos]#<br>[root@ip-172-31-7-40 centos]# docker wait 15c695103fd0<br>143<br>[root@ip-172-31-7-40 centos]#</p>



<p class="wp-block-paragraph">[root@ip-172-31-7-40 centos]# docker wait e91a38a225ad<br>137<br>[root@ip-172-31-7-40 centos]#<br>[root@ip-172-31-7-40 centos]# docker kill e91a38a225ad<br>e91a38a225ad<br>[root@ip-172-31-7-40 centos]#</p>



<p class="wp-block-paragraph">If a docker container is already stopped or killed, the wait command will return immediately with the error code without blocking. Also, if the container is just paused, wait command won&#8217;t come out of block state. Wait command only works if the container is stopped and not on only pause.</p>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>Answer for Assignment &#8211; Day 1</title>
		<link>https://www.bestdevops.com/answer-for-assignment-day-1/</link>
		
		<dc:creator><![CDATA[Saurav kumar]]></dc:creator>
		<pubDate>Mon, 16 Aug 2021 10:52:07 +0000</pubDate>
				<category><![CDATA[DevOps]]></category>
		<guid isPermaLink="false">https://www.bestdevops.com/?p=19182</guid>

					<description><![CDATA[What is the diff between docker pause and docker unpause? Docker pause command is used to move the processes running [&#8230;]]]></description>
										<content:encoded><![CDATA[
<h2 class="wp-block-heading">What is the diff between docker pause and docker unpause?</h2>



<p class="wp-block-paragraph">Docker pause command is used to move the processes running within the container to paused state by sending a signal SIGSTOP and then the docker unpause command can be used to bring back the processes to running state.</p>



<h2 class="wp-block-heading">What is the diff between docker stop and docker kill?</h2>



<p class="wp-block-paragraph">Docker stop command is used to stop all the running processes within the container by sending a SIGTERM signal which can be handled using signal handlers within the process to do any kind of cleanup activities. While docker kill command kills all the processes within a container through SIGKILL command.</p>
]]></content:encoded>
					
		
		
			</item>
	</channel>
</rss>
