Accessing a Mac SSD with my Fedora Thinkpad

New Fedora user and basic Linux noob here. I have a Thinkpad T470 running the latest Fedora version. (I can’t figure out where to find it now, but I JUST loaded it two days ago.) I have an SSD hard drive I took out of a ‘bad’ Mac. I plugged it into one of the USB-C ports on the Thinkpad using the appropriate cable. The machine recognizes the drive and using the “Drives” function, I can “see” it. I’ve attached a screenshot of what the “Drive” function provides re the Mac SSD.

Can someone tell me how I can access the contents of this drive? I need to get the ‘stuff’ off of it and onto the Thinkpad before I wipe the Mac SSD.

Thanks in advance,
Paul

Does this help? https://www.baeldung.com/linux/apfs-partition-mount
(I don’t have a Mac to play with so untested by me.)

apfs-fuse has “worked for me” in the past. Fedora has:

% dnf5 info apfs-fuse        
Updating and loading repositories:
Repositories loaded.
Available packages
Name           : apfs-fuse
Epoch          : 0
Version        : 0
Release        : 22.20200928gitee71aa5.fc38
Architecture   : x86_64
Download size  : 270.4 KiB
Installed size : 1.4 MiB
Source         : apfs-fuse-0-22.20200928gitee71aa5.fc38.src.rpm
Repository     : fedora
Summary        : A read-only FUSE driver for Apple's APFS
URL            : https://github.com/sgan81/apfs-fuse
License        : GPLv2+
Description    : apfs-fuse is a read-only driver for the new Apple File System, APFS. Since
               : Apple didn't document the disk format, this driver should be considered
               : experimental. Not all compression methods are supported yet, thus the driver
               : may return compressed files instead of uncompressed ones.
Vendor         : Fedora Project

Thank you for your replies! I’ll give that a shot. Regardless of how it turns out I’ll report the results in this thread.

Paul

A suggestion, not advice. Would this work on Fedora, just replacing apt with dnf in the commands?

I haven’t yet tried the process explained in the above video, but I intend to. It looks promising. Thanks!

Paul

PS - Just tried it. Repeatedly got “apt: command not found”.
(Remember, I am a COMPLETE novice WRT Linux.) If I enter “apt” at the command line, I get “apt: command not found”. So… What am I doing wrong?

Paul

I haven’t watched the video in full, but it looks like it’s specifically for Ubuntu, not Linux in general. Fedora uses a package manager called dnf, Ubuntu uses one called apt, and the commands aren’t compatible.

It looks like the apfs-fuse package they are talking about is in the Fedora repo, like gnwii mentions above. To install it, all it takes is typing

dnf install apfs-fuse

at the command line (actually, start the command with sudo, so sudo dnf install apfs-fuse ) It will ask for your password, and the cursor won’t move while you type it; just type your password and hit enter.

That will at least get it installed. I can’t help you use it beyond that.

1 Like

You are following a video that was based on ubuntu which uses apt for the package management.
Fedora uses dnf for package management.
You would need to use the proper command, as well as make sure the proper package name is used. Ubuntu and fedora do not always use the same package names, though they are usually similar.

As mentioned, the package name that may be what is required is apfs-fuse, so the command given above might solve the issue for installing that package.

1 Like

Thanks!

Paul

So here’s the next iteration:

