<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: LabEx</title>
    <description>The latest articles on DEV Community by LabEx (labex).</description>
    <link>https://dev.to/labex</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Forganization%2Fprofile_image%2F8995%2F715cc2d8-2659-45f0-994c-c1c271f135d0.jpg</url>
      <title>DEV Community: LabEx</title>
      <link>https://dev.to/labex</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/labex"/>
    <language>en</language>
    <item>
      <title>Find a File by Name with find</title>
      <dc:creator>Labby</dc:creator>
      <pubDate>Sun, 06 Dec 2026 01:09:50 +0000</pubDate>
      <link>https://dev.to/labex/find-a-file-by-name-with-find-5cf4</link>
      <guid>https://dev.to/labex/find-a-file-by-name-with-find-5cf4</guid>
      <description>&lt;p&gt;Originally published on &lt;a href="https://labex.io/blog/find-a-file-by-name" rel="noopener noreferrer"&gt;LabEx Blog&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;You remember a filename but not the folder that holds it. On Linux, &lt;code&gt;find&lt;/code&gt; can start at a chosen directory, descend into its subdirectories, and print the paths whose names match. It reports locations; it does not open or change the files it finds.&lt;/p&gt;

&lt;p&gt;This &lt;a href="https://www.youtube.com/watch?v=JtC6Ef4Ddyw" rel="noopener noreferrer"&gt;LabEx video&lt;/a&gt; follows an old menu file from a cafe directory to the path that identifies it. You can recreate the example in a directory you own.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F3cc7o8rltwm0st9tmj9m.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F3cc7o8rltwm0st9tmj9m.png" alt="A LabEx terminal shows find locating menu-old.txt inside an archive directory" width="800" height="450"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Create a small directory tree
&lt;/h2&gt;

&lt;p&gt;Run these commands in a disposable directory:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;mkdir -p ~/find-demo/cafe/archive
&lt;span class="nb"&gt;cd&lt;/span&gt; ~/find-demo/cafe
touch menu.txt notes.txt archive/menu-old.txt
find . -type f -name &lt;span class="s1"&gt;'menu-old.txt'&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The output is:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;./archive/menu-old.txt
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The dot means “start in the current directory.” &lt;code&gt;find&lt;/code&gt; also walks into the &lt;code&gt;archive&lt;/code&gt; subdirectory. &lt;code&gt;-type f&lt;/code&gt; limits the result to regular files, and &lt;code&gt;-name&lt;/code&gt; tests the filename. Keeping the filename in quotes prevents the shell from treating any wildcard characters in it as its own pattern.&lt;/p&gt;

&lt;h2&gt;
  
  
  Read the result as a path
&lt;/h2&gt;

&lt;p&gt;The leading &lt;code&gt;./&lt;/code&gt; says the path is relative to the folder where you ran the command. In this example, follow &lt;code&gt;archive/menu-old.txt&lt;/code&gt; below the current &lt;code&gt;cafe&lt;/code&gt; directory to reach the matching file.&lt;/p&gt;

&lt;p&gt;&lt;code&gt;find&lt;/code&gt; searches names and paths, not the text stored inside a file. Use &lt;code&gt;grep&lt;/code&gt; when you need to search file contents instead. If you only want to list the current folder without descending into subdirectories, &lt;code&gt;find . -maxdepth 1 -type f&lt;/code&gt; is one way to keep the search shallow. See the &lt;a href="https://www.gnu.org/software/findutils/manual/html_mono/find.html" rel="noopener noreferrer"&gt;GNU find manual&lt;/a&gt; for the full set of tests and actions.&lt;/p&gt;

&lt;h2&gt;
  
  
  Try another filename
&lt;/h2&gt;

&lt;p&gt;Search for the notes file from the same directory:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;find . -type f -name &lt;span class="s1"&gt;'notes.txt'&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This time the result is &lt;code&gt;./notes.txt&lt;/code&gt;, because the file is directly inside &lt;code&gt;cafe&lt;/code&gt;. Change the quoted name to one that is absent to see the normal no-match result: &lt;code&gt;find&lt;/code&gt; prints no path and leaves the directory unchanged.&lt;/p&gt;

&lt;p&gt;For a broader hands-on introduction to moving around a Linux environment and working with files, try &lt;a href="https://labex.io/courses/quick-start-with-linux" rel="noopener noreferrer"&gt;Quick Start with Linux&lt;/a&gt; on LabEx.&lt;/p&gt;

</description>
      <category>linux</category>
      <category>commandline</category>
    </item>
    <item>
      <title>Find Matching Lines in a File with grep</title>
      <dc:creator>Labby</dc:creator>
      <pubDate>Sat, 05 Dec 2026 02:18:47 +0000</pubDate>
      <link>https://dev.to/labex/find-matching-lines-in-a-file-with-grep-1g9i</link>
      <guid>https://dev.to/labex/find-matching-lines-in-a-file-with-grep-1g9i</guid>
      <description>&lt;p&gt;Originally published on &lt;a href="https://labex.io/blog/grep-find-matching-lines" rel="noopener noreferrer"&gt;LabEx Blog&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;A three-line order file contains two orders for Mochi. Instead of reading a long file line by line, &lt;code&gt;grep&lt;/code&gt; can print the lines that contain a pattern. The result is a selection of lines; it does not edit the file.&lt;/p&gt;

&lt;p&gt;This &lt;a href="https://www.youtube.com/watch?v=IfaT62LNous" rel="noopener noreferrer"&gt;LabEx video&lt;/a&gt; follows one search from the original file to the terminal output. You can reproduce the example in a disposable directory.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Ff6or5l65p1sdy0iusj5s.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Ff6or5l65p1sdy0iusj5s.png" alt="The order file and terminal show that the first and third lines match Mochi" width="800" height="450"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Create and inspect the file
&lt;/h2&gt;

&lt;p&gt;Run these commands in a directory you own:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;mkdir -p ~/grep-demo
&lt;span class="nb"&gt;cd&lt;/span&gt; ~/grep-demo
&lt;span class="nb"&gt;printf&lt;/span&gt; &lt;span class="s1"&gt;'%s\n'&lt;/span&gt; &lt;span class="s1"&gt;'09:00 Mochi tea'&lt;/span&gt; &lt;span class="s1"&gt;'09:05 Luna coffee'&lt;/span&gt; &lt;span class="s1"&gt;'09:10 Mochi cocoa'&lt;/span&gt; &lt;span class="o"&gt;&amp;gt;&lt;/span&gt; orders.txt
cat orders.txt
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The file now has three lines. Search for the name with:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;grep &lt;span class="s1"&gt;'Mochi'&lt;/span&gt; orders.txt
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The output contains the two full lines with &lt;code&gt;Mochi&lt;/code&gt;, in their original order:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;09:00 Mochi tea
09:10 Mochi cocoa
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The quoted argument is the search pattern, and &lt;code&gt;orders.txt&lt;/code&gt; is the input file. &lt;code&gt;grep&lt;/code&gt; searches file contents, not filenames. The name &lt;code&gt;Mochi&lt;/code&gt; is an ordinary pattern here; in general, grep patterns can include regular-expression characters. For literal text containing such characters, GNU grep offers &lt;code&gt;-F&lt;/code&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  Keep the original line numbers
&lt;/h2&gt;

&lt;p&gt;Add &lt;code&gt;-n&lt;/code&gt; when you need to find the matches again in the source file:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;grep -n &lt;span class="s1"&gt;'Mochi'&lt;/span&gt; orders.txt
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;





&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;1:09:00 Mochi tea
3:09:10 Mochi cocoa
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The numbers refer to lines in the input, not positions in the filtered output. Run &lt;code&gt;cat orders.txt&lt;/code&gt; again: the Luna line remains in the file.&lt;/p&gt;

&lt;h2&gt;
  
  
  Try a different spelling
&lt;/h2&gt;

&lt;p&gt;Search for &lt;code&gt;Luna&lt;/code&gt; and then lowercase &lt;code&gt;mochi&lt;/code&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;grep &lt;span class="s1"&gt;'Luna'&lt;/span&gt; orders.txt
grep &lt;span class="s1"&gt;'mochi'&lt;/span&gt; orders.txt
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The first command prints the second order. The second prints no matching line because the default search is case-sensitive. No output from this example means the pattern did not match; a missing or unreadable file is a different situation and produces an error. GNU grep documents its &lt;a href="https://www.gnu.org/software/grep/manual/grep.html" rel="noopener noreferrer"&gt;matching options and exit status&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;To practice the same kind of search with log messages, try LabEx's &lt;a href="https://labex.io/labs/linux-grep-command-pattern-searching-219192" rel="noopener noreferrer"&gt;grep command lab&lt;/a&gt;. Its basic search and case-insensitive steps build on this example; the lab's &lt;code&gt;-i&lt;/code&gt; option extends the video's default case-sensitive search.&lt;/p&gt;

</description>
      <category>linux</category>
      <category>commandline</category>
    </item>
    <item>
      <title>Save a Linux Handover Note Without Losing Earlier Lines</title>
      <dc:creator>Labby</dc:creator>
      <pubDate>Fri, 04 Dec 2026 01:34:38 +0000</pubDate>
      <link>https://dev.to/labex/save-a-linux-handover-note-without-losing-earlier-lines-2bel</link>
      <guid>https://dev.to/labex/save-a-linux-handover-note-without-losing-earlier-lines-2bel</guid>
      <description>&lt;p&gt;Originally published on &lt;a href="https://labex.io/blog/save-linux-handover-note" rel="noopener noreferrer"&gt;LabEx Blog&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;When a note needs both a fresh starting section and one later reminder, the redirection operator matters. A single &lt;code&gt;&amp;gt;&lt;/code&gt; replaces a file; &lt;code&gt;&amp;gt;&amp;gt;&lt;/code&gt; adds to the end of the file that is already there.&lt;/p&gt;

&lt;p&gt;This &lt;a href="https://www.youtube.com/watch?v=FmY8NK_3nWo" rel="noopener noreferrer"&gt;LabEx video&lt;/a&gt; uses a small cafe handover to make the difference visible. The task is to save the first two menu lines, add &lt;code&gt;Check milk.&lt;/code&gt;, and read back the complete note.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fqlptyyzz2q5n1mtupdck.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fqlptyyzz2q5n1mtupdck.png" alt="A Linux terminal shows a handover file with Coffee, Tea, and Check milk on separate lines." width="800" height="457"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Replace the old practice note
&lt;/h2&gt;

&lt;p&gt;Start with a &lt;code&gt;menu.txt&lt;/code&gt; file that contains three lines. To put just the first two lines into &lt;code&gt;handover.txt&lt;/code&gt;, run:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;head -n 2 menu.txt &lt;span class="o"&gt;&amp;gt;&lt;/span&gt; handover.txt
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;code&gt;head -n 2&lt;/code&gt; writes the first two lines to standard output. The single greater-than sign redirects that output into &lt;code&gt;handover.txt&lt;/code&gt;. If that file already contains an old note, its old contents are replaced.&lt;/p&gt;

&lt;p&gt;At this point, the handover file contains:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Coffee  $3
Tea     $2
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Append a reminder without replacing the menu lines
&lt;/h2&gt;

&lt;p&gt;Now add the reminder with two greater-than signs:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;printf&lt;/span&gt; &lt;span class="s1"&gt;'Check milk.\n'&lt;/span&gt; &lt;span class="o"&gt;&amp;gt;&amp;gt;&lt;/span&gt; handover.txt
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;code&gt;printf&lt;/code&gt; produces the reminder and its newline. &lt;code&gt;&amp;gt;&amp;gt;&lt;/code&gt; appends that output after the existing contents, so the two menu lines stay in place. If this command used &lt;code&gt;&amp;gt;&lt;/code&gt; instead, the file would contain only the reminder.&lt;/p&gt;

&lt;h2&gt;
  
  
  Verify the saved note
&lt;/h2&gt;

&lt;p&gt;Read the complete file before handing it over:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;cat handover.txt
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The expected result is:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Coffee  $3
Tea     $2
Check milk.
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This is a useful pattern whenever a command builds the first part of a file and a later command adds a small follow-up. Use &lt;code&gt;&amp;gt;&lt;/code&gt; deliberately when the old file should be replaced, and use &lt;code&gt;&amp;gt;&amp;gt;&lt;/code&gt; when existing lines must remain.&lt;/p&gt;

&lt;h2&gt;
  
  
  Practice the redirect operators
&lt;/h2&gt;

