{"id":2995,"date":"2019-08-12T10:35:53","date_gmt":"2019-08-12T10:35:53","guid":{"rendered":"http:\/\/blog.designed79.co.uk\/?p=2995"},"modified":"2019-08-12T10:35:53","modified_gmt":"2019-08-12T10:35:53","slug":"mount-a-raspberry-pi-sd-card-on-a-mac-read-only-with-osxfuse-and-ext4fuse","status":"publish","type":"post","link":"https:\/\/blog.designed79.co.uk\/?p=2995","title":{"rendered":"Mount a Raspberry Pi SD card on a Mac (read-only) with osxfuse and ext4fuse"},"content":{"rendered":"<ol>\n<li>Plug the microSD card into a card reader connected to your Mac. The\n<div class=\"codecolorer-container text default\" style=\"overflow:auto;white-space:nowrap;\"><div class=\"text codecolorer\">boot<\/div><\/div>\n<p>volume will be automatically mounted, but it doesn&#8217;t contain all the files from the Pi&#8217;s primary filesystem.<\/li>\n<li>Make sure you have <a href=\"https:\/\/brew.sh\/\">Homebrew<\/a> installed (instructions <a href=\"https:\/\/brew.sh\/\">here<\/a>), so you can install the tools you need to mount the filesystem.<\/li>\n<li>Using Homebrew, install osxfuse and ext4fuse (find out more about the tools on the <a href=\"https:\/\/osxfuse.github.io\/\">FUSE for macOS<\/a> website):\n<ol>\n<li>\n<div class=\"codecolorer-container text default\" style=\"overflow:auto;white-space:nowrap;\"><div class=\"text codecolorer\">brew cask install osxfuse<\/div><\/div>\n<\/li>\n<li>\n<div class=\"codecolorer-container text default\" style=\"overflow:auto;white-space:nowrap;\"><div class=\"text codecolorer\">brew install ext4fuse<\/div><\/div>\n<\/li>\n<\/ol>\n<\/li>\n<li>Use Disk Utility on the command line to find the Raspberry Pi&#8217;s partition ID; run\n<div class=\"codecolorer-container text default\" style=\"overflow:auto;white-space:nowrap;\"><div class=\"text codecolorer\">diskutil list<\/div><\/div>\n<p>to get output like below:<\/p>\n<pre>\n\n<div class=\"codecolorer-container text default\" style=\"overflow:auto;white-space:nowrap;\"><div class=\"text codecolorer\">$ diskutil list<br \/>\n\/dev\/disk0 (internal):<br \/>\n&nbsp; &nbsp;#: &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; TYPE NAME &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;SIZE &nbsp; &nbsp; &nbsp; IDENTIFIER<br \/>\n&nbsp; &nbsp;0: &nbsp; &nbsp; &nbsp;GUID_partition_scheme &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 500.3 GB &nbsp; disk0<br \/>\n&nbsp; &nbsp;1: &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;EFI EFI &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 314.6 MB &nbsp; disk0s1<br \/>\n&nbsp; &nbsp;2: &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;Apple_HFS Macintosh HD &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;499.3 GB &nbsp; disk0s2<br \/>\n&nbsp; &nbsp;3: &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; Apple_Boot Recovery HD &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 650.0 MB &nbsp; disk0s3<br \/>\n<br \/>\n\/dev\/disk2 (external, physical):<br \/>\n&nbsp; &nbsp;#: &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; TYPE NAME &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;SIZE &nbsp; &nbsp; &nbsp; IDENTIFIER<br \/>\n&nbsp; &nbsp;0: &nbsp; &nbsp; FDisk_partition_scheme &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;*32.0 GB &nbsp; &nbsp;disk4<br \/>\n&nbsp; &nbsp;1: &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; Windows_FAT_32 boot &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;66.1 MB &nbsp; &nbsp;disk4s1<br \/>\n&nbsp; &nbsp;2: &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;Linux &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 31.9 GB &nbsp; &nbsp;disk4s2<\/div><\/div>\n\n<\/pre>\n<p>You should be able to tell which drive is your Pi drive by the description (<\/p>\n<div class=\"codecolorer-container text default\" style=\"overflow:auto;white-space:nowrap;\"><div class=\"text codecolorer\">external, physical<\/div><\/div>\n<p>), the &#8216;Linux&#8217; partition type, and the size of the disk (e.g.<\/p>\n<div class=\"codecolorer-container text default\" style=\"overflow:auto;white-space:nowrap;\"><div class=\"text codecolorer\">31.9 GB<\/div><\/div>\n<p>for my 32 GB card). The ID is the<\/p>\n<div class=\"codecolorer-container text default\" style=\"overflow:auto;white-space:nowrap;\"><div class=\"text codecolorer\">disk4s2<\/div><\/div>\n<p>in my case, in the<\/p>\n<div class=\"codecolorer-container text default\" style=\"overflow:auto;white-space:nowrap;\"><div class=\"text codecolorer\">IDENTIFIER<\/div><\/div>\n<p>column.<\/li>\n<li>Create a &#8216;mount point&#8217;\u2014a folder on your Mac where you will &#8216;mount&#8217; the Linux partition so you can read data from it:\n<div class=\"codecolorer-container text default\" style=\"overflow:auto;white-space:nowrap;\"><div class=\"text codecolorer\">sudo mkdir \/Volumes\/rpi<\/div><\/div>\n<p>(<\/p>\n<div class=\"codecolorer-container text default\" style=\"overflow:auto;white-space:nowrap;\"><div class=\"text codecolorer\">sudo<\/div><\/div>\n<p>requires you to enter your Mac account&#8217;s admin password, since it performs actions with elevated privileges\u2014enter your password when prompted.)<\/li>\n<li>Mount the drive using\n<div class=\"codecolorer-container text default\" style=\"overflow:auto;white-space:nowrap;\"><div class=\"text codecolorer\">ext4fuse<\/div><\/div>\n<p>:<\/p>\n<div class=\"codecolorer-container text default\" style=\"overflow:auto;white-space:nowrap;\"><div class=\"text codecolorer\">sudo ext4fuse \/dev\/disk2s2 \/Volumes\/rpi -o allow_other<\/div><\/div>\n<\/li>\n<\/ol>\n<blockquote><p>The<\/p>\n<div class=\"codecolorer-container text default\" style=\"overflow:auto;white-space:nowrap;\"><div class=\"text codecolorer\">-o allow_other<\/div><\/div>\n<p>is required to make sure the mounted disk is readable by everyone (and not just the<\/p>\n<div class=\"codecolorer-container text default\" style=\"overflow:auto;white-space:nowrap;\"><div class=\"text codecolorer\">sudo<\/div><\/div>\n<p>\/<\/p>\n<div class=\"codecolorer-container text default\" style=\"overflow:auto;white-space:nowrap;\"><div class=\"text codecolorer\">root<\/div><\/div>\n<p>user). See this issue: <a href=\"https:\/\/github.com\/gerard\/ext4fuse\/issues\/36\">Unable to open ext4 mounted partition on El Captain<\/a>.<\/p><\/blockquote>\n<p>Now you&#8217;ll see the<\/p>\n<div class=\"codecolorer-container text default\" style=\"overflow:auto;white-space:nowrap;\"><div class=\"text codecolorer\">rpi<\/div><\/div>\n<p>volume mounted in the Finder. You can open it and read from it just like any other disk, card, or flash drive you connect to your Mac.<\/p>\n<p>Once you&#8217;re finished, make sure you safely unmount the disk, by either ejecting the disk in the finder, or running<\/p>\n<div class=\"codecolorer-container text default\" style=\"overflow:auto;white-space:nowrap;\"><div class=\"text codecolorer\">sudo umount \/Volumes\/rpi<\/div><\/div>\n<p>in Terminal. After that, you can unplug the card and put it back in your Pi, where it will be ready to do more awesome Pi things!<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Plug the microSD card into a card reader connected to your Mac. The boot volume will be automatically mounted, but it doesn&#8217;t [&hellip;]<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-2995","post","type-post","status-publish","format-standard","hentry","category-info-on-tech"],"_links":{"self":[{"href":"https:\/\/blog.designed79.co.uk\/index.php?rest_route=\/wp\/v2\/posts\/2995","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/blog.designed79.co.uk\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blog.designed79.co.uk\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blog.designed79.co.uk\/index.php?rest_route=\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/blog.designed79.co.uk\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=2995"}],"version-history":[{"count":0,"href":"https:\/\/blog.designed79.co.uk\/index.php?rest_route=\/wp\/v2\/posts\/2995\/revisions"}],"wp:attachment":[{"href":"https:\/\/blog.designed79.co.uk\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=2995"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blog.designed79.co.uk\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=2995"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blog.designed79.co.uk\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=2995"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}