$ sudo dnf install apfs- fuse
[sudo] password for :
Fedora 38 - x86_64 - Updates 2.2 kB/s | 23 kB 00:10
Fedora 38 - x86_64 - Updates 672 kB/s | 2.9 MB 00:04
Fedora Modular 38 - x86_64 - Updates 43 kB/s | 25 kB 00:00
No match for argument: apfs-
Package fuse-2.9.9-16.fc38.x86_64 is already installed.
Error: Unable to find a match: apfs-
$ sudo libfuse-dev libicu-dev bzip2 libbz2-dev cmake clang git libattr1-dev
sudo: libfuse-dev: command not found
$ libfuse
bash: libfuse: command not found…
$ libicu
bash: libicu: command not found…
$ bzip2
bzip2: I won’t write compressed data to a terminal.
bzip2: For help, type: `bzip2 --help’.
$ bzip2 --help
bzip2, a block-sorting file compressor. Version 1.0.8, 13-Jul-2019.

usage: bzip2 [flags and input files in any order]

-h --help print this message
-d --decompress force decompression
-z --compress force compression
-k --keep keep (don’t delete) input files
-f --force overwrite existing output files
-t --test test compressed file integrity
-c --stdout output to standard out
-q --quiet suppress noncritical error messages
-v --verbose be verbose (a 2nd -v gives more)
-L --license display software version & license
-V --version display software version & license
-s --small use less memory (at most 2500k)
-1 … -9 set block size to 100k … 900k
–fast alias for -1
–best alias for -9

If invoked as bzip2', default action is to compress. as bunzip2’, default action is to decompress.
as `bzcat’, default action is to decompress to stdout.