&lt;p&gt;Try the same workflow in LabEx's &lt;a href="https://labex.io/courses/quick-start-with-linux" rel="noopener noreferrer"&gt;Linux Commands course&lt;/a&gt;, then change the reminder and run &lt;code&gt;cat handover.txt&lt;/code&gt; again. For the narrated walkthrough, watch &lt;a href="https://www.youtube.com/watch?v=FmY8NK_3nWo" rel="noopener noreferrer"&gt;Mission: Leave a Cafe Handover Note&lt;/a&gt;.&lt;/p&gt;

</description>
      <category>linux</category>
      <category>commandline</category>
      <category>shell</category>
    </item>
    <item>
      <title>How a Linux Pipe Passes One Command's Output to Another</title>
      <dc:creator>Labby</dc:creator>
      <pubDate>Thu, 03 Dec 2026 01:10:18 +0000</pubDate>
      <link>https://dev.to/labex/how-a-linux-pipe-passes-one-commands-output-to-another-4ckf</link>
      <guid>https://dev.to/labex/how-a-linux-pipe-passes-one-commands-output-to-another-4ckf</guid>
      <description>&lt;p&gt;Originally published on &lt;a href="https://labex.io/blog/connect-commands-with-a-pipe" rel="noopener noreferrer"&gt;LabEx Blog&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;A pipe lets one command hand its output directly to the next command. It is useful when the first command produces more text than you need, and the next command can select, transform, or inspect that text.&lt;/p&gt;

&lt;p&gt;This short &lt;a href="https://www.youtube.com/watch?v=rPciEgfW--4" rel="noopener noreferrer"&gt;LabEx video&lt;/a&gt; follows a six-line order file through a simple pipeline. The goal is not to create a temporary file: it is to make the first command's standard output become the second command's standard input.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fukww6qbm4m63ojgyznye.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fukww6qbm4m63ojgyznye.png" alt="A flow diagram showing cat orders.txt sending standard output through a pipe to head -n 3, producing the first three of six lines." width="800" height="450"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Start with two separate commands
&lt;/h2&gt;

&lt;p&gt;In the example, &lt;code&gt;orders.txt&lt;/code&gt; contains six lines. Reading it with &lt;code&gt;cat&lt;/code&gt; prints every line:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;cat orders.txt
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;To read only the first three lines directly from that file, use &lt;code&gt;head&lt;/code&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;head -n 3 orders.txt
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Those commands do different jobs. &lt;code&gt;cat&lt;/code&gt; writes text to standard output. &lt;code&gt;head -n 3&lt;/code&gt; can read text from a file, but it can also read text supplied on standard input.&lt;/p&gt;

&lt;h2&gt;
  
  
  Put a pipe between them
&lt;/h2&gt;

&lt;p&gt;Use the vertical bar to connect the commands:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;cat orders.txt &lt;span class="o"&gt;|&lt;/span&gt; head -n 3
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The shell starts the commands as one pipeline. Instead of sending the output from &lt;code&gt;cat&lt;/code&gt; to the terminal, it connects that output to the input of &lt;code&gt;head&lt;/code&gt;. &lt;code&gt;head&lt;/code&gt; receives all six lines, prints the first three, and then the result appears in the terminal.&lt;/p&gt;

&lt;p&gt;The file itself is not changed. Run &lt;code&gt;cat orders.txt&lt;/code&gt; again and all six original lines are still there.&lt;/p&gt;

&lt;h2&gt;
  
  
  Read the command from left to right
&lt;/h2&gt;

&lt;p&gt;When a pipeline feels confusing, name the connection rather than memorizing the punctuation:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;code&gt;cat orders.txt&lt;/code&gt; produces text.&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;|&lt;/code&gt; carries that text to the next command.&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;head -n 3&lt;/code&gt; reads the incoming text and keeps the first three lines.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;That model also helps you spot a common mistake: type both sides before pressing Enter. The pipe is part of one command line, not a second command you run afterward.&lt;/p&gt;

&lt;h2&gt;
  
  
  Try it in a Linux environment
&lt;/h2&gt;

&lt;p&gt;Start with the &lt;a href="https://labex.io/courses/quick-start-with-linux" rel="noopener noreferrer"&gt;Quick Start with Linux course on LabEx&lt;/a&gt; to practice terminal navigation and reading files. Then create a small text file of your own and change the number after &lt;code&gt;-n&lt;/code&gt; to see how the selected output changes.&lt;/p&gt;

&lt;p&gt;For the full walkthrough, watch &lt;a href="https://www.youtube.com/watch?v=rPciEgfW--4" rel="noopener noreferrer"&gt;Connect Commands with a Pipe&lt;/a&gt;.&lt;/p&gt;

</description>
      <category>linux</category>
      <category>commandline</category>
      <category>shell</category>
    </item>
    <item>
      <title>Watch a Growing Log File with tail -f</title>
      <dc:creator>Labby</dc:creator>
      <pubDate>Wed, 02 Dec 2026 01:14:36 +0000</pubDate>
      <link>https://dev.to/labex/watch-a-growing-log-file-with-tail-f-191n</link>
      <guid>https://dev.to/labex/watch-a-growing-log-file-with-tail-f-191n</guid>
      <description>&lt;p&gt;Originally published on &lt;a href="https://labex.io/blog/tail-follow-log" rel="noopener noreferrer"&gt;LabEx Blog&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;When a log gains a line after each request or job, rerunning &lt;code&gt;tail&lt;/code&gt; makes you guess whether anything changed. &lt;code&gt;tail -f&lt;/code&gt; leaves one terminal watching while the file grows. The useful habit is to separate the watcher from the writer, then stop the watcher without confusing that action with changing the file.&lt;/p&gt;

&lt;p&gt;This short &lt;a href="https://www.youtube.com/watch?v=NztcRe4LmHM" rel="noopener noreferrer"&gt;LabEx video&lt;/a&gt; uses two terminals and one small order log. The commands below reproduce that pattern in any disposable directory.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F9fvsxk5l5lu7l3nw518p.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F9fvsxk5l5lu7l3nw518p.png" alt="A LabEx terminal showing a new log entry appearing while a file is followed" width="800" height="450"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Start with a file you can safely change
&lt;/h2&gt;

&lt;p&gt;Use a directory you own. The first command makes a log with three known lines; the second prints its current end.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;mkdir -p ~/tail-demo/logs
&lt;span class="nb"&gt;printf&lt;/span&gt; &lt;span class="s1"&gt;'%s\n'&lt;/span&gt; \
  &lt;span class="s1"&gt;'09:00 INFO cafe opened'&lt;/span&gt; \
  &lt;span class="s1"&gt;'09:05 ERROR milk unavailable'&lt;/span&gt; \
  &lt;span class="s1"&gt;'09:10 INFO milk restocked'&lt;/span&gt; \
  &lt;span class="o"&gt;&amp;gt;&lt;/span&gt; ~/tail-demo/logs/orders.log
tail ~/tail-demo/logs/orders.log
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;code&gt;tail&lt;/code&gt; normally prints the last ten lines when no count is given. With &lt;code&gt;-f&lt;/code&gt;, GNU &lt;code&gt;tail&lt;/code&gt; prints the current end and then waits for appended data instead of returning to a prompt.&lt;/p&gt;

&lt;h2&gt;
  
  
  Let one terminal follow the file
&lt;/h2&gt;

&lt;p&gt;Open Terminal A, change to the test directory, and run:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;cd&lt;/span&gt; ~/tail-demo
tail -f logs/orders.log
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Terminal A should show the three records and then remain occupied. That missing prompt is the important state: &lt;code&gt;tail&lt;/code&gt; is still running and ready to show an addition. It has not detected an error merely because it has no new line to print.&lt;/p&gt;

&lt;p&gt;Leave that window alone. Open Terminal B in the same directory and append one complete record:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;printf&lt;/span&gt; &lt;span class="s1"&gt;'09:15 INFO tea\n'&lt;/span&gt; &lt;span class="o"&gt;&amp;gt;&amp;gt;&lt;/span&gt; logs/orders.log
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Terminal B returns to its prompt because the append is finished. Terminal A should print the new &lt;code&gt;09:15&lt;/code&gt; line without rerunning &lt;code&gt;tail -f&lt;/code&gt;. The &lt;a href="https://www.youtube.com/watch?v=NztcRe4LmHM" rel="noopener noreferrer"&gt;video demonstration&lt;/a&gt; shows the two-window handoff and the difference between an occupied watcher and a terminal that is ready for another command.&lt;/p&gt;

&lt;h2&gt;
  
  
  Stop the watcher, then check the file
&lt;/h2&gt;

&lt;p&gt;Return to Terminal A and press Ctrl+C. This interrupts &lt;code&gt;tail&lt;/code&gt; in that terminal; it does not delete the file or undo the line Terminal B wrote. Check the last line with a separate command:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;tail -n 1 logs/orders.log
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The output should still be:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;09:15 INFO tea
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;That final check is useful because it separates two facts: the follower stopped, and the file remains intact. If you later follow service logs that rotate, check the implementation's rotation behavior too. GNU &lt;code&gt;tail -f&lt;/code&gt; follows a file descriptor by default; GNU documents &lt;code&gt;tail -F&lt;/code&gt; as the shorthand for following a name with retry, which is often the behavior wanted when a log is renamed and recreated.&lt;/p&gt;

&lt;p&gt;For terminal orientation, prompts, and running short commands before trying the two-window example, &lt;a href="https://labex.io/courses/linux-terminal-basics" rel="noopener noreferrer"&gt;Linux Terminal Basics&lt;/a&gt; starts with guided environment, prompt, and command exercises. The course page currently describes those terminal fundamentals; it does not claim to be this log-following exercise.&lt;/p&gt;

&lt;h2&gt;
  
  
  References
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;a href="https://www.gnu.org/software/coreutils/manual/html_node/tail-invocation.html" rel="noopener noreferrer"&gt;GNU Coreutils: &lt;code&gt;tail&lt;/code&gt; invocation&lt;/a&gt; — default output, follow modes, retry, and rotated-file behavior.&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://labex.io/courses/linux-terminal-basics" rel="noopener noreferrer"&gt;LabEx: Linux Terminal Basics&lt;/a&gt; — current beginner terminal syllabus and lab links.&lt;/li&gt;
&lt;/ul&gt;

</description>
      <category>linux</category>
      <category>commandline</category>
      <category>logging</category>
    </item>
    <item>
      <title>Why an Old Page Can Appear After a Site Move</title>
      <dc:creator>Labby</dc:creator>
      <pubDate>Tue, 01 Dec 2026 01:11:36 +0000</pubDate>
      <link>https://dev.to/labex/why-an-old-page-can-appear-after-a-site-move-3o4n</link>
      <guid>https://dev.to/labex/why-an-old-page-can-appear-after-a-site-move-3o4n</guid>
      <description>&lt;p&gt;Originally published on &lt;a href="https://labex.io/blog/old-page-after-site-moves" rel="noopener noreferrer"&gt;LabEx Blog&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;A site can move to a new server while a visitor still sees an old page at the same URL. That result is not enough to identify the cause. Two different caches can preserve two different clues:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;A DNS cache can reuse an older address for the site name.&lt;/li&gt;
&lt;li&gt;A browser cache can reuse an older HTTP response without making a new document request.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The distinction matters when you are debugging a migration. Check the path from name to address, then check whether the browser requested a fresh page.&lt;/p&gt;

&lt;p&gt;This guide follows the teaching scenario in the LabEx video &lt;a href="https://www.youtube.com/watch?v=a_1qyVRi9-g" rel="noopener noreferrer"&gt;Why Do I See the Old Page After a Site Moves?&lt;/a&gt;. The site, addresses, and schedule below are fictional examples.&lt;/p&gt;

&lt;h2&gt;
  
  
  Start with the same URL
&lt;/h2&gt;

&lt;p&gt;Imagine that &lt;code&gt;festival.example/schedule&lt;/code&gt; moved to a new server. One visitor sees the opening film at 7:00 PM, while another sees 8:00 PM from the same saved link. The hostname and path can stay unchanged during the move; what changes is the address returned for the hostname, or the response a browser decides to reuse.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fnyis855h5ikddownrj79.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fnyis855h5ikddownrj79.png" alt="Two DNS lookups for the same site show an old saved address and a newer address." width="800" height="450"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;The first question is whether the browser connected to the expected server. DNS maps a name to an address. Resolvers commonly cache that answer for its TTL, or time to live. If a resolver saved the old answer before the move and its TTL has not expired, a fresh connection may still reach the old server.&lt;/p&gt;

&lt;p&gt;That does not mean the DNS record is wrong everywhere. Another resolver that looks up the name after the move can receive the new address immediately. Different caches can legitimately have different remaining lifetimes.&lt;/p&gt;

&lt;h2&gt;
  
  
  A new address does not guarantee a new page
