<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:content="http://purl.org/rss/1.0/modules/content/">
  <channel>
    <title>Dd on Kenno&#39;s Open Note</title>
    <link>https://blog.khmersite.net/tags/dd/</link>
    <description>Recent content in Dd on Kenno&#39;s Open Note</description>
    <image>
      <title>Kenno&#39;s Open Note</title>
      <url>https://blog.khmersite.net/%3Clink%20or%20path%20of%20image%20for%20opengraph,%20twitter-cards%3E</url>
      <link>https://blog.khmersite.net/%3Clink%20or%20path%20of%20image%20for%20opengraph,%20twitter-cards%3E</link>
    </image>
    <generator>Hugo -- 0.154.0</generator>
    <language>en</language>
    <lastBuildDate>Sat, 19 Mar 2022 21:00:58 +1100</lastBuildDate>
    <atom:link href="https://blog.khmersite.net/tags/dd/index.xml" rel="self" type="application/rss+xml" />
    <item>
      <title>Create a Disk Image With dd Command</title>
      <link>https://blog.khmersite.net/p/create-disk-image-with-dd/</link>
      <pubDate>Sat, 19 Mar 2022 21:00:58 +1100</pubDate>
      <guid>https://blog.khmersite.net/p/create-disk-image-with-dd/</guid>
      <description>&lt;h2 id=&#34;situation&#34;&gt;Situation:&lt;/h2&gt;
&lt;p&gt;I want to re-use an external drive which already contains some data. So I will create a disk image on an external drive in case I need to copy that image back to the drive in the future.&lt;/p&gt;
&lt;h2 id=&#34;solution&#34;&gt;Solution:&lt;/h2&gt;
&lt;p&gt;Normally, I just run &lt;code&gt;dd&lt;/code&gt; to create an &lt;code&gt;file.img&lt;/code&gt; when the disk is small, e.g. SD card. However, the drive capacity is 512GB. So a better option is to compress the image. Here is how this can be done:&lt;/p&gt;</description>
    </item>
    <item>
      <title>Create a FreeBSD install disk with dd on OS X</title>
      <link>https://blog.khmersite.net/p/create-a-freebsd-install-disk-with-dd-on-os-x/</link>
      <pubDate>Fri, 09 Feb 2018 22:23:20 +0000</pubDate>
      <guid>https://blog.khmersite.net/p/create-a-freebsd-install-disk-with-dd-on-os-x/</guid>
      <description>&lt;p&gt;I need to create a bootable FreeBSD install disk and the downloaded file happened to be on a Mac laptop. Since OS X is based on BSD, it also comes with &lt;code&gt;dd&lt;/code&gt; utility.&lt;/p&gt;
&lt;p&gt;After a USB is inserted, I need to identify the disk. This can be done using &lt;code&gt;diskutil&lt;/code&gt; command:&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;$ sudo diskutil list
/dev/disk0 (internal):
   #:                       TYPE NAME                    SIZE       IDENTIFIER
   0:      GUID_partition_scheme                         251.0 GB   disk0
   1:                        EFI EFI                     314.6 MB   disk0s1
   2:                 Apple_APFS Container disk1         250.7 GB   disk0s2
/dev/disk1 (synthesized):
   #:                       TYPE NAME                    SIZE       IDENTIFIER
   0:      APFS Container Scheme -                      +250.7 GB   disk1
                                 Physical Store disk0s2
   1:                APFS Volume Macintosh HD            98.6 GB    disk1s1
   2:                APFS Volume Preboot                 21.4 MB    disk1s2
   3:                APFS Volume Recovery                509.8 MB   disk1s3
   4:                APFS Volume VM                      3.2 GB     disk1s4
/dev/disk2 (external, physical):
   #:                       TYPE NAME                    SIZE       IDENTIFIER
   0:     Apple_partition_scheme                        *2.1 GB     disk2
   1:        Apple_partition_map                         4.1 KB     disk2s1
   2:                  Apple_HFS                         2.4 MB     disk2s2
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;From the above output, the USB drive is &lt;code&gt;/dev/disk2&lt;/code&gt;. Now, I can use &lt;code&gt;dd&lt;/code&gt; to copy the image file to the USB drive using the following command:&lt;/p&gt;</description>
    </item>
    <item>
      <title>Create bootable USB Fedora 24</title>
      <link>https://blog.khmersite.net/p/create-bootable-usb-fedora-24/</link>
      <pubDate>Mon, 27 Jun 2016 10:21:29 +0000</pubDate>
      <guid>https://blog.khmersite.net/p/create-bootable-usb-fedora-24/</guid>
      <description>&lt;p&gt;Every time there is a new release of Linux distro, I need to create a bootable USB. And, I forgot how I did it last time. So, I tried by using the &amp;ldquo;Startup Disk Creator&amp;rdquo; program installed on my Ubuntu workstation, only to find out that it didn&amp;rsquo;t even work.&lt;/p&gt;
&lt;p&gt;After a while I remember, it was just a matter of using &lt;code&gt;dd&lt;/code&gt; command to copy the ISO image to the USB.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Copy RaspBSD image to micro SD card</title>
      <link>https://blog.khmersite.net/p/copy-raspbsd-image-to-micro-sd-card/</link>
      <pubDate>Wed, 02 Dec 2015 22:30:33 +0000</pubDate>
      <guid>https://blog.khmersite.net/p/copy-raspbsd-image-to-micro-sd-card/</guid>
      <description>&lt;p&gt;The RaspBSD image for Raspberry Pi can be found at &lt;a href=&#34;http://raspbsd.org/raspberrypi.html&#34;&gt;http://raspbsd.org/raspberrypi.html&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;After it’s been downloaded, we need to copy it to a microSD card. Before we can do that, we need to find out the device name represents the microSD card. One way to find out is to plug the card in, and check the newest messages of &lt;strong&gt;dmesg&lt;/strong&gt;.&lt;/p&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;$ dmesg
...
[282430.689656] mmc0: new SDHC card at address aaaa
[282430.691039] mmcblk0: mmc0:aaaa SU08G 7.40 GiB 
[282430.711060] mmcblk0: p1 p2
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;In my case, using Ubuntu 15.10, the card is detected as &lt;strong&gt;mmcblk0&lt;/strong&gt;.&lt;/p&gt;</description>
    </item>
  </channel>
</rss>