If no file names are given, bzip2 compresses or decompresses
from standard input to standard output. You can combine
short flags, so `-v -4’ means the same as -v4 or -4v, &c.

$ fuse
bash: fuse: command not found…
Install package ‘fuse-emulator’ to provide command ‘fuse’? [N/y] y

  • Waiting in queue…

  • Loading list of packages…
    The following packages have to be installed:
    adwaita-gtk2-theme-3.28-16.fc38.x86_64 Adwaita gtk2 theme
    audiofile-1:0.3.6-33.fc38.x86_64 Library for accessing various audio file formats
    fuse-emulator-1.6.0-5.fc38.x86_64 The Free UNIX Spectrum Emulator
    gtk2-2.24.33-13.fc38.x86_64 GTK+ graphical user interface library
    ibus-gtk2-1.5.28-6.fc38.x86_64 IBus IM module for GTK2
    libcanberra-gtk2-0.30-31.fc38.x86_64 Gtk+ 2.x Bindings for libcanberra
    libspectrum-1.5.0-5.fc38.x86_64 A library for reading spectrum emulator file formats
    sdl12-compat-1.2.68-1.fc38.x86_64 SDL 1.2 runtime compatibility library using SDL 2.0
    Proceed with changes? [N/y] y

  • Waiting in queue…

  • Waiting for authentication…

  • Waiting in queue…

  • Downloading packages…

  • Requesting data…

  • Testing changes…

  • Installing packages…

The Free Unix Spectrum Emulator (Fuse) version 1.6.0.
(c) 1999-2021 Philip Kendall and others; see the file
‘AUTHORS’ for more details.

For help, please mail fuse-emulator-devel@lists.sf.net or use
the forums at http://sourceforge.net/p/fuse-emulator/discussion/.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.

(fuse:18815): Gtk-WARNING **: 19:28:18.562: Unable to locate theme engine in module_path: “hcengine”,
Gtk-Message: 19:28:18.564: Failed to load module “pk-gtk-module”
fuse: error: couldn’t find ROM ‘48.rom’
fuse: error initialising – giving up!

And “giving up” is exactly what I’m going to do with this (the video solution). I think I’m just going to find someone with an Apple computer.

Paul

That should have been apfs-fuse. The space caused the error which prevented the download and install of the package.

Let me try and repeat/translate everything the video told you to do but stated for fedora instead of for ubuntu.

  1. sudo dnf upgrade
  2. sudo dnf install apfs-fuse
    Since there is no need to compile apfs-fuse the remaining packages shown in that video are not required.
  3. Once step 2 has been completed then connect the mac (apfs) drive and wait for the system to identify it. I think it should be auto-mounted and a notification may be seen at the top center of your screen to confirm that.
  4. Open up the file manager and the device should show just as attaching any usb device normally shows. Once that is done simply copy the data from the mac drive to your other drive as desired.

The device was obviously seen as stated in your very first post, but was not accessible due to not having the apfs-fuse package installed first.

If the device does not auto-mount then please let us know exactly what occurs and we can work from that point.

Typo: apfs-fuse (no space after the -).

To install these you need to add dnf install after the sudo.

Thanks for the clarifications! I really do appreciate your collective patience.

I’ll probably give it one more try, but if that fails as catastrophically, (even if it IS Operator Error), I’m just going to find someone with a Mac.

This ‘conflagration’ is clearly a function of my ignorance of Linux. Nevertheless, I don’t think I want to continue to use this exercise to get educated. I’d rather learn on a more pedestrian pace with less risky potential.

I’m committed to Linux because my feelings toward MS and Apple, (borne of decades of putting up with their abuses), are too strong. I’m less concerned about Linux becoming a Beast because it doesn’t have the basic corrupt foundation to become what MS and Apple are. I’ll get Linux figured out, (to my level of need), sooner or later.

Thanks again,
Paul

1 Like

Sure, and thanks for your patience with us. :slight_smile:

I think I wasn’t quite clear enough above with my attempt at help: that video is really leading you down a long and wrong path. The first problem, we pointed out, is that it’s for Ubuntu, and it’s giving commands that specifically deal with Ubuntu’s package manager.

The second problem is the video is trying to lead you to compile a package from source code, and is instructing you to get a bunch of additional packages that don’t apply to what you want to do.

It looks like apfs-fuse is already in the Fedora repository, already compiled and configured for you, ready to go. Just copy and paste sudo dnf install apfs-fuse to your command line (no space within apfs-fuse). After it asks for your password, it should install the package, and that’s that. Plug in your drive, and see if you can mount and read it. I think @computersavvy explains it pretty well above.

Amen brother. Couldn’t have put it better myself, as good, but not better. :smiley:

I know I said I’d quit if it didn’t work, but… :smiling_imp:

fuse is installed, and I can mount the small (210MB) partition, However, I’m getting the following error message when I “run” the larger 750GB partition:

$ apfs-fuse /dev/sdb2 /run/media/paulskvorc
Opening device /dev/sdb2 failed with error Permission denied
Error opening device!
$ apfs-fuse /dev/sdb2 /run/media/paulskvorc/xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Opening device /dev/sdb2 failed with error Permission denied
Error opening device!

I seem to be close. Could the problem be because the SSD was “encrypted” on a Mac? If so, I know the password to start the Mac, but I don’t get a prompt to enter it.

Paul

Ok, we’re really having fun now, aren’t we? :slight_smile:

(say “yes”, lol)

For “permission denied” things, often it’s because you’re trying to do something as a user, but you need root permissions to accomplish. The easiest way is to use that magic word “sudo” that we were having you type earlier. So sudo apfs-fuse and the rest of the command you tried.

Other than that, you may have to make sure the mount point you’re trying to use exists (maybe someone can correct me if I’m wrong here). Whatever directory you’re trying to mount it at needs to already be a thing. Say you want to mount it at /run/media/paulskvorc/mac_disk, create the directory from the command line with sudo mkdir /run/media/paulskvorc/mac_disk

Notice the “sudo” again, because as a regular user, you don’t own the stuff in the /run/media/ directory. You could probably even just use the file browser and make a new folder in your home directory without using the command line or sudo, and mount it there if you wanted.

Finish with sudo apfs-fuse /dev/sdb2 /run/media/paulskvorc/mac_disk or sudo apfs-fuse /dev/sdb2 ~/mac_disk or whever you chose to put the empty directory. ( " ~/ " is just shorthand for your home directory on the command line.)

I hope we’re getting closer, ha. I want to see the end of this movie.

y :wink:

Sounds plausible, I’ll give it a try.

Thanks,
Paul

Looks close, but "Nos such file or directory, which has to be referring to “sbd2”. I know that was there ‘once’. Not sure it was there when I reopened computer and plugged in Mac SSD. However, the machine clearly ‘sees’ the Mac SSD.

Paul

To clarify, /run/media/paulskvorc/mac_disk and ~/mac_disk are two different choices you could use, one OR the other. You have to make the same choice for both creating the directory and mounting the disk. If you want to sudo apfs-fuse /dev/sdb2 ~/mac_disk like you do here, you must first mkdir ~/mac_disk not the other one.