&lt;/h2&gt;

&lt;p&gt;Now assume DNS resolves to the new address. A visitor can still see an old schedule if the browser reuses a saved HTTP response. In that case, the browser may display a page it already has rather than issue a new document request.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F84h2bp89yir8xhkbk1vf.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F84h2bp89yir8xhkbk1vf.png" alt="The browser has a new DNS address ready while its cached page still shows the earlier schedule." width="" height=""&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;DNS caching remembers an address. Browser caching remembers a response. They are separate layers, so clearing or waiting for one does not prove what happened at the other.&lt;/p&gt;

&lt;h2&gt;
  
  
  Check the request evidence
&lt;/h2&gt;

&lt;p&gt;Use a new request to distinguish the layers. In a browser's Network panel, open a fresh tab or reload with cache disabled while developer tools are open. Then look at the document request:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Confirm whether the browser made a network request for the page.&lt;/li&gt;
&lt;li&gt;Note whether the response came from the network or from the browser cache.&lt;/li&gt;
&lt;li&gt;If you can record it safely, compare the resolved address with the address expected after the move.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Ft9dnluqdx8sr1qc06ppm.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Ft9dnluqdx8sr1qc06ppm.png" alt="An illustrated browser Network panel shows cache disabled and a new document response." width="800" height="450"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Disabling the browser cache only tests the saved page layer. It does not force every DNS resolver to forget an answer. If the page is still old after a verified network request, the address and server response are the next evidence to inspect.&lt;/p&gt;

&lt;h2&gt;
  
  
  Record two visits, not just one result
&lt;/h2&gt;

&lt;p&gt;For a concise handoff, capture the URL, the time, whether the page came from the network or cache, and the address when available. Compare a fresh request with a repeat visit. This makes it possible to say which evidence changed rather than guessing that every stale page is a DNS problem.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fmk8468owvosgb2x6m3ap.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fmk8468owvosgb2x6m3ap.png" alt="A comparison distinguishes an old network response from a repeat visit served by browser cache." width="800" height="450"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Avoid testing someone else's account, private page, or access route. Use systems and test identities you are authorized to inspect.&lt;/p&gt;

&lt;h2&gt;
  
  
  Practice the DNS part safely
&lt;/h2&gt;

&lt;p&gt;The video also walks through the decision points step by step. For hands-on DNS practice, LabEx's &lt;a href="https://labex.io/courses/dns-service-administration" rel="noopener noreferrer"&gt;DNS Service Administration course&lt;/a&gt; includes &lt;strong&gt;Configuring a Caching Resolver&lt;/strong&gt;, where you can compare cold and cached DNS queries and observe how a record's TTL affects a cached answer.&lt;/p&gt;

&lt;p&gt;Watch the full video: &lt;a href="https://www.youtube.com/watch?v=a_1qyVRi9-g" rel="noopener noreferrer"&gt;Why Do I See the Old Page After a Site Moves?&lt;/a&gt;.&lt;/p&gt;

</description>
      <category>cybersecurity</category>
      <category>dns</category>
      <category>browsers</category>
    </item>
    <item>
      <title>Can a Former Teammate Still Open Your Shared Folder?</title>
      <dc:creator>Labby</dc:creator>
      <pubDate>Mon, 30 Nov 2026 02:24:21 +0000</pubDate>
      <link>https://dev.to/labex/can-a-former-teammate-still-open-your-shared-folder-dam</link>
      <guid>https://dev.to/labex/can-a-former-teammate-still-open-your-shared-folder-dam</guid>
      <description>&lt;p&gt;Originally published on &lt;a href="https://labex.io/blog/former-teammate-shared-folder" rel="noopener noreferrer"&gt;LabEx Blog&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Removing someone from a shared folder sounds straightforward: open the sharing settings, remove their name, and move on. But a direct invitation is only one way a person might get access.&lt;/p&gt;

&lt;p&gt;They may also belong to a group that can open the folder, or they may have a link that works for anyone who has it. To check the whole picture, follow each route separately and test the result.&lt;/p&gt;

&lt;p&gt;This tutorial uses a fictional example from the LabEx video &lt;a href="https://www.youtube.com/watch?v=zzzr9tmDL1U" rel="noopener noreferrer"&gt;Can a Former Coworker Still Open the Shared Folder?&lt;/a&gt;. The illustrations show a teaching model, not the interface of a particular file-sharing service. Names and settings vary by product.&lt;/p&gt;

&lt;h2&gt;
  
  
  The situation
&lt;/h2&gt;

&lt;p&gt;Mina manages a folder called &lt;strong&gt;Shift Plans&lt;/strong&gt; for a film festival. Jules has left the team, but Leo still needs to read the schedule. Mina removes Jules from the folder's list of direct invitees.&lt;/p&gt;

&lt;p&gt;Before reading on, make a prediction: if Jules saved an old link to the folder, will it still open?&lt;/p&gt;

&lt;p&gt;The answer depends on more than whether Jules appears in the direct access list. Let's inspect three routes: people, groups, and links.&lt;/p&gt;

&lt;h2&gt;
  
  
  1. Check direct invitations
&lt;/h2&gt;

&lt;p&gt;Start with the folder's sharing settings. Look for people who have been invited by name and identify the entry for the person whose access should end.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Farjeraaspa5vwdzdoob7.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Farjeraaspa5vwdzdoob7.png" alt="The Shift Plans sharing list shows Jules has no direct invitation and Leo can still view the folder." width="800" height="450"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Mina has removed Jules's direct invitation and kept Leo's. That establishes one useful fact: &lt;strong&gt;the direct invitation no longer grants Jules access&lt;/strong&gt;. It does not establish that every other route is closed.&lt;/p&gt;

&lt;p&gt;Signing in and being authorized to open a folder are separate questions. A service can recognize an account and still deny it access to a particular folder. It can also grant access through a group, even when the account has no individual invitation.&lt;/p&gt;

&lt;h2&gt;
  
  
  2. Follow group access
&lt;/h2&gt;

&lt;p&gt;Next, look for groups that have permission to view or edit the folder. A group lets an owner grant access to multiple people at once; the individual members may not appear as separate direct invitees.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F9ywys1qdvmoc2zj74e6s.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F9ywys1qdvmoc2zj74e6s.png" alt="The Festival Crew group can view Shift Plans, and its membership still includes Jules and Leo." width="800" height="450"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Here, &lt;strong&gt;Festival Crew&lt;/strong&gt; has viewer access, and Jules is still a member. In this example, that group membership lets Jules open Shift Plans while signed in, even though the direct invitation is gone.&lt;/p&gt;

&lt;p&gt;Mina asks the group owner to remove Jules because Jules has left the crew entirely. Leo remains in the group. Before requesting a membership change in a real organization, check what else the group controls: removing someone from a group can affect more than one folder. If the change is meant to apply only to this folder, review the folder's group grant and the service's available controls with its owner.&lt;/p&gt;

&lt;h2&gt;
  
  
  3. Inspect the link audience
&lt;/h2&gt;

&lt;p&gt;The next question is not simply whether an old link exists. It is &lt;strong&gt;who the link allows in&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fblle0bjz8te3tzq5l910.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fblle0bjz8te3tzq5l910.png" alt="A folder link is set to anyone with the link, and a signed-out clean browser session can open it." width="800" height="450"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;In the example, the link is set to &lt;strong&gt;anyone with the link can view&lt;/strong&gt;. Mina tests it in a clean, signed-out browser session and the folder opens. That shows the link setting permits access without signing in; it does not show whether Jules or anyone else actually used it.&lt;/p&gt;

&lt;p&gt;Mina changes the audience to people who already have access. The address can remain the same, but holding it no longer grants access by itself. Deleting a message containing the link would remove only that copy of the address; it would not change the folder's sharing settings.&lt;/p&gt;

&lt;p&gt;Product behavior differs, so check the exact wording and effect of the setting in the service you use.&lt;/p&gt;

&lt;h2&gt;
  
  
  4. Verify both outcomes
&lt;/h2&gt;

&lt;p&gt;Removing unwanted access is only half the job. The people who still need the folder must be able to use it.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fxdn1dox9pan11er7eike.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fxdn1dox9pan11er7eike.png" alt="Two denied checks appear beside a successful check for Leo, who still has permission." width="800" height="450"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;In the teaching example, Mina checks both sides:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Open the old link in a clean, signed-out session. It should ask for access.&lt;/li&gt;
&lt;li&gt;Use an approved test account Mina controls that has no invitation or group membership. It should also be refused.&lt;/li&gt;
&lt;li&gt;Confirm that Leo can open the folder while signed in to his authorized account.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Use only accounts and resources you are authorized to test. Do not sign in as the former teammate or infer their activity from a test account. Review the relevant people and group lists for that identity as well: a generic test account does not prove every possible route available to a particular person has been removed.&lt;/p&gt;

&lt;p&gt;In a work setting, record the folder, the access routes changed, the identity used for each test, and the observed result. If an authorized person loses access, revisit the relevant grants before making additional changes.&lt;/p&gt;

&lt;h2&gt;
  
  
  One important limit
&lt;/h2&gt;

&lt;p&gt;Changing sharing settings controls future access through those settings. It does not recall a copy someone already downloaded or otherwise retained. Depending on the service and your organization's procedures, other controls or follow-up may be necessary.&lt;/p&gt;

&lt;h2&gt;
  
  
  Try a second case
&lt;/h2&gt;

&lt;p&gt;Imagine another folder, &lt;strong&gt;Poster Drafts&lt;/strong&gt;. Jules has no direct invitation, and its link is already restricted. The Design Crew group can view the folder, and Jules is still a member. Leo and the rest of the design team still need access.&lt;/p&gt;

&lt;p&gt;Which entry explains the access? The group membership. If Jules has left that crew, ask its owner to remove the relevant membership while preserving the group's access for the active designers. Then repeat a denied test and an allowed test using accounts you control.&lt;/p&gt;

&lt;p&gt;The repeatable habit is simple: &lt;strong&gt;check people, groups, and links; change the route that grants unwanted access; then verify both the denied and allowed cases.&lt;/strong&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Continue practicing
&lt;/h2&gt;

&lt;p&gt;Want to explore how group membership affects access in another setting? In LabEx's &lt;a href="https://labex.io/tutorials/manage-local-groups-and-membership-663390" rel="noopener noreferrer"&gt;Manage Local Groups and Membership&lt;/a&gt; lab, you can inspect and change Linux group memberships with practice accounts. Linux permissions work differently from the shared-link settings in this example, but the lab gives you a hands-on way to explore the group membership part of the picture.&lt;/p&gt;

</description>
      <category>cybersecurity</category>
      <category>permissions</category>
    </item>
    <item>
      <title>One site won't load: a small DNS troubleshooting exercise</title>
      <dc:creator>Labby</dc:creator>
      <pubDate>Sat, 28 Nov 2026 12:46:22 +0000</pubDate>
      <link>https://dev.to/labex/one-site-wont-load-a-small-dns-troubleshooting-exercise-14j2</link>
      <guid>https://dev.to/labex/one-site-wont-load-a-small-dns-troubleshooting-exercise-14j2</guid>
      <description>&lt;p&gt;&lt;em&gt;AI-assisted tutorial.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;A single website fails to load. Is your connection down, is the name failing to resolve, or is the service having trouble? Start by narrowing the question.&lt;/p&gt;

&lt;h2&gt;
  
  
  Compare first
&lt;/h2&gt;

&lt;p&gt;Try another unrelated site. If it loads, your connection can reach at least one service. That does not prove the first site is down: the two sites may use different DNS records, networks, or servers.&lt;/p&gt;

&lt;h2&gt;
  
  
  Look up the name
&lt;/h2&gt;

&lt;p&gt;On a terminal with &lt;code&gt;nslookup&lt;/code&gt; installed, run:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;nslookup example.com
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Replace &lt;code&gt;example.com&lt;/code&gt; with the hostname you are investigating. A returned address tells you that this resolver supplied an answer; it does not prove the web server is healthy. A lookup failure points you toward name resolution, but check the exact error and resolver before deciding why it failed.&lt;/p&gt;

&lt;h2&gt;
  
  
  Choose the next check
&lt;/h2&gt;

&lt;p&gt;If the name resolves, compare the address with a known-good source and investigate the service or connection next. If it does not, repeat the lookup using a trusted resolver and check the spelling. Change one thing at a time and record the result so the comparison remains useful.&lt;/p&gt;

</description>
      <category>cli</category>
      <category>networking</category>
      <category>tutorial</category>
    </item>
    <item>
      <title>What happens between the address bar and the page?</title>
      <dc:creator>Labby</dc:creator>
      <pubDate>Thu, 26 Nov 2026 07:30:54 +0000</pubDate>
      <link>https://dev.to/labex/what-happens-between-the-address-bar-and-the-page-4286</link>
      <guid>https://dev.to/labex/what-happens-between-the-address-bar-and-the-page-4286</guid>
      <description>&lt;p&gt;&lt;em&gt;AI-assisted tutorial.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Pick a page you visit all the time. Before you open it, try to name the host and path in its URL. Then watch how the browser finds the server and what comes back.&lt;/p&gt;

&lt;p&gt;  &lt;iframe src="https://www.youtube.com/embed/XmqkjIUnyHk" width="710" height="399"&gt;
  &lt;/iframe&gt;
&lt;/p&gt;

&lt;p&gt;A quick check after watching: a page that returns 404 got far enough to receive an HTTP response. Where did things stop if the browser couldn't resolve the host?&lt;/p&gt;

&lt;p&gt;&lt;a href="https://www.youtube.com/watch?v=XmqkjIUnyHk" rel="noopener noreferrer"&gt;Watch on YouTube&lt;/a&gt;&lt;/p&gt;

</description>
      <category>beginners</category>
      <category>learning</category>
      <category>networking</category>
      <category>webdev</category>
    </item>
    <item>
      <title>Docker EXPOSE vs. Publish: Why Your Running Container Is Unreachable</title>
      <dc:creator>Labby</dc:creator>
      <pubDate>Mon, 07 Sep 2026 05:51:32 +0000</pubDate>
      <link>https://dev.to/labex/docker-expose-vs-publish-why-your-running-container-is-unreachable-390c</link>
      <guid>https://dev.to/labex/docker-expose-vs-publish-why-your-running-container-is-unreachable-390c</guid>
      <description>&lt;p&gt;Your Dockerfile contains &lt;code&gt;EXPOSE 8000&lt;/code&gt;. The container is running. &lt;code&gt;docker ps&lt;/code&gt; even lists &lt;code&gt;8000/tcp&lt;/code&gt;. Yet opening &lt;code&gt;http://localhost:8080&lt;/code&gt; gives you a connection error.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;&lt;code&gt;EXPOSE&lt;/code&gt; records a container port in the image's metadata. &lt;code&gt;docker run -p&lt;/code&gt; publishes a container port through an address and port on the Docker host. Neither instruction makes your application start listening.&lt;/strong&gt; These are three separate controls, and a working browser request depends on more than the first one.&lt;/p&gt;

&lt;p&gt;This guide uses one small HTTP server to reproduce three states: an unpublished port, a working published port, and a published port pointing at an unreachable listener. You will inspect each state before changing it, so the commands remain useful when your next container has a different application inside.&lt;/p&gt;

&lt;h2&gt;
  
  
  What EXPOSE, publish, and bind actually control
&lt;/h2&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Setting&lt;/th&gt;
&lt;th&gt;Where it belongs&lt;/th&gt;
&lt;th&gt;What it does&lt;/th&gt;
&lt;th&gt;What it does not prove&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;EXPOSE 8000&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Dockerfile&lt;/td&gt;
&lt;td&gt;Records an intended container port&lt;/td&gt;
&lt;td&gt;That a server is running or a host port exists&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;-p 127.0.0.1:8080:8000&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;&lt;code&gt;docker run&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Maps host loopback port 8080 to container port 8000&lt;/td&gt;
&lt;td&gt;That the application accepts that traffic&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;--bind 0.0.0.0&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Our Python server command&lt;/td&gt;
&lt;td&gt;Makes the application listen on all IPv4 interfaces inside its container&lt;/td&gt;
&lt;td&gt;That Docker publishes a host port&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;Docker's &lt;a href="https://docs.docker.com/reference/dockerfile/#expose" rel="noopener noreferrer"&gt;Dockerfile reference&lt;/a&gt; explicitly separates exposing from publishing. An image can document a port without making it available through &lt;code&gt;localhost&lt;/code&gt; on the host. Conversely, an explicit &lt;code&gt;-p&lt;/code&gt; mapping can target a port that the Dockerfile never declared.&lt;/p&gt;

&lt;p&gt;For this example, read the publishing argument from left to right:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;-p 127.0.0.1:8080:8000
   └ host IP  │    └ container port
              └ host port

Host request to 127.0.0.1:8080
    → Docker port mapping
    → container network interface, port 8000
    → HTTP server
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The two port numbers need not match. Use &lt;code&gt;8080&lt;/code&gt; in the host-side URL because that is the entrance you created; the server still listens on &lt;code&gt;8000&lt;/code&gt; inside the container. Docker documents this syntax in its &lt;a href="https://docs.docker.com/get-started/docker-concepts/running-containers/publishing-ports/" rel="noopener noreferrer"&gt;port publishing walkthrough&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  Prepare one server you can test from both sides
&lt;/h2&gt;

&lt;p&gt;You need a working Docker Engine, a terminal with a POSIX shell, &lt;code&gt;curl&lt;/code&gt;, and permission to run Docker commands. Check the engine before copying the example:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker version
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;You should see both Client and Server information. A missing Server section or a daemon connection error is an environment problem to resolve first. This guide uses Linux containers on Docker's ordinary bridge network; it does not use &lt;code&gt;--network host&lt;/code&gt; or custom routing rules.&lt;/p&gt;

&lt;p&gt;The experiments and screenshots below were captured in a LabEx Ubuntu 22.04 instance VM with Docker Engine 20.10.21 on September 7, 2026. The image tag &lt;code&gt;python:3.12-alpine&lt;/code&gt; can change over time. The experiment concerns port behavior, rather than a specific Python patch release.&lt;/p&gt;

&lt;p&gt;If creating images and running named containers are new to you, the &lt;a href="https://labex.io/courses/docker-for-beginners" rel="noopener noreferrer"&gt;Docker for Beginners course&lt;/a&gt; includes &lt;strong&gt;Docker Run Command Parameters&lt;/strong&gt;, &lt;strong&gt;Custom Docker Images&lt;/strong&gt;, and &lt;strong&gt;Docker Networking Basics&lt;/strong&gt;. Those activities provide the surrounding practice for this example.&lt;/p&gt;

&lt;p&gt;Create an empty working directory:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;mkdir &lt;/span&gt;docker-port-demo
&lt;span class="nb"&gt;cd &lt;/span&gt;docker-port-demo
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Save this as &lt;code&gt;index.html&lt;/code&gt;. The page deliberately has no application dependencies: if it loads, an HTTP request reached the server.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight html"&gt;&lt;code&gt;&lt;span class="cp"&gt;&amp;lt;!doctype html&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;html&lt;/span&gt; &lt;span class="na"&gt;lang=&lt;/span&gt;&lt;span class="s"&gt;"en"&lt;/span&gt;&lt;span class="nt"&gt;&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;meta&lt;/span&gt; &lt;span class="na"&gt;charset=&lt;/span&gt;&lt;span class="s"&gt;"utf-8"&lt;/span&gt; &lt;span class="nt"&gt;/&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;meta&lt;/span&gt; &lt;span class="na"&gt;name=&lt;/span&gt;&lt;span class="s"&gt;"viewport"&lt;/span&gt; &lt;span class="na"&gt;content=&lt;/span&gt;&lt;span class="s"&gt;"width=device-width"&lt;/span&gt; &lt;span class="nt"&gt;/&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;title&amp;gt;&lt;/span&gt;Docker port demo&lt;span class="nt"&gt;&amp;lt;/title&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;style&amp;gt;&lt;/span&gt;
    &lt;span class="nt"&gt;body&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
      &lt;span class="nl"&gt;font&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;22px&lt;/span&gt;&lt;span class="p"&gt;/&lt;/span&gt;&lt;span class="m"&gt;1.6&lt;/span&gt; &lt;span class="n"&gt;system-ui&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
      &lt;span class="nl"&gt;max-width&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;760px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
      &lt;span class="nl"&gt;margin&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;12vh&lt;/span&gt; &lt;span class="nb"&gt;auto&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
      &lt;span class="nl"&gt;padding&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;32px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
      &lt;span class="nl"&gt;color&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;#18334a&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
      &lt;span class="nl"&gt;background&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;#f1f7fa&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt;
    &lt;span class="nt"&gt;h1&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
      &lt;span class="nl"&gt;font-size&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;44px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
      &lt;span class="nl"&gt;line-height&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;1.15&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt;
    &lt;span class="nt"&gt;code&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
      &lt;span class="nl"&gt;background&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;#dcecf5&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
      &lt;span class="nl"&gt;padding&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;3px&lt;/span&gt; &lt;span class="m"&gt;9px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
      &lt;span class="nl"&gt;border-radius&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="m"&gt;6px&lt;/span&gt;&lt;span class="p"&gt;;&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;/style&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;p&amp;gt;&lt;/span&gt;DOCKER NETWORKING EXPERIMENT&lt;span class="nt"&gt;&amp;lt;/p&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;h1&amp;gt;&lt;/span&gt;Your request reached the container.&lt;span class="nt"&gt;&amp;lt;/h1&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;p&amp;gt;&lt;/span&gt;This page is served by Python on container port &lt;span class="nt"&gt;&amp;lt;code&amp;gt;&lt;/span&gt;8000&lt;span class="nt"&gt;&amp;lt;/code&amp;gt;&lt;/span&gt;.&lt;span class="nt"&gt;&amp;lt;/p&amp;gt;&lt;/span&gt;
  &lt;span class="nt"&gt;&amp;lt;p&amp;gt;&lt;/span&gt;
    Change the port mapping or listening address, then test the same request
    again.
  &lt;span class="nt"&gt;&amp;lt;/p&amp;gt;&lt;/span&gt;
&lt;span class="nt"&gt;&amp;lt;/html&amp;gt;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;In the same directory, save this as &lt;code&gt;Dockerfile&lt;/code&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight docker"&gt;&lt;code&gt;&lt;span class="k"&gt;FROM&lt;/span&gt;&lt;span class="s"&gt; python:3.12-alpine&lt;/span&gt;
&lt;span class="k"&gt;WORKDIR&lt;/span&gt;&lt;span class="s"&gt; /site&lt;/span&gt;
&lt;span class="k"&gt;COPY&lt;/span&gt;&lt;span class="s"&gt; index.html .&lt;/span&gt;
&lt;span class="k"&gt;EXPOSE&lt;/span&gt;&lt;span class="s"&gt; 8000&lt;/span&gt;
&lt;span class="k"&gt;CMD&lt;/span&gt;&lt;span class="s"&gt; ["python", "-u", "-m", "http.server", "8000", "--bind", "0.0.0.0"]&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;code&gt;WORKDIR&lt;/code&gt; selects the directory to serve, &lt;code&gt;COPY&lt;/code&gt; adds the page, and &lt;code&gt;CMD&lt;/code&gt; starts the process. The &lt;code&gt;-u&lt;/code&gt; option makes Python's output unbuffered, which helps when reading startup messages through container logs. The &lt;code&gt;EXPOSE&lt;/code&gt; line describes the port; the &lt;code&gt;http.server&lt;/code&gt; command is what opens the listener.&lt;/p&gt;

&lt;p&gt;Build the image:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker build &lt;span class="nt"&gt;-t&lt;/span&gt; port-demo &lt;span class="nb"&gt;.&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Python's &lt;a href="https://docs.python.org/3.12/library/http.server.html" rel="noopener noreferrer"&gt;HTTP server documentation&lt;/a&gt; explains the command-line bind option and cautions against using this server for production. Use this small static page for the experiment, not as a deployment template for a sensitive application.&lt;/p&gt;

&lt;h2&gt;
  
  
  Experiment 1: EXPOSE without a published port
&lt;/h2&gt;

&lt;p&gt;Start the image without &lt;code&gt;-p&lt;/code&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker run &lt;span class="nt"&gt;-d&lt;/span&gt; &lt;span class="nt"&gt;--name&lt;/span&gt; exposed-only port-demo
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Inspect the image metadata and the running container:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker image inspect port-demo &lt;span class="nt"&gt;--format&lt;/span&gt; &lt;span class="s1"&gt;'{{json .Config.ExposedPorts}}'&lt;/span&gt;
docker ps &lt;span class="nt"&gt;--filter&lt;/span&gt; &lt;span class="nv"&gt;name&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;exposed-only &lt;span class="nt"&gt;--format&lt;/span&gt; &lt;span class="s1"&gt;'table {{.Names}}\t{{.Ports}}'&lt;/span&gt;
docker port exposed-only
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The image records &lt;code&gt;{"8000/tcp":{}}&lt;/code&gt;, and the container's port column shows &lt;code&gt;8000/tcp&lt;/code&gt;. However, &lt;code&gt;docker port exposed-only&lt;/code&gt; produces no mapping. The &lt;a href="https://docs.docker.com/reference/cli/docker/container/port/" rel="noopener noreferrer"&gt;docker port reference&lt;/a&gt; defines this command as a mapping inspection tool; it is not an application health check.&lt;/p&gt;

&lt;p&gt;Try a request from the &lt;strong&gt;Docker host terminal&lt;/strong&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl &lt;span class="nt"&gt;--max-time&lt;/span&gt; 3 http://127.0.0.1:8080/
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;It should fail if nothing else is listening on host port 8080. If it succeeds, inspect that other service before continuing: this container did not publish that address.&lt;/p&gt;

&lt;p&gt;Now make a request &lt;strong&gt;inside the container&lt;/strong&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker &lt;span class="nb"&gt;exec &lt;/span&gt;exposed-only python &lt;span class="nt"&gt;-c&lt;/span&gt; &lt;span class="s1"&gt;'import urllib.request; print(urllib.request.urlopen("http://127.0.0.1:8000").status)'&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The result is &lt;code&gt;200&lt;/code&gt;. This test uses Python because the image already contains it; you do not need to install &lt;code&gt;curl&lt;/code&gt; inside the container.&lt;/p&gt;

&lt;p&gt;Together, the observations say something precise: the application answers HTTP internally, but this container has no host port mapping. They do not say that the application is inaccessible from every possible network location. On a Linux bridge, the host and other containers on the same bridge may reach a reachable container listener directly. Docker explains that distinction in its &lt;a href="https://docs.docker.com/engine/network/drivers/bridge/" rel="noopener noreferrer"&gt;bridge network documentation&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  Experiment 2: publish the host entrance
&lt;/h2&gt;

&lt;p&gt;Start a second container from exactly the same image:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker run &lt;span class="nt"&gt;-d&lt;/span&gt; &lt;span class="nt"&gt;--name&lt;/span&gt; published &lt;span class="nt"&gt;-p&lt;/span&gt; 127.0.0.1:8080:8000 port-demo
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;After the server starts, inspect and test it:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker port published
curl &lt;span class="nt"&gt;-s&lt;/span&gt; &lt;span class="nt"&gt;-o&lt;/span&gt; /dev/null &lt;span class="nt"&gt;-w&lt;/span&gt; &lt;span class="s1"&gt;'Host HTTP status: %{http_code}\n'&lt;/span&gt; http://127.0.0.1:8080/
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The mapping is &lt;code&gt;8000/tcp -&amp;gt; 127.0.0.1:8080&lt;/code&gt;, and the request returns &lt;code&gt;Host HTTP status: 200&lt;/code&gt;. If a request made immediately after &lt;code&gt;docker run&lt;/code&gt; fails, check the logs and retry after startup; creating the container and accepting HTTP are separate events.&lt;/p&gt;

&lt;p&gt;&lt;a href="/blog/assets/posts/docker-expose-vs-publish/expose-and-publish.png"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fx72le8kzkgm8bl6tvfll.png" alt="A LabEx VM terminal showing an exposed-only container without a host mapping and a published container returning HTTP 200" width="798" height="161"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;The same image, tested in a LabEx VM. Adding a host mapping changes the host request result without changing the Dockerfile.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;You can now open &lt;code&gt;http://127.0.0.1:8080&lt;/code&gt; in a browser &lt;strong&gt;on the Docker host&lt;/strong&gt;. If Docker runs in a remote VM, your laptop's browser is a different machine; use the remote-preview section below.&lt;/p&gt;

&lt;p&gt;Why specify &lt;code&gt;127.0.0.1&lt;/code&gt;? With Docker's default settings, omitting the host IP publishes on all host interfaces. Explicit loopback binding is the appropriate starting point for a local development example. It does not add authentication or encryption. Docker also documents a caveat for engines older than 28.0.0: another host on the same layer-2 network may reach a localhost-published port. Our older demonstration VM is not evidence that loopback publishing provides complete isolation. See Docker's &lt;a href="https://docs.docker.com/engine/network/port-publishing/" rel="noopener noreferrer"&gt;publishing and mapping security notes&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  Experiment 3: a mapping exists, but the listener is wrong
&lt;/h2&gt;

&lt;p&gt;Now keep port publishing and change only the application's listening address. Use host port 8081 so the working container can remain available for comparison:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker run &lt;span class="nt"&gt;-d&lt;/span&gt; &lt;span class="nt"&gt;--name&lt;/span&gt; wrong-bind &lt;span class="nt"&gt;-p&lt;/span&gt; 127.0.0.1:8081:8000 &lt;span class="se"&gt;\&lt;/span&gt;
  port-demo python &lt;span class="nt"&gt;-u&lt;/span&gt; &lt;span class="nt"&gt;-m&lt;/span&gt; http.server 8000 &lt;span class="nt"&gt;--bind&lt;/span&gt; 127.0.0.1
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The command after &lt;code&gt;port-demo&lt;/code&gt; replaces this image's default &lt;code&gt;CMD&lt;/code&gt;. Python now listens only on the &lt;strong&gt;container's&lt;/strong&gt; loopback interface.&lt;/p&gt;

&lt;p&gt;Check the mapping, then test from the host:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker port wrong-bind
curl &lt;span class="nt"&gt;--max-time&lt;/span&gt; 3 http://127.0.0.1:8081/
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;A mapping exists, yet the HTTP request fails. Depending on your engine and network implementation, the error may be a reset or another connection failure; the important observation is that you do not receive the page.&lt;/p&gt;

&lt;p&gt;Repeat the internal check:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker &lt;span class="nb"&gt;exec &lt;/span&gt;wrong-bind python &lt;span class="nt"&gt;-c&lt;/span&gt; &lt;span class="s1"&gt;'import urllib.request; print(urllib.request.urlopen("http://127.0.0.1:8000").status)'&lt;/span&gt;
docker logs &lt;span class="nt"&gt;--tail&lt;/span&gt; 5 wrong-bind
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The internal request returns &lt;code&gt;200&lt;/code&gt;, and the startup log identifies &lt;code&gt;127.0.0.1&lt;/code&gt; as the bind address.&lt;/p&gt;

&lt;p&gt;&lt;a href="/blog/assets/posts/docker-expose-vs-publish/wrong-bind.png"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fb78bura7bl4hqxz4pkxn.png" alt="A LabEx VM terminal showing a published port failing from the host while the loopback-only HTTP server returns 200 inside the container" width="800" height="150"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Port forwarding exists. The application is listening at the wrong address for traffic arriving through the container's network interface.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;There are two different loopbacks here. &lt;code&gt;127.0.0.1&lt;/code&gt; in the publishing argument belongs to the host. &lt;code&gt;127.0.0.1&lt;/code&gt; in the Python command belongs to the container. Forwarded traffic arrives at the container's network interface, not its private loopback listener.&lt;/p&gt;

&lt;p&gt;For this server, restore &lt;code&gt;--bind 0.0.0.0&lt;/code&gt; by recreating the container with the image's default command:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker &lt;span class="nb"&gt;rm&lt;/span&gt; &lt;span class="nt"&gt;-f&lt;/span&gt; wrong-bind
docker run &lt;span class="nt"&gt;-d&lt;/span&gt; &lt;span class="nt"&gt;--name&lt;/span&gt; wrong-bind &lt;span class="nt"&gt;-p&lt;/span&gt; 127.0.0.1:8081:8000 port-demo
curl &lt;span class="nt"&gt;--retry&lt;/span&gt; 5 &lt;span class="nt"&gt;--retry-all-errors&lt;/span&gt; &lt;span class="nt"&gt;--retry-delay&lt;/span&gt; 1 http://127.0.0.1:8081/
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This final read-only request retries startup connection failures, including resets. The &lt;a href="https://curl.se/docs/manpage.html#--retry-all-errors" rel="noopener noreferrer"&gt;&lt;code&gt;--retry-all-errors&lt;/code&gt; option&lt;/a&gt; requires curl 7.71.0 or newer; with an older curl, wait for the startup log and repeat the request manually.&lt;/p&gt;

&lt;p&gt;The host-side mapping can stay on &lt;code&gt;127.0.0.1&lt;/code&gt; while the application listens on &lt;code&gt;0.0.0.0&lt;/code&gt; &lt;strong&gt;inside&lt;/strong&gt; the container. These settings control different boundaries. &lt;code&gt;0.0.0.0&lt;/code&gt; is a listening address meaning all IPv4 interfaces in that network namespace, not the URL to type into your browser.&lt;/p&gt;

&lt;h2&gt;
  
  
  Viewing the page from a LabEx VM
&lt;/h2&gt;

&lt;p&gt;A remote experiment adds another step to the request path:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Your browser → LabEx web preview → VM port 8082
             → Docker mapping → container port 8000
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;For the captured browser demonstration, we started a separate preview container:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker run &lt;span class="nt"&gt;-d&lt;/span&gt; &lt;span class="nt"&gt;--name&lt;/span&gt; preview &lt;span class="nt"&gt;-p&lt;/span&gt; 8082:8000 port-demo
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This mapping omits a host IP so the VM's preview service can reach it. In the LabEx environment, open a web preview for &lt;strong&gt;VM port 8082&lt;/strong&gt; and use the provided preview URL. The exact preview controls depend on the lab environment. Typing &lt;code&gt;localhost:8082&lt;/code&gt; into your laptop browser would target your laptop instead.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F71d59h8gr9ht16kjq59l.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F71d59h8gr9ht16kjq59l.png" alt="The example HTTP page served from a Docker container through a LabEx VM web preview" width="800" height="500"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;The actual example page reached through the LabEx VM preview. The temporary environment URL is excluded from the capture.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Only the disposable static demo is being served here. On your own remote server, publishing on all interfaces changes who may reach the application; choose the host binding and any surrounding network controls deliberately. A successful &lt;code&gt;curl&lt;/code&gt; inside the VM followed by a failed external preview means you should inspect the preview port and intervening network path before editing &lt;code&gt;EXPOSE&lt;/code&gt; again.&lt;/p&gt;

&lt;h2&gt;
  
  
  A troubleshooting order that preserves the evidence
&lt;/h2&gt;

&lt;p&gt;When another container is unreachable, start with the closest observable boundary and work outward.&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Question&lt;/th&gt;
&lt;th&gt;Check&lt;/th&gt;
&lt;th&gt;How to interpret it&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Is the container still running?&lt;/td&gt;
&lt;td&gt;&lt;code&gt;docker ps -a --filter name=published&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;An exited process needs log inspection before networking changes&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;What did the application report?&lt;/td&gt;
&lt;td&gt;&lt;code&gt;docker logs --tail 50 published&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Look for startup errors, port numbers, and bind addresses&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;What command actually started?&lt;/td&gt;
&lt;td&gt;&lt;code&gt;docker inspect published --format '{{json .Config.Cmd}}'&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;A runtime override may differ from the Dockerfile&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Is there a host mapping?&lt;/td&gt;
&lt;td&gt;&lt;code&gt;docker port published&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;No mapping means no published host entrance for this container&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Does HTTP work inside?&lt;/td&gt;
&lt;td&gt;Use the internal Python request above&lt;/td&gt;
&lt;td&gt;Success establishes internal HTTP response, not outside reachability&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Does HTTP work on the Docker host?&lt;/td&gt;
&lt;td&gt;&lt;code&gt;curl -v --max-time 3 http://127.0.0.1:8080/&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Failure with internal success narrows attention to mapping and bind address&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Does the remote browser use the same host and port?&lt;/td&gt;
&lt;td&gt;Compare its destination with the VM preview configuration&lt;/td&gt;
&lt;td&gt;A laptop localhost URL does not target a remote VM&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;The &lt;a href="https://docs.docker.com/reference/cli/docker/container/logs/" rel="noopener noreferrer"&gt;logs command&lt;/a&gt; retrieves container output, while &lt;a href="https://docs.docker.com/reference/cli/docker/container/inspect/" rel="noopener noreferrer"&gt;inspect&lt;/a&gt; returns configuration and state. Neither replaces a request to the actual endpoint. Some applications also write logs to files rather than standard output, so an empty &lt;code&gt;docker logs&lt;/code&gt; result is not proof that nothing happened.&lt;/p&gt;

&lt;p&gt;If Docker reports that a host port is already allocated, change the &lt;strong&gt;host&lt;/strong&gt; number, for example to &lt;code&gt;127.0.0.1:8083:8000&lt;/code&gt;, and use 8083 in your URL. Changing the container number to 8083 would point forwarding at a port where this server is not listening.&lt;/p&gt;

&lt;p&gt;An HTTP &lt;code&gt;404&lt;/code&gt; or &lt;code&gt;500&lt;/code&gt; is different from a connection failure: an HTTP server responded. Confirm you reached the intended service, then investigate its path or application behavior. Repeatedly rebuilding the image to add more &lt;code&gt;EXPOSE&lt;/code&gt; lines will not explain an HTTP error response.&lt;/p&gt;

&lt;h2&gt;
  
  
  Questions that come up next
&lt;/h2&gt;

&lt;h3&gt;
  
  
  Do I need EXPOSE if I already use -p?
&lt;/h3&gt;

&lt;p&gt;No. Explicit publishing does not require an &lt;code&gt;EXPOSE&lt;/code&gt; declaration. Keeping the declaration can still communicate the image's intended port to people and tools. It should agree with the application configuration, but it does not enforce that configuration.&lt;/p&gt;

&lt;p&gt;To test that distinction yourself, remove &lt;code&gt;EXPOSE 8000&lt;/code&gt;, build under a second tag, and run it with an explicit mapping on an unused host port. Avoid using a base image that already declares the same port if your experiment is intended to show the absence of exposed-port metadata.&lt;/p&gt;

&lt;h3&gt;
  
  
  What is the difference between -p and -P?
&lt;/h3&gt;

&lt;p&gt;Lowercase &lt;code&gt;-p&lt;/code&gt; specifies a publication, such as &lt;code&gt;-p 127.0.0.1:8080:8000&lt;/code&gt;. Uppercase &lt;code&gt;-P&lt;/code&gt; publishes all exposed ports to automatically selected host ports. Inspect the resulting mappings rather than guessing the chosen numbers. Neither option changes the application's listening port or address.&lt;/p&gt;

&lt;h3&gt;
  
  
  Does Compose expose publish a port?
&lt;/h3&gt;

&lt;p&gt;No. For the working example, the equivalent host publication belongs under &lt;code&gt;ports&lt;/code&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight yaml"&gt;&lt;code&gt;&lt;span class="na"&gt;services&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
  &lt;span class="na"&gt;web&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
    &lt;span class="na"&gt;image&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;port-demo&lt;/span&gt;
    &lt;span class="na"&gt;ports&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
      &lt;span class="pi"&gt;-&lt;/span&gt; &lt;span class="s2"&gt;"&lt;/span&gt;&lt;span class="s"&gt;127.0.0.1:8080:8000"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Stop the earlier &lt;code&gt;published&lt;/code&gt; container before starting this service, because both would otherwise claim host port 8080. The image must already exist on the Docker host for this example.&lt;/p&gt;

&lt;p&gt;Compose's &lt;code&gt;expose&lt;/code&gt; describes container ports without publishing them to the host. It is not a firewall between services. The official &lt;a href="https://docs.docker.com/reference/compose-file/services/" rel="noopener noreferrer"&gt;Compose services reference&lt;/a&gt; documents both fields and their different purposes.&lt;/p&gt;

&lt;h3&gt;
  
  
  Do two containers need published ports to communicate?
&lt;/h3&gt;

&lt;p&gt;Not when they can already communicate over the same user-defined bridge network. They can use a container name and the application's container port, such as &lt;code&gt;web:8000&lt;/code&gt;; the application still needs to listen on a reachable interface. Publishing is for the additional host entrance. Do not publish a database port merely because another container needs to talk to the database.&lt;/p&gt;

&lt;h2&gt;
  
  
  Clean up, then practice a different failure
&lt;/h2&gt;

&lt;p&gt;Remove only the containers created by this guide:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker &lt;span class="nb"&gt;rm&lt;/span&gt; &lt;span class="nt"&gt;-f&lt;/span&gt; exposed-only published wrong-bind preview
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;If you skipped the preview step, Docker will report that &lt;code&gt;preview&lt;/code&gt; does not exist. If you tried the optional Compose example, stop it with &lt;code&gt;docker compose down&lt;/code&gt; from its project directory as well. Keep &lt;code&gt;port-demo&lt;/code&gt; if you want to repeat the experiments; otherwise remove that image with &lt;code&gt;docker image rm port-demo&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;For the next practice session, choose the gap your experiment exposed:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;If reading &lt;code&gt;docker run&lt;/code&gt; arguments was the hard part, work through &lt;a href="https://labex.io/labs/docker-docker-run-command-parameters-389228" rel="noopener noreferrer"&gt;Docker Run Command Parameters&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;If you want to extend the example to container networks, continue with &lt;a href="https://labex.io/labs/docker-docker-networking-basics-389048" rel="noopener noreferrer"&gt;Docker Networking Basics&lt;/a&gt; and &lt;a href="https://labex.io/labs/docker-docker-network-playground-389054" rel="noopener noreferrer"&gt;Docker Network Playground&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;If addresses, processes, and service troubleshooting still feel disconnected, use the networking and service checkpoints in the &lt;a href="https://labex.io/blog/linux-learning-roadmap" rel="noopener noreferrer"&gt;Linux learning roadmap&lt;/a&gt;.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Repeat the failed request before applying a fix, change one boundary, and repeat the same request afterward. The useful result is being able to explain which observation changed and why.&lt;/p&gt;

&lt;h2&gt;
  
  
  References
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;a href="https://docs.docker.com/reference/dockerfile/#expose" rel="noopener noreferrer"&gt;Dockerfile reference: EXPOSE&lt;/a&gt; — exposed-port metadata and its relationship to explicit publishing.&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://docs.docker.com/get-started/docker-concepts/running-containers/publishing-ports/" rel="noopener noreferrer"&gt;Docker: Publishing and exposing ports&lt;/a&gt; — mapping syntax and automatically selected host ports.&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://docs.docker.com/engine/network/port-publishing/" rel="noopener noreferrer"&gt;Docker: Port publishing and mapping&lt;/a&gt; — host binding scope and the pre-28.0.0 localhost caveat.&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://docs.docker.com/engine/network/drivers/bridge/" rel="noopener noreferrer"&gt;Docker: Bridge network driver&lt;/a&gt; — communication within a bridge and name resolution on user-defined networks.&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://docs.docker.com/reference/cli/docker/container/port/" rel="noopener noreferrer"&gt;Docker CLI: container port&lt;/a&gt; — inspect an existing port mapping.&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://docs.docker.com/reference/cli/docker/container/logs/" rel="noopener noreferrer"&gt;Docker CLI: container logs&lt;/a&gt; and &lt;a href="https://docs.docker.com/reference/cli/docker/container/inspect/" rel="noopener noreferrer"&gt;container inspect&lt;/a&gt; — distinguish application output from container configuration.&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://docs.docker.com/reference/compose-file/services/" rel="noopener noreferrer"&gt;Docker Compose services reference&lt;/a&gt; — &lt;code&gt;ports&lt;/code&gt;, &lt;code&gt;expose&lt;/code&gt;, and service configuration.&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://curl.se/docs/manpage.html#--retry-all-errors" rel="noopener noreferrer"&gt;curl manual&lt;/a&gt; — retry behavior for the post-startup verification request.&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://docs.python.org/3.12/library/http.server.html" rel="noopener noreferrer"&gt;Python 3.12: http.server&lt;/a&gt; — the demonstration server, bind address, and production limitations.&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://labex.io/courses/docker-for-beginners" rel="noopener noreferrer"&gt;LabEx: Docker for Beginners&lt;/a&gt; — the related image, container, and networking practice sequence.&lt;/li&gt;
&lt;/ul&gt;

</description>
      <category>docker</category>
      <category>networking</category>
      <category>linux</category>
    </item>
    <item>
      <title>Linux Learning Roadmap for 2026: From Your First Command to Running a Service</title>
      <dc:creator>Labby</dc:creator>
      <pubDate>Mon, 07 Sep 2026 05:51:05 +0000</pubDate>
      <link>https://dev.to/labex/linux-learning-roadmap-for-2026-from-your-first-command-to-running-a-service-2oma</link>
      <guid>https://dev.to/labex/linux-learning-roadmap-for-2026-from-your-first-command-to-running-a-service-2oma</guid>
      <description>&lt;p&gt;A service cannot read its configuration file. You can find the file and open it yourself, but restarting the service changes nothing. What would you inspect next: the path, the file's owner, the directory permissions, or the identity running the service?&lt;/p&gt;

&lt;p&gt;That question connects several parts of Linux that beginners often study separately. A useful learning roadmap should help you make those connections. Its checkpoints should tell you what you can now investigate and fix, not just which commands you have seen.&lt;/p&gt;

&lt;p&gt;The route below starts with a terminal and ends with maintaining a small service: checking its files, reading its logs, tracing a connection, and recovering a configuration. Use the checkpoints to choose your starting point. Looking up syntax is allowed; being able to explain and verify the change is the test.&lt;/p&gt;

&lt;h2&gt;
  
  
  The roadmap at a glance
&lt;/h2&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Stage&lt;/th&gt;
&lt;th&gt;Learn to work with&lt;/th&gt;
&lt;th&gt;Move on when you can…&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Choose an environment&lt;/td&gt;
&lt;td&gt;Distribution, shell, user, system capabilities&lt;/td&gt;
&lt;td&gt;Identify where commands run and which administration tasks the environment supports&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Navigate and edit&lt;/td&gt;
&lt;td&gt;Paths, help, files, directories, a text editor&lt;/td&gt;
&lt;td&gt;Find a configuration, edit a copy, and check exactly what changed&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Control access&lt;/td&gt;
&lt;td&gt;Users, groups, ownership, file and directory permissions&lt;/td&gt;
&lt;td&gt;Give the intended identity access and verify the access boundary&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Process text&lt;/td&gt;
&lt;td&gt;Standard streams, pipes, filters, exit status&lt;/td&gt;
&lt;td&gt;Produce a repeatable report from a log file&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Inspect a running system&lt;/td&gt;
&lt;td&gt;Processes, packages, services, journals&lt;/td&gt;
&lt;td&gt;Use evidence to recover a failed service&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Trace connections&lt;/td&gt;
&lt;td&gt;Addresses, routes, DNS, listening sockets, SSH&lt;/td&gt;
&lt;td&gt;Separate a name-resolution problem from a connection or service problem&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Automate and recover&lt;/td&gt;
&lt;td&gt;Scripts, disk space, archives, scheduling&lt;/td&gt;
&lt;td&gt;Run a task reliably and restore a selected file from its backup&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;This is a learning sequence, not a fixed number of weeks. If you already edit files and understand permissions, try those checkpoints and begin where your explanation breaks down. If a later task exposes a gap, return to the relevant stage.&lt;/p&gt;

&lt;p&gt;The scope is consistent with established introductory curricula. &lt;a href="https://www.lpi.org/our-certifications/exam-010-objectives/" rel="noopener noreferrer"&gt;LPI Linux Essentials&lt;/a&gt; includes files, permissions, archives, recovery, and simple scripts. The Linux Foundation's &lt;a href="https://training.linuxfoundation.org/training/introduction-to-linux/" rel="noopener noreferrer"&gt;Introduction to Linux&lt;/a&gt; also covers processes, networking, Bash, and local security. Neither source establishes a universal learning order; the order here follows the dependencies of the practice tasks.&lt;/p&gt;

&lt;h2&gt;
  
  
  Choose an environment you can inspect
&lt;/h2&gt;

&lt;p&gt;Pick one Linux distribution for the main route. Ubuntu is a practical choice for following the package-management documentation linked below. Learn its conventions first, then compare another distribution when you have a reason to do so.&lt;/p&gt;

&lt;p&gt;A terminal is the interface you type into. A shell interprets your commands. The distribution supplies the operating-system environment and its package and configuration conventions. Open Bash for the examples in this article and inspect the environment:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;cat&lt;/span&gt; /etc/os-release
&lt;span class="nb"&gt;printf&lt;/span&gt; &lt;span class="s1"&gt;'%s\n'&lt;/span&gt; &lt;span class="s2"&gt;"&lt;/span&gt;&lt;span class="nv"&gt;$BASH_VERSION&lt;/span&gt;&lt;span class="s2"&gt;"&lt;/span&gt;
&lt;span class="nb"&gt;id
pwd&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Record the distribution, Bash version, current identity, and working directory. These details explain many differences between a tutorial and the system in front of you. A command that exists on one machine may need an additional package on another.&lt;/p&gt;

