{"id":12765,"date":"2019-09-05T14:47:24","date_gmt":"2019-09-05T12:47:24","guid":{"rendered":"https:\/\/www.dbi-services.com\/blog\/debugging-sql-server-containers-considerations\/"},"modified":"2023-07-17T08:16:11","modified_gmt":"2023-07-17T06:16:11","slug":"debugging-sql-server-containers-considerations","status":"publish","type":"post","link":"https:\/\/www.dbi-services.com\/blog\/debugging-sql-server-containers-considerations\/","title":{"rendered":"Debugging SQL Server containers considerations"},"content":{"rendered":"<p>When it comes to troubleshooting processes or to get a deeper look of how SQL Server works internally , I always used debugging tools as windbg on Windows and since SQL Server is available on Linux, I switched to <a href=\"https:\/\/linux.die.net\/man\/1\/strace\" target=\"_blank\" rel=\"noopener noreferrer\">strace<\/a> tool.<\/p>\n<p>But let\u2019s add containers in the game now. I didn\u2019t want to touch any based image for applications including SQL Server with debugging tools added. So, my concern was to figure out how to debug a running Docker container from a separate container. Creating a custom image for only debugging tools including strace is not a hard task and after some quick google searches, it is easy to find blogs that explain the process.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone wp-image-34205 size-full\" src=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/blog-162-0-banner-e1567694673119.jpg\" alt=\"\" width=\"400\" height=\"295\" \/><\/p>\n<p>Here is my Docker file:<\/p>\n<pre class=\"brush: shell; gutter: true; first-line: 1\">FROM alpine\n\nENV CAPTUREMODE \"S\"<\/pre>\n<pre class=\"brush: shell; gutter: true; first-line: 1\">RUN apk update &amp;&amp; apk add strace\nCMD [\"sh\", \"-c\", \"<\/pre>\n<div style=\"color: #000000; line-height: 22px; font-family: Consolas, 'Courier New', monospace; font-size: 16px; font-weight: normal; background-color: #ffffff;\">\n<div>strace -t -f -p $(if [ $CAPTUREMODE == &#8216;Start&#8217; ]; then echo 1; else pgrep -P 1; fi)&#8221;]<\/div>\n<\/div>\n<p>I picked up the alpine based image for is low footprint and my custom image is designed to trace any running container. Note that I\u2019m using the -p parameter to attach to the concerning process and begin tracing. In the Docker file the PID environment variable is intended to target the process ID of the remote container process I want to look at. Obviously, this image may be improved by adding other parameters to implement specific filter rules for example, but this is not the focus of this write-up.<\/p>\n<p>As an aside, maybe you are wondering why I have implemented such variable because usually we trace the PID 1 within a container? (the magic of Docker entry point and Linux namespace)<\/p>\n<p><strong>(Update 06.09.2019 : Anthony E. Nocentino brought me to my attention a more elegant way to get dynamically the child processes of the PID 1. In fact it works well with a running container but not a starting container\u00a0 because pgrep will return child processes of the sleep command. I modified my Dockerfile above accordingly to provide a way to choose which mode you want to enter)<\/strong><\/p>\n<p>Well, referring to the Bob Dorr\u2019s <a href=\"https:\/\/blogs.msdn.microsoft.com\/bobsql\/2018\/07\/18\/sql-server-on-linux-why-do-i-have-two-sql-server-processes\/\" target=\"_blank\" rel=\"noopener noreferrer\">blog post<\/a> and applying it to the container world, good chances are the PID 1 doesn\u2019t belong to the SQL Server process itself but it is a lightweight monitor process for the SQL Server process (WATCHDOG).<\/p>\n<p>If I try to trace the PID 1 of a running SQL Server container, I get the following result with nothing relevant here \u2026<\/p>\n<pre class=\"brush: shell; gutter: true; first-line: 1\">strace: Process 1 attached with 2 threads\n[pid     1] 08:11:59 wait4(9,  &lt;unfinished ...&gt;\n[pid     8] 08:11:59 ppoll([{fd=15, events=POLLIN}], 1, NULL, NULL, 8<\/pre>\n<p>\u2026 hence the idea to implement the PID variable to provide the ability to pick up the right process to trace (by default the PID 1). Here an example of a Docker command to trace the sqlservr process inside my container:<\/p>\n<pre class=\"brush: bash; gutter: true; first-line: 1\">$ docker ps | grep sql\ne3aca69d5dff        mcr.microsoft.com\/mssql\/server:2019-latest   \"\/opt\/mssql\/bin\/perm\u2026\"   About an hour ago   Up About an hour    0.0.0.0:1401-&gt;1433\/tcp   sql1\n\n$ docker exec -ti sql1 top\n  PID USER      PR  NI    VIRT    RES    SHR S  %CPU %MEM     TIME+ COMMAND                                                 \n    9 root      20   0 12.337g 770160  58540 S   1.7 12.7   1:11.78 sqlservr\n    1 root      20   0  148520  23036  13376 S   0.0  0.4   0:00.62 sqlservr\n  325 root      20   0    1888    920    728 S   0.0  0.0   0:00.04 strace\n  376 root      20   0   38728   3184   2748 R   0.0  0.1   0:00.04 top\n\n$ docker run --name debug -t --pid=container:sql1 \\\n --net=container:sql1 \\\n --cap-add sys_admin \\\n --cap-add sys_ptrace \\\n strace | tee trace.txt<\/pre>\n<p>The PID 9 corresponds to the SQL Server process (not the WATCHDOG). Then I started my debug container which begun to trace a bunch of activities. The last docker command uses special parameters including \u2013pid, &#8211;net and &#8211;cap-add to run the debug container in the same pid and network namespace. Pretty cool!<\/p>\n<p>Here a trimmed sample of the trace.txt file during the creation of the test database:<\/p>\n<pre class=\"brush: shell; gutter: true; first-line: 1\">strace: Process 9 attached with 161 threads\n[pid   373] 08:21:49 restart_syscall(&lt;... resuming interrupted futex ...&gt; &lt;unfinished ...&gt;\n[pid   343] 08:21:49 futex(0x7f9835de2cc4, FUTEX_WAIT_PRIVATE, 5, NULL &lt;unfinished ...&gt;\n\u2026\n[pid   162] 08:26:05 open(\"\/var\/opt\/mssql\/data\/test.mdf\", O_RDWR|O_CREAT|O_EXCL|O_DIRECT, 0660 &lt;unfinished ...&gt;\n[pid    14] 08:26:05 clock_gettime(CLOCK_REALTIME, {tv_sec=1567671965, tv_nsec=625743500}) = 0\n\u2026\n[pid   162] 08:26:05 stat(\"\/var\/opt\/mssql\/data\/test.mdf\", {st_mode=S_IFREG|0640, st_size=0, ...}) = 0\n[pid    14] 08:26:05 clock_gettime(CLOCK_MONOTONIC,  &lt;unfinished ...&gt;\n\u2026<\/pre>\n<p>So, for a running container everything seems to work like a charm but what if I want to catch events for a starting container? . I get this opportunity to thank Anthony E. Nocentino (<a href=\"https:\/\/twitter.com\/nocentino\">@nocentino<\/a>) to make me indirectly want to write this blog post \ud83d\ude42 Anthony is\u00a0\u00a0a Microsoft Data Platform MVP who is doing incredible stuff around SQL Server containers with blogs and trainings. I would simply say just follow it :). At the first step, I got the same idea as him and he already explained very well the context of this tracing problem when SQL Server is starting and the way he found to fix it. Everything is in his <a href=\"http:\/\/www.centinosystems.com\/blog\/author\/aencentinosystems-com\/\">blog post<\/a> so there is no need to duplicate his work. The interesting point here is Anthony\u2019s final approach consists in creating a custom container with SQL Server and strace installed. That&#8217;s exactly at the opposite of what I want to achieve but it seemed to be the better alternative so far. To be honest, it remains a good and simple approach in any cases.<\/p>\n<p>But I kept motivated (thank again Anthony for that!), to find another solution I decided to continue exploring other alternatives based on my first requirements (a separate container) and I believe I found an interesting one. Just to refresh your mind, the problem here is to ensure catching all events since the startup of the SQL Server process but However running 2 containers in parallel \u2013 the SQL Server container and the debug container including strace tool \u2013 seems to be not a viable option and this is exactly what Anthony explained in the first attempt of tests section of his blog.<\/p>\n<p>If you start the debug container too early before the SQL Server container process has started the sqlservr process \u2026<\/p>\n<pre class=\"brush: bash; gutter: true; first-line: 1\">docker run --rm --name debug -t --pid=container:sql1 \\\n --net=container:sql1 \\\n --cap-add sys_admin \\\n --cap-add sys_ptrace \\\n strace &gt; trace.txt &amp; \\ docker run --name sql1 \\\n --env 'ACCEPT_EULA=Y' \\\n --env 'MSSQL_SA_PASSWORD=Password1' \\\n --volume \/t\/Docker\/DMK\/BACKUP\/test1:\/var\/opt\/mssql\/ \\\n --publish 1401:1433 \\\n --detach \\\n mcr.microsoft.com\/mssql\/server:2019-latest<\/pre>\n<p>\u2026 chances are you will face an error as show below:<\/p>\n<pre class=\"brush: shell; gutter: true; first-line: 1\">docker: Error response from daemon: No such container: sql1.<\/pre>\n<p>At the opposite, if you start the debug container too late (note the introduction of the sleep command) \u00a0\u2026<\/p>\n<pre class=\"brush: bash; gutter: true; first-line: 1\">$ docker run --name debug -t --pid=container:sql1 \\\n --net=container:sql1 \\\n --cap-add sys_admin \\\n --cap-add sys_ptrace \\\n strace &gt; trace.txt &amp; \\\n sleep .001 &amp;&amp; docker restart sql1\n\n[1] 1171\nsql1\n\n[1]  + 1171 exit 137   docker run --name debug -t --pid=container:sql1 --net=container:sql1 --cap-ad<\/pre>\n<p>\u2026 chances are you will miss some events. Here the beginning of the trace output:<\/p>\n<pre class=\"brush: shell; gutter: true; first-line: 1\">trace: Process 1 attached\n13:52:53 pread64(13, \"\\33\\n\\6-\\16\\2rx\\6\\2p\\3(\\237\\24\\0\\6\\24*~L\\16\\0\\n\\7\\6oQ\\16\\0\\n\\6\"..., 131072, 31195148) = 131072\n13:52:53 pread64(13, \"\\1\\0\\245\\20\\0\\0\\0\\0\\0\\0\\306\\r(i\\2\\0\\340\\1\\0\\0\\246\\20\\0\\0\\0\\0\\0\\0\\306\\rhi\"..., 131072, 31326220) = 131072\n13:52:53 pread64(13, \"\\301\\35\\2\\0b.\\0\\0\\344\\10\\362\\31\\2\\0i.\\0\\0\\364\\t\\260\\225\\1\\0\\205\\4\\0\\0l\\nIQ\"..., 131072, 31457292) = 131072<\/pre>\n<p>Referring to the above strace output, it is clear we didn\u2019t catch all the events from the startup of the sqlservr process with the following missing entry for example:<\/p>\n<pre class=\"brush: bash; gutter: true; first-line: 1\">execve(\"\/opt\/mssql\/bin\/sqlservr\", [\"\/opt\/mssql\/bin\/sqlservr\"]<\/pre>\n<p>In a nutshell, this is not a viable way of achieving what we want. My approach, based on keeping running separate containers, consists in overriding the default entry point in order to delay directly the call of the sqlservr binary during the container runtime.<\/p>\n<p>We may easily identify the Docker entry point by running the docker history command against the concerned SQL Server docker image as follow:<\/p>\n<pre class=\"brush: bash; gutter: true; first-line: 1\">$ docker history c5a295efea97 --no-trunc | grep ENTRYPOINT\n&lt;missing&gt;                                                                 2 weeks ago         \/bin\/sh -c #(nop)  ENTRYPOINT [\"\/opt\/mssql\/bin\/permissions_check.sh\"]<\/pre>\n<p>When the SQL Server container is spinning up the <em><strong>\/opt\/mssql\/bin\/permissions_check.sh<\/strong><\/em> is called. Without going into details here, this bash script executes at the final stage the CMD from the Dockerfile which the following is:<\/p>\n<pre class=\"brush: bash; gutter: true; first-line: 1\">$ docker history c5a295efea97 --no-trunc | grep CMD\nsha256:c5a295efea970743a71a330a1d314458272811e3524e1fc1245e6d6fe57aab90   2 weeks ago         \/bin\/sh -c #(nop)  CMD [\"\/opt\/mssql\/bin\/sqlservr\"]<\/pre>\n<p>It only remains to override the entry point to make a custom call of the sqlservr process during the container runtime with a delay of 4s for example. Here the command I used to start both the SQL Server container and the debug container in parallel and how I managed to trace all the desired events of the sqlservr process.<\/p>\n<pre class=\"brush: bash; gutter: true; first-line: 1\">docker run --name sql1 \\\n --env 'ACCEPT_EULA=Y' \\\n --env 'MSSQL_SA_PASSWORD=Password1' \\\n --volume \/t\/Docker\/DMK\/BACKUP\/test1:\/var\/opt\/mssql\/ \\\n --publish 1401:1433 \\\n --detach \\\n --entrypoint \"\/bin\/sh\" \\\n mcr.microsoft.com\/mssql\/server:2019-latest -c 'sleep 4 &amp;&amp; \/opt\/mssql\/bin\/sqlservr' &amp;&amp; \\\ndocker run --rm --name debug -t --pid=container:sql1 \\\n --net=container:sql1 \\\n --cap-add sys_admin \\\n --cap-add sys_ptrace \\\n strace &gt; trace.txt<\/pre>\n<p>I get the following result (pretty similar to Anthony\u2019s result in his blog post)<\/p>\n<pre class=\"brush: shell; gutter: true; first-line: 1\">strace: Process 1 attached\n09:12:12 wait4(-1, [{WIFEXITED(s) &amp;&amp; WEXITSTATUS(s) == 0}], 0, NULL) = 6\n09:12:15 --- SIGCHLD {si_signo=SIGCHLD, si_code=CLD_EXITED, si_pid=6, si_uid=0, si_status=0, si_utime=0, si_stime=0} ---\n09:12:15 rt_sigreturn({mask=[]})        = 6\n09:12:15 clone(strace: Process 13 attached\n &lt;unfinished ...&gt;\n[pid    13] 09:12:15 execve(\"\/opt\/mssql\/bin\/sqlservr\", [\"\/opt\/mssql\/bin\/sqlservr\"], 0x5577ad6ccbc8 \/* 6 vars *\/ &lt;unfinished ...&gt;\n[pid     1] 09:12:15 &lt;... clone resumed&gt; child_stack=NULL, flags=CLONE_CHILD_CLEARTID|CLONE_CHILD_SETTID|SIGCHLD, child_tidptr=0x7f941b2499d0) = 13\n[pid     1] 09:12:15 wait4(-1,  &lt;unfinished ...&gt;\n[pid    13] 09:12:15 &lt;... execve resumed&gt; ) = 0\n[pid    13] 09:12:15 brk(NULL)          = 0x558af526b000\n[pid    13] 09:12:15 access(\"\/etc\/ld.so.nohwcap\", F_OK) = -1 ENOENT (No such file or directory)\n[pid    13] 09:12:15 readlink(\"\/proc\/self\/exe\", \"\/opt\/mssql\/bin\/sqlservr\", 4096) = 23\n[pid    13] 09:12:15 access(\"\/etc\/ld.so.preload\", R_OK) = -1 ENOENT (No such file or directory)\n[pid    13] 09:12:15 open(\"\/opt\/mssql\/bin\/tls\/x86_64\/libpthread.so.0\", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)\n\u2026<\/pre>\n<p>Here we go ! Feel free to comment!<\/p>\n<p>Happy container debugging!<\/p>\n<p><span style=\"float: none; background-color: #ffffff; color: #333333; cursor: text; font-family: Georgia,'Times New Roman','Bitstream Charter',Times,serif; font-size: 16px; font-style: normal; font-variant: normal; font-weight: 400; letter-spacing: normal; text-align: left; text-decoration: none; text-indent: 0px; text-transform: none;\">By David Barbarin<\/span><\/p>\n","protected":false},"excerpt":{"rendered":"<p>When it comes to troubleshooting processes or to get a deeper look of how SQL Server works internally , I always used debugging tools as windbg on Windows and since SQL Server is available on Linux, I switched to strace tool. But let\u2019s add containers in the game now. I didn\u2019t want to touch any [&hellip;]<\/p>\n","protected":false},"author":26,"featured_media":12766,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[229,1504,99],"tags":[1688,73,1346,1689],"type_dbi":[],"class_list":["post-12765","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-database-administration-monitoring","category-docker","category-sql-server","tag-container-debugging","tag-linux","tag-sqlserver","tag-strace"],"acf":[],"yoast_head":"<!-- This site is optimized with the Yoast SEO Premium plugin v27.2 (Yoast SEO v27.2) - https:\/\/yoast.com\/product\/yoast-seo-premium-wordpress\/ -->\n<title>Debugging SQL Server containers considerations - dbi Blog<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.dbi-services.com\/blog\/debugging-sql-server-containers-considerations\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Debugging SQL Server containers considerations\" \/>\n<meta property=\"og:description\" content=\"When it comes to troubleshooting processes or to get a deeper look of how SQL Server works internally , I always used debugging tools as windbg on Windows and since SQL Server is available on Linux, I switched to strace tool. But let\u2019s add containers in the game now. I didn\u2019t want to touch any [&hellip;]\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.dbi-services.com\/blog\/debugging-sql-server-containers-considerations\/\" \/>\n<meta property=\"og:site_name\" content=\"dbi Blog\" \/>\n<meta property=\"article:published_time\" content=\"2019-09-05T12:47:24+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2023-07-17T06:16:11+00:00\" \/>\n<meta property=\"og:image\" content=\"http:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/blog-162-0-banner-e1567694673119.jpg\" \/>\n\t<meta property=\"og:image:width\" content=\"400\" \/>\n\t<meta property=\"og:image:height\" content=\"295\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/jpeg\" \/>\n<meta name=\"author\" content=\"Microsoft Team\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Microsoft Team\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"5 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/www.dbi-services.com\/blog\/debugging-sql-server-containers-considerations\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/www.dbi-services.com\/blog\/debugging-sql-server-containers-considerations\/\"},\"author\":{\"name\":\"Microsoft Team\",\"@id\":\"https:\/\/www.dbi-services.com\/blog\/#\/schema\/person\/bfab48333280d616e1170e7369df90a4\"},\"headline\":\"Debugging SQL Server containers considerations\",\"datePublished\":\"2019-09-05T12:47:24+00:00\",\"dateModified\":\"2023-07-17T06:16:11+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/www.dbi-services.com\/blog\/debugging-sql-server-containers-considerations\/\"},\"wordCount\":1057,\"commentCount\":0,\"image\":{\"@id\":\"https:\/\/www.dbi-services.com\/blog\/debugging-sql-server-containers-considerations\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/blog-162-0-banner-e1567694673119.jpg\",\"keywords\":[\"container debugging\",\"Linux\",\"SQLServer\",\"strace\"],\"articleSection\":[\"Database Administration &amp; Monitoring\",\"Docker\",\"SQL Server\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/www.dbi-services.com\/blog\/debugging-sql-server-containers-considerations\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.dbi-services.com\/blog\/debugging-sql-server-containers-considerations\/\",\"url\":\"https:\/\/www.dbi-services.com\/blog\/debugging-sql-server-containers-considerations\/\",\"name\":\"Debugging SQL Server containers considerations - dbi Blog\",\"isPartOf\":{\"@id\":\"https:\/\/www.dbi-services.com\/blog\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/www.dbi-services.com\/blog\/debugging-sql-server-containers-considerations\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/www.dbi-services.com\/blog\/debugging-sql-server-containers-considerations\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/blog-162-0-banner-e1567694673119.jpg\",\"datePublished\":\"2019-09-05T12:47:24+00:00\",\"dateModified\":\"2023-07-17T06:16:11+00:00\",\"author\":{\"@id\":\"https:\/\/www.dbi-services.com\/blog\/#\/schema\/person\/bfab48333280d616e1170e7369df90a4\"},\"breadcrumb\":{\"@id\":\"https:\/\/www.dbi-services.com\/blog\/debugging-sql-server-containers-considerations\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.dbi-services.com\/blog\/debugging-sql-server-containers-considerations\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/www.dbi-services.com\/blog\/debugging-sql-server-containers-considerations\/#primaryimage\",\"url\":\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/blog-162-0-banner-e1567694673119.jpg\",\"contentUrl\":\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/blog-162-0-banner-e1567694673119.jpg\",\"width\":400,\"height\":295},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.dbi-services.com\/blog\/debugging-sql-server-containers-considerations\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Accueil\",\"item\":\"https:\/\/www.dbi-services.com\/blog\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Debugging SQL Server containers considerations\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.dbi-services.com\/blog\/#website\",\"url\":\"https:\/\/www.dbi-services.com\/blog\/\",\"name\":\"dbi Blog\",\"description\":\"\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.dbi-services.com\/blog\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.dbi-services.com\/blog\/#\/schema\/person\/bfab48333280d616e1170e7369df90a4\",\"name\":\"Microsoft Team\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/secure.gravatar.com\/avatar\/c44a1a792c059f24055763aa77d80a244467f6eef724a8bd13db8d4a350b7a4c?s=96&d=mm&r=g\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/c44a1a792c059f24055763aa77d80a244467f6eef724a8bd13db8d4a350b7a4c?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/c44a1a792c059f24055763aa77d80a244467f6eef724a8bd13db8d4a350b7a4c?s=96&d=mm&r=g\",\"caption\":\"Microsoft Team\"},\"url\":\"https:\/\/www.dbi-services.com\/blog\/author\/microsoft-team\/\"}]}<\/script>\n<!-- \/ Yoast SEO Premium plugin. -->","yoast_head_json":{"title":"Debugging SQL Server containers considerations - dbi Blog","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.dbi-services.com\/blog\/debugging-sql-server-containers-considerations\/","og_locale":"en_US","og_type":"article","og_title":"Debugging SQL Server containers considerations","og_description":"When it comes to troubleshooting processes or to get a deeper look of how SQL Server works internally , I always used debugging tools as windbg on Windows and since SQL Server is available on Linux, I switched to strace tool. But let\u2019s add containers in the game now. I didn\u2019t want to touch any [&hellip;]","og_url":"https:\/\/www.dbi-services.com\/blog\/debugging-sql-server-containers-considerations\/","og_site_name":"dbi Blog","article_published_time":"2019-09-05T12:47:24+00:00","article_modified_time":"2023-07-17T06:16:11+00:00","og_image":[{"width":400,"height":295,"url":"http:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/blog-162-0-banner-e1567694673119.jpg","type":"image\/jpeg"}],"author":"Microsoft Team","twitter_card":"summary_large_image","twitter_misc":{"Written by":"Microsoft Team","Est. reading time":"5 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.dbi-services.com\/blog\/debugging-sql-server-containers-considerations\/#article","isPartOf":{"@id":"https:\/\/www.dbi-services.com\/blog\/debugging-sql-server-containers-considerations\/"},"author":{"name":"Microsoft Team","@id":"https:\/\/www.dbi-services.com\/blog\/#\/schema\/person\/bfab48333280d616e1170e7369df90a4"},"headline":"Debugging SQL Server containers considerations","datePublished":"2019-09-05T12:47:24+00:00","dateModified":"2023-07-17T06:16:11+00:00","mainEntityOfPage":{"@id":"https:\/\/www.dbi-services.com\/blog\/debugging-sql-server-containers-considerations\/"},"wordCount":1057,"commentCount":0,"image":{"@id":"https:\/\/www.dbi-services.com\/blog\/debugging-sql-server-containers-considerations\/#primaryimage"},"thumbnailUrl":"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/blog-162-0-banner-e1567694673119.jpg","keywords":["container debugging","Linux","SQLServer","strace"],"articleSection":["Database Administration &amp; Monitoring","Docker","SQL Server"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/www.dbi-services.com\/blog\/debugging-sql-server-containers-considerations\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/www.dbi-services.com\/blog\/debugging-sql-server-containers-considerations\/","url":"https:\/\/www.dbi-services.com\/blog\/debugging-sql-server-containers-considerations\/","name":"Debugging SQL Server containers considerations - dbi Blog","isPartOf":{"@id":"https:\/\/www.dbi-services.com\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.dbi-services.com\/blog\/debugging-sql-server-containers-considerations\/#primaryimage"},"image":{"@id":"https:\/\/www.dbi-services.com\/blog\/debugging-sql-server-containers-considerations\/#primaryimage"},"thumbnailUrl":"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/blog-162-0-banner-e1567694673119.jpg","datePublished":"2019-09-05T12:47:24+00:00","dateModified":"2023-07-17T06:16:11+00:00","author":{"@id":"https:\/\/www.dbi-services.com\/blog\/#\/schema\/person\/bfab48333280d616e1170e7369df90a4"},"breadcrumb":{"@id":"https:\/\/www.dbi-services.com\/blog\/debugging-sql-server-containers-considerations\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.dbi-services.com\/blog\/debugging-sql-server-containers-considerations\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.dbi-services.com\/blog\/debugging-sql-server-containers-considerations\/#primaryimage","url":"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/blog-162-0-banner-e1567694673119.jpg","contentUrl":"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/blog-162-0-banner-e1567694673119.jpg","width":400,"height":295},{"@type":"BreadcrumbList","@id":"https:\/\/www.dbi-services.com\/blog\/debugging-sql-server-containers-considerations\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Accueil","item":"https:\/\/www.dbi-services.com\/blog\/"},{"@type":"ListItem","position":2,"name":"Debugging SQL Server containers considerations"}]},{"@type":"WebSite","@id":"https:\/\/www.dbi-services.com\/blog\/#website","url":"https:\/\/www.dbi-services.com\/blog\/","name":"dbi Blog","description":"","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.dbi-services.com\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Person","@id":"https:\/\/www.dbi-services.com\/blog\/#\/schema\/person\/bfab48333280d616e1170e7369df90a4","name":"Microsoft Team","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/secure.gravatar.com\/avatar\/c44a1a792c059f24055763aa77d80a244467f6eef724a8bd13db8d4a350b7a4c?s=96&d=mm&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/c44a1a792c059f24055763aa77d80a244467f6eef724a8bd13db8d4a350b7a4c?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/c44a1a792c059f24055763aa77d80a244467f6eef724a8bd13db8d4a350b7a4c?s=96&d=mm&r=g","caption":"Microsoft Team"},"url":"https:\/\/www.dbi-services.com\/blog\/author\/microsoft-team\/"}]}},"_links":{"self":[{"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/posts\/12765","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/users\/26"}],"replies":[{"embeddable":true,"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/comments?post=12765"}],"version-history":[{"count":1,"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/posts\/12765\/revisions"}],"predecessor-version":[{"id":26706,"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/posts\/12765\/revisions\/26706"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/media\/12766"}],"wp:attachment":[{"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/media?parent=12765"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/categories?post=12765"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/tags?post=12765"},{"taxonomy":"type","embeddable":true,"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/type_dbi?post=12765"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}