&lt;p&gt;On Windows, WSL is an option, including for some service-management practice. &lt;a href="https://learn.microsoft.com/en-us/windows/wsl/systemd/" rel="noopener noreferrer"&gt;Microsoft documents systemd support in WSL&lt;/a&gt;, with requirements and configuration that depend on the installation. Check the actual environment before assuming that a service command will work. For boot, disk, and recovery exercises, choose a disposable Linux VM that exposes the capabilities the exercise requires.&lt;/p&gt;

&lt;p&gt;Also distinguish a container from a complete VM. &lt;a href="https://docs.docker.com/get-started/docker-concepts/the-basics/what-is-a-container/" rel="noopener noreferrer"&gt;Docker describes containers as isolated processes sharing a kernel&lt;/a&gt;. A container shell can be useful for file and scripting work, but its presence does not establish that you can manage a full guest's boot process or services.&lt;/p&gt;

&lt;p&gt;If you want a structured starting point, the &lt;a href="https://labex.io/learn/linux" rel="noopener noreferrer"&gt;LabEx Linux path&lt;/a&gt; links to Linux courses and practice. &lt;a href="https://labex.io/courses/quick-start-with-linux" rel="noopener noreferrer"&gt;Quick Start with Linux&lt;/a&gt; is the short entry route; choose a lab environment appropriate to the task as you progress.&lt;/p&gt;

&lt;h2&gt;
  
  
  Navigate, edit, and check your changes
&lt;/h2&gt;

&lt;p&gt;Start with absolute and relative paths, hidden files, and the relationship between your current directory and a command's arguments. Practise finding help with &lt;code&gt;--help&lt;/code&gt; and &lt;code&gt;man&lt;/code&gt;. Learn enough of one editor to open, search, change, save, and exit a file.&lt;/p&gt;

&lt;p&gt;Build a small practice directory that you will reuse later. Run this once in a new Bash session; keep the terminal open for the subsequent examples. &lt;code&gt;mktemp&lt;/code&gt; creates a fresh directory rather than reusing an existing project:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nv"&gt;practice_dir&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="si"&gt;$(&lt;/span&gt;&lt;span class="nb"&gt;mktemp&lt;/span&gt; &lt;span class="nt"&gt;-d&lt;/span&gt;&lt;span class="si"&gt;)&lt;/span&gt;
&lt;span class="nb"&gt;cd&lt;/span&gt; &lt;span class="s2"&gt;"&lt;/span&gt;&lt;span class="nv"&gt;$practice_dir&lt;/span&gt;&lt;span class="s2"&gt;"&lt;/span&gt;
&lt;span class="nb"&gt;mkdir&lt;/span&gt; &lt;span class="nt"&gt;-p&lt;/span&gt; service/&lt;span class="o"&gt;{&lt;/span&gt;config,logs,backups&lt;span class="o"&gt;}&lt;/span&gt;
&lt;span class="nb"&gt;printf&lt;/span&gt; &lt;span class="s1"&gt;'port=8080\n'&lt;/span&gt; &lt;span class="o"&gt;&amp;gt;&lt;/span&gt; service/config/app.conf
&lt;span class="nb"&gt;cp &lt;/span&gt;service/config/app.conf service/config/app.conf.before
&lt;span class="nb"&gt;printf&lt;/span&gt; &lt;span class="s1"&gt;'%s\n'&lt;/span&gt; &lt;span class="s2"&gt;"&lt;/span&gt;&lt;span class="nv"&gt;$practice_dir&lt;/span&gt;&lt;span class="s2"&gt;"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The configuration is a practice fixture, not a configuration format for an installed server. Open &lt;code&gt;app.conf&lt;/code&gt; in your editor and change the port to &lt;code&gt;8081&lt;/code&gt;. Then inspect the difference:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;diff &lt;span class="nt"&gt;-u&lt;/span&gt; service/config/app.conf.before service/config/app.conf
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Explain which line changed and which file contains the original. A difference makes &lt;code&gt;diff&lt;/code&gt; return status 1; that is its way of reporting unequal inputs, not automatically a command failure.&lt;/p&gt;

&lt;p&gt;Your checkpoint is to locate this file from another working directory, edit a copy, and verify the result. If you cannot predict which path a command will touch, spend more time here before practising recursive operations.&lt;/p&gt;

&lt;p&gt;The &lt;a href="https://labex.io/courses/linux-for-noobs" rel="noopener noreferrer"&gt;Linux for Noobs course&lt;/a&gt; provides the main practice spine for this roadmap. Its public syllabus covers file operations and command help, then continues through permissions, text processing, processes, services, networking, scripting, and recovery. The exercises below are article examples, not reproductions of its lab instructions.&lt;/p&gt;

&lt;h2&gt;
  
  
  Understand which identity needs access
&lt;/h2&gt;

&lt;p&gt;Read &lt;code&gt;ls -l&lt;/code&gt; output in terms of owner, group, and everyone else. Then learn why directories have permission bits too. Directory search permission affects access through a path; reading a file involves more than the bits on that final file.&lt;/p&gt;

&lt;p&gt;In the practice directory, inspect both the file and its containing directory:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;id
ls&lt;/span&gt; &lt;span class="nt"&gt;-ld&lt;/span&gt; service service/config
&lt;span class="nb"&gt;ls&lt;/span&gt; &lt;span class="nt"&gt;-l&lt;/span&gt; service/config/app.conf
&lt;span class="nb"&gt;chmod &lt;/span&gt;600 service/config/app.conf
&lt;span class="nb"&gt;ls&lt;/span&gt; &lt;span class="nt"&gt;-l&lt;/span&gt; service/config/app.conf
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The mode change gives the owner read and write permission and removes the group's and others' mode permissions. This is an appropriate exercise for an owner-only file. It does not prove that the same mode would work for a service running as another user.&lt;/p&gt;

&lt;p&gt;That distinction is the checkpoint: state which identity needs access, choose ownership and permissions to match, and test as that identity in an administration lab. Also test the identity that should lack access. Reading the file as your own user proves only your own access. Later, ACLs and mandatory access controls can add further constraints beyond ordinary mode bits.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://labex.io/lesson/file-permissions" rel="noopener noreferrer"&gt;Linux Journey's file-permissions lesson&lt;/a&gt; is a useful companion when you need to decode the permission string. Keep returning to the opening service problem: which user is actually trying to read the configuration?&lt;/p&gt;

&lt;h2&gt;
  
  
  Turn output into a repeatable report
&lt;/h2&gt;

&lt;p&gt;Before learning long pipelines, understand standard output, standard error, and redirection. Learn a few filters well: &lt;code&gt;grep&lt;/code&gt; for selection, &lt;code&gt;cut&lt;/code&gt; or &lt;code&gt;awk&lt;/code&gt; for fields, and &lt;code&gt;sort&lt;/code&gt; with &lt;code&gt;uniq&lt;/code&gt; for grouping.&lt;/p&gt;

&lt;p&gt;Create a deliberately simple log fixture:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;printf&lt;/span&gt; &lt;span class="s1"&gt;'%s\n'&lt;/span&gt; &lt;span class="se"&gt;\&lt;/span&gt;
  &lt;span class="s1"&gt;'INFO started'&lt;/span&gt; &lt;span class="se"&gt;\&lt;/span&gt;
  &lt;span class="s1"&gt;'ERROR config-unreadable'&lt;/span&gt; &lt;span class="se"&gt;\&lt;/span&gt;
  &lt;span class="s1"&gt;'ERROR config-unreadable'&lt;/span&gt; &lt;span class="se"&gt;\&lt;/span&gt;
  &lt;span class="s1"&gt;'ERROR connection-refused'&lt;/span&gt; &lt;span class="o"&gt;&amp;gt;&lt;/span&gt; service/logs/app.log

&lt;span class="nb"&gt;awk&lt;/span&gt; &lt;span class="s1"&gt;'$1 == "ERROR" { print $2 }'&lt;/span&gt; service/logs/app.log |
  &lt;span class="nb"&gt;sort&lt;/span&gt; |
  &lt;span class="nb"&gt;uniq&lt;/span&gt; &lt;span class="nt"&gt;-c&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;For this fixture, the report should count two &lt;code&gt;config-unreadable&lt;/code&gt; events and one &lt;code&gt;connection-refused&lt;/code&gt; event. It relies on a specific input format: a severity followed by a single-word event. Real logs may use timestamps, quoted fields, JSON, or multiline records; inspect the format before choosing a parser.&lt;/p&gt;

&lt;p&gt;Save the report in a file, add another event, and regenerate it. Check that the new count matches the input. Then try a missing input file and observe the error separately from the report.&lt;/p&gt;

&lt;p&gt;Exit status becomes important here. In Bash, a pipeline normally reports the last command's status. With &lt;code&gt;pipefail&lt;/code&gt;, a failure earlier in the pipeline can affect that result. Consult the &lt;a href="https://www.gnu.org/software/bash/manual/html_node/Pipelines.html" rel="noopener noreferrer"&gt;Bash pipeline documentation&lt;/a&gt; before treating an empty output file as proof of success.&lt;/p&gt;

&lt;h2&gt;
  
  
  Inspect processes, packages, services, and logs
&lt;/h2&gt;

&lt;p&gt;Now move from prepared files to a running system. Learn to identify a process, its owner, its command, and its resource use. Practise process termination in an exercise with a known target, and distinguish that process from unrelated work.&lt;/p&gt;

&lt;p&gt;Use the distribution's package manager to install software and inspect what is installed. &lt;a href="https://ubuntu.com/server/docs/how-to/software/package-management/" rel="noopener noreferrer"&gt;Ubuntu's package-management guide&lt;/a&gt; explains APT and related tools. Treat that as Ubuntu-specific guidance; RPM-based systems have a different toolchain.&lt;/p&gt;

&lt;p&gt;A service manager adds another layer: it manages a program according to a unit's configuration and lifecycle rules. On a systemd-based practice VM, select a service supplied by the exercise and inspect its status, recent journal entries, and unit configuration. Learn the difference between starting it now and enabling it for future activation at boot. The &lt;a href="https://www.freedesktop.org/software/systemd/man/latest/systemctl.html" rel="noopener noreferrer"&gt;systemctl manual&lt;/a&gt; explicitly distinguishes enabling from starting.&lt;/p&gt;

&lt;p&gt;Do not make restart the whole troubleshooting procedure. A useful investigation records the failure, reads the relevant log entry, identifies a cause, changes one thing, and checks the result. A unit's active state is only one check; the application must also do its intended job.&lt;/p&gt;

&lt;p&gt;Use &lt;a href="https://labex.io/labs/linux-recover-a-failed-service-725413" rel="noopener noreferrer"&gt;Recover a Failed Service&lt;/a&gt; as a practice destination. The checkpoint is an explanation of the cause and evidence that the recovered service works. If the task includes persistence across reboot, verify that separately in an environment designed for it.&lt;/p&gt;

&lt;h2&gt;
  
  
  Trace a connection before changing the firewall
&lt;/h2&gt;

&lt;p&gt;A running process does not guarantee a reachable service. Learn enough addressing, routing, DNS, and ports to separate the layers. On a Linux system with the relevant tools installed, start with read-only inspection:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;ip addr
ip route
ss &lt;span class="nt"&gt;-ltn&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;These answer different questions: which addresses exist, where packets are routed, and which TCP sockets are listening. A loopback listener and a listener on an external interface have different reachability. A firewall is another boundary; opening a port cannot make a nonexistent listener appear.&lt;/p&gt;

&lt;p&gt;For a lab-provided HTTP service, first test the intended local address and port, then the intended remote path. Check hostname resolution when using a name. A successful local request does not prove remote connectivity, and a failed ping alone does not establish that HTTP is unavailable.&lt;/p&gt;

&lt;p&gt;Next learn SSH login, key-based authentication, and file transfer. &lt;a href="https://ubuntu.com/server/docs/how-to/security/openssh-server/" rel="noopener noreferrer"&gt;Ubuntu's OpenSSH guide&lt;/a&gt; provides the client/server context and configuration guidance. Keep a working session available when an exercise changes remote-access configuration, and verify a new connection before relying on the change.&lt;/p&gt;

&lt;p&gt;The checkpoint is to explain whether a failure concerns name resolution, routing, listening, filtering, or the application response. The course exercise &lt;a href="https://labex.io/labs/linux-correct-a-service-bind-address-725411" rel="noopener noreferrer"&gt;Correct a Service Bind Address&lt;/a&gt; gives this stage a bounded practice target.&lt;/p&gt;

&lt;h2&gt;
  
  
  Automate a task and prove you can recover
&lt;/h2&gt;

&lt;p&gt;Turn the log report into a Bash script only after you understand its commands. Give it an input-path argument, quote expansions, check missing or unreadable inputs, and return a nonzero status on failure. Practise conditions, loops, and functions as the task needs them; &lt;a href="https://labex.io/courses/shell-for-beginners" rel="noopener noreferrer"&gt;Shell for Beginners&lt;/a&gt; offers additional exercises in those areas.&lt;/p&gt;

&lt;p&gt;Test an ordinary path, a path containing spaces, an empty log, and a missing file. &lt;a href="https://www.shellcheck.net/wiki/SC2086" rel="noopener noreferrer"&gt;ShellCheck's quoting explanation&lt;/a&gt; shows why unquoted expansion can change arguments through word splitting and globbing. Use the checker alongside execution tests. If you use an AI assistant to suggest a script, apply the same tests and explain the changes before adopting it.&lt;/p&gt;

&lt;p&gt;Before scheduling backups, learn to inspect filesystem capacity with &lt;code&gt;df&lt;/code&gt; and directory usage with &lt;code&gt;du&lt;/code&gt;. Understand where the archive will be written and whether there is room for it. Partitions, LVM, and boot recovery can wait for a deeper administration track.&lt;/p&gt;

&lt;p&gt;Back in the same practice directory, create an archive and restore into a separate location:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;tar&lt;/span&gt; &lt;span class="nt"&gt;-czf&lt;/span&gt; service/backups/config.tar.gz &lt;span class="nt"&gt;-C&lt;/span&gt; service/config app.conf
&lt;span class="nb"&gt;tar&lt;/span&gt; &lt;span class="nt"&gt;-tzf&lt;/span&gt; service/backups/config.tar.gz
&lt;span class="nb"&gt;mkdir&lt;/span&gt; &lt;span class="nt"&gt;-p&lt;/span&gt; service/restore-check
&lt;span class="nb"&gt;tar&lt;/span&gt; &lt;span class="nt"&gt;-xzf&lt;/span&gt; service/backups/config.tar.gz &lt;span class="nt"&gt;-C&lt;/span&gt; service/restore-check
cmp service/config/app.conf service/restore-check/app.conf
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;For an unchanged source, &lt;code&gt;cmp&lt;/code&gt; should produce no output and return zero. That checks the recovered file's contents. It does not establish a complete backup policy, off-machine protection, or application recovery.&lt;/p&gt;

&lt;p&gt;Only then schedule the task using cron or, on an appropriate system, a systemd timer. Use explicit paths and capture failures: scheduled execution may not have the same working directory or environment as your interactive terminal. Verify an actual scheduled run, then restore a selected file. &lt;a href="https://labex.io/labs/linux-restore-a-configuration-from-backup-725409" rel="noopener noreferrer"&gt;Restore a Configuration from Backup&lt;/a&gt; is a focused next exercise.&lt;/p&gt;

&lt;h2&gt;
  
  
  Choose a direction after the core checkpoints
&lt;/h2&gt;

&lt;p&gt;The 2026 part of this roadmap is its checked environment and resource guidance, not a new set of Linux fundamentals. Course listings and platform defaults can change; use the documentation for the system you actually run.&lt;/p&gt;

&lt;p&gt;For development, continue into Git, language environments, and containers. Your knowledge of paths, users, processes, ports, and logs gives you specific questions to ask when a containerized application fails.&lt;/p&gt;

&lt;p&gt;For system administration, deepen storage, boot recovery, network configuration, and security policy. If you choose certification, map your skills against its current objectives. The &lt;a href="https://www.redhat.com/en/services/training/ex200-red-hat-certified-system-administrator-rhcsa-exam" rel="noopener noreferrer"&gt;RHCSA EX200 page&lt;/a&gt; currently specifies RHEL 10 and includes areas such as LVM and SELinux beyond this core route. This article is not an exam-coverage claim.&lt;/p&gt;

&lt;p&gt;For security, continue with service exposure, access boundaries, and privileged automation. &lt;a href="https://labex.io/courses/linux-security-for-devsecops" rel="noopener noreferrer"&gt;Linux Security for DevSecOps&lt;/a&gt; lists exercises in those areas. Learn to inspect the running system before attempting to harden it.&lt;/p&gt;

&lt;p&gt;Before branching out, complete one small maintenance exercise without step-by-step instructions. In a disposable service lab, recover a broken configuration, verify the service's response at its intended address, generate an error report, and restore a selected file from backup. Keep a short record of the evidence, your change, and the verification. If you can explain all three, you have a concrete basis for the next stage.&lt;/p&gt;

&lt;h2&gt;
  
  
  References
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;a href="https://labex.io/learn/linux" rel="noopener noreferrer"&gt;LabEx Linux learning path&lt;/a&gt; — course and practice entry points; linked course syllabi were checked on September 7, 2026.&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://www.lpi.org/our-certifications/exam-010-objectives/" rel="noopener noreferrer"&gt;LPI Linux Essentials objectives&lt;/a&gt; and &lt;a href="https://training.linuxfoundation.org/training/introduction-to-linux/" rel="noopener noreferrer"&gt;Linux Foundation Introduction to Linux&lt;/a&gt; — independent reference points for introductory scope.&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://learn.microsoft.com/en-us/windows/wsl/systemd/" rel="noopener noreferrer"&gt;Microsoft: systemd in WSL&lt;/a&gt; and &lt;a href="https://docs.docker.com/get-started/docker-concepts/the-basics/what-is-a-container/" rel="noopener noreferrer"&gt;Docker: containers and VMs&lt;/a&gt; — environment capabilities and boundaries.&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://www.gnu.org/software/bash/manual/html_node/Pipelines.html" rel="noopener noreferrer"&gt;GNU Bash pipelines&lt;/a&gt; and &lt;a href="https://www.freedesktop.org/software/systemd/man/latest/systemctl.html" rel="noopener noreferrer"&gt;systemctl&lt;/a&gt; — pipeline status and service-management semantics.&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://ubuntu.com/server/docs/how-to/software/package-management/" rel="noopener noreferrer"&gt;Ubuntu package management&lt;/a&gt; and &lt;a href="https://ubuntu.com/server/docs/how-to/security/openssh-server/" rel="noopener noreferrer"&gt;OpenSSH server&lt;/a&gt; — distribution-specific administration guidance.&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://www.shellcheck.net/wiki/SC2086" rel="noopener noreferrer"&gt;ShellCheck SC2086&lt;/a&gt; — word splitting, globbing, and quoting examples.&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://www.redhat.com/en/services/training/ex200-red-hat-certified-system-administrator-rhcsa-exam" rel="noopener noreferrer"&gt;Red Hat EX200 objectives&lt;/a&gt; — the boundary between this general route and RHEL certification preparation.&lt;/li&gt;
&lt;/ul&gt;

</description>
      <category>linux</category>
      <category>shell</category>
      <category>systemadministration</category>
    </item>
    <item>
      <title>Linux Journey, Rebuilt for Interactive Learning</title>
      <dc:creator>Labby</dc:creator>
      <pubDate>Tue, 01 Sep 2026 07:26:26 +0000</pubDate>
      <link>https://dev.to/labex/linux-journey-rebuilt-for-interactive-learning-4lmd</link>
      <guid>https://dev.to/labex/linux-journey-rebuilt-for-interactive-learning-4lmd</guid>
      <description>&lt;p&gt;The old Linux History page put almost everything on one screen: the lesson list on the left, the complete article in the middle, and exercises plus a quiz on the right. The material was available, but the learner had to decide how to move through it, where to pause, and whether one answer at the end was enough to check their understanding.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fw11goygt6j1zwbeqc3yc.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fw11goygt6j1zwbeqc3yc.png" alt="The previous Linux Journey lesson page with a sidebar, full article, exercises, and a quiz" width="800" height="560"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;The new Linux Journey starts one level earlier. A course page now shows the sequence of lessons, a short outcome for each lesson, and one place to start or resume the course.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fgdclfxxoqgtvga5pvw6e.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fgdclfxxoqgtvga5pvw6e.png" alt="The redesigned Getting Started course page with an ordered interactive syllabus" width="800" height="560"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;That visual redesign supports a more important change: Linux Journey is no longer organized only as a collection of pages to read. Each lesson now runs as a small learning sequence built around explanation, a decision, feedback, and continuation.&lt;/p&gt;

&lt;h2&gt;
  
  
  From a Syllabus to Learning Mode
&lt;/h2&gt;

&lt;p&gt;The redesigned &lt;a href="https://labex.io/linuxjourney/courses/getting-started" rel="noopener noreferrer"&gt;Getting Started course&lt;/a&gt; presents its 11 lessons as an ordered path. Each entry names the lesson and states what it covers, so a learner can see how Linux History leads into distribution choices and individual distribution guides before opening the first page.&lt;/p&gt;

&lt;p&gt;Selecting &lt;strong&gt;Start Course&lt;/strong&gt; opens the lesson in learning mode. Instead of displaying the entire page at once, the player begins with the first meaningful block and reveals the lesson step by step. A progress bar shows how far the learner has moved through the current lesson, while the &lt;strong&gt;Continue&lt;/strong&gt; button provides a clear next action.&lt;/p&gt;

&lt;p&gt;Course and lesson progress can be saved for signed-in learners. Signing in is not required to study the lessons; it is used to keep completion state available across devices.&lt;/p&gt;

&lt;h2&gt;
  
  
  Questions Become Part of the Explanation
&lt;/h2&gt;

&lt;p&gt;The previous Linux History quiz asked one recall question after the article: who developed the Linux kernel? In the revised lesson, checks appear immediately after the ideas they depend on.&lt;/p&gt;

&lt;p&gt;After the lesson explains that rewriting UNIX in C made it portable, for example, the learner chooses among three possible consequences. Selecting an option produces feedback for that specific choice. An incorrect answer explains the mismatch with the preceding material; the correct answer reinforces the portability principle. The lesson continues only after the learner identifies the correct answer.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F7cgiax15zyh0zskyystu.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F7cgiax15zyh0zskyystu.png" alt="The new Linux History learning mode showing lesson progress and immediate feedback on a contextual question" width="800" height="598"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;These questions are comprehension checks, not claims that a learner has mastered Linux administration. Their job is narrower: interrupt passive scrolling at a useful moment and make the learner apply the explanation that just appeared.&lt;/p&gt;

&lt;p&gt;The same player also provides a completion view with the lesson outcomes, a link to the next lesson, and a way to learn the lesson again. This turns the lesson boundary into part of the course flow instead of leaving navigation in a separate sidebar.&lt;/p&gt;

&lt;h2&gt;
  
  
  The Content Was Revised for the New Flow
&lt;/h2&gt;

&lt;p&gt;The interface could not create this experience by itself. The Linux Journey lessons were also migrated to a structure that the player can divide into meaningful steps.&lt;/p&gt;

&lt;p&gt;The revision preserved explanations, examples, images, and practice links when they were still accurate. It removed the old standalone exercise and quiz containers, moved useful material next to the topic it supports, and converted worthwhile questions into contextual single-choice checks. Each lesson now ends with a short summary of what the learner can explain or do.&lt;/p&gt;

&lt;p&gt;Across the current lesson collection, every lesson in all nine supported languages contains four or five of these checks. Each option includes feedback, and each question must be answerable from material taught earlier in the lesson. The structure is designed to test the current idea without requiring unstated Linux knowledge.&lt;/p&gt;

&lt;p&gt;The result is not a wholesale replacement of the original Linux Journey material. It is a new delivery structure for that material, with targeted revisions where a transition, explanation, or question needed to support the interactive sequence.&lt;/p&gt;

&lt;h2&gt;
  
  
  Still Free, Still Open
&lt;/h2&gt;

&lt;p&gt;The redesigned &lt;a href="https://labex.io/linuxjourney" rel="noopener noreferrer"&gt;Linux Journey&lt;/a&gt; remains free to use, with no payment or account required to read the lessons. Creating a free account is optional and enables saved learning progress.&lt;/p&gt;

&lt;p&gt;The lesson content also remains open source in the &lt;a href="https://github.com/labex-labs/linuxjourney" rel="noopener noreferrer"&gt;official Linux Journey repository&lt;/a&gt;. It is published under the CC BY-SA 4.0 license, and the repository continues to accept community contributions to lessons and translations.&lt;/p&gt;

&lt;p&gt;You can start with &lt;a href="https://labex.io/linuxjourney/courses/getting-started" rel="noopener noreferrer"&gt;Getting Started&lt;/a&gt;, or inspect and improve the source material on &lt;a href="https://github.com/labex-labs/linuxjourney" rel="noopener noreferrer"&gt;GitHub&lt;/a&gt;.&lt;/p&gt;

</description>
      <category>linux</category>
      <category>linuxjourney</category>
      <category>opensource</category>
      <category>interactivelearning</category>
    </item>
  </channel>
</rss>
