 Hello and welcome, today we're going to be looking at these three different phones. I got a Motorola G 2014 model, a Nexus 5X and a Motorola X4, 4X, and I really should look it up because I can never remember which one that is, but we're going to be looking at them and we're going to be looking at their partitions and how to figure out on the internal memory which partition is which, which is your boot loader, which is your boot image that has your kernel and your initial RAM disk, your system, your cache, your user data, how to figure out which partition is which on each of these devices. So let's go ahead, we're going to plug them in one at a time. Again, these videos are not for beginners. I assume that you already know how to unlock your boot loader and how to get a customer recovery right on there. We're going to get TWRP, which I believe is team win recovery partition, already booted on each one of these. If I turn one on, you can see that I already have that up and running on them. So we're just going to ADB into it and start looking at the system and the partition. So let's go ahead and get started on that. Okay, we're going to go in the order from oldest to newest. So I now have hooked up my Motorola G 2014 phone and it is named Titan and I'm just going to ADB. It's plugged in. I have the customer recovery going on there. So now we are at the root prompt in the customer recovery. If I list, you can see we're in the root directory. So again, we are going to be looking at the internal storage and trying to figure out which partition is which now on a regular Linux system, you would look in dev and you know that your hard drive is usually going to be an SD A or SD B with partitions would be SDB A, you know, one or two. And that's for say the drives. If you have an older system with ID connections, they should be labeled HDA, but this is an internal memory. So it's actually going to be looking for block devices to start with MMC, which is multimedia control block device. If we list in here, we do not see those so I can do and then here you don't see them. But if we were to look into a sub directory of blocks, so we have dev block, we can now list and we can see that we have a few of these devices or one device. So MMC block zero would be the internal memory, the embedded device itself, the embedded hard drive. And then we have P one and all these numbers for the different partitions and there's close to 40 of them up to 38. So again, what are all these partitions on there? And how do we figure that? Well, there is a sub folder in here called boot device. So let's go ahead and move into that. So currently we are in dev block device and then we went into boot devices which actually pointed to platform, this MSM, blah, blah, blah. But that's just a symbolic link. So remember device block boot device and now we can list here. We can see again that internal memory listed and if we list this out in a list format, you can see that these are just symbolic links. That's what this means right here. It's linking to this block device. So the main place the block device is found is under device block. But then we can move into the platform here. And again, now if we move into another folder called by name, they are going to list them by name. And I can list out all these and you can see that we have a boot and a boot which there are differences between that C logo. We have our system. We have we should have user data somewhere right there user data and cash. But again, these are the labels or the names of those partitions, which is which wealth we can list out with a long list. So dash L here, we can now see where they're pointing. So we can see our recovery partition is actually pointing to the first block device partition 32. We can see that the logo is pointing to partition 27. We can see system, our system partition, which is our main operating system is on partition 36. Our user data where all our personal information is stored, our photos, our settings for our applications, the applications we've installed are all on partition 38. And so you can go through all these if we were to, let's see if more is installed. Yes, so I can go through this partly. And we can see that our boot partition is partition 31. Our cash partition, which is like a temporary file for pulling stuff on applications you've run recently is under partition 35. So now we know if we want to back up one of these partitions, which we will look at in the future video, we know on this device, which partition is which. And we can go through each one of these and pull them. I'm going to go ahead and exit out of that device. I'm now going to unplug it. And I'll plug in the next device, which is the Nexus 5x bull head. So I'll ADB into that. Let me clear the screen here. And again, I will list and we can again, I'll CD into dev block. I'll type B and tab complete boot device. And I will now buy name. And I'm in this directory for here. And again, you can see that once I go in there, it actually redirects me somewhere else because they're using symbolic links. So this particular directory may change on between the two devices, but using the symbolic links, we got to where we need to be. Although I leave on the next phone, it is a little different, but still very easy to find. And again, we can see a list of all the partitions on that device. And if we were to do a long list of them, we can see again, which is which. And this one, your user data is on partition 45. Your vendor partition, which is where when a vendor, you know, in this case, you know, we're looking at some Motorola phones and this is the Nexus phone. The vendor for that phone will put their custom applications and stuff most likely on this partition, which in this case is partition 39. We can see again, there's lots you got partitions that have settings for the modem on the device, your recovery on this one is 38. So again, the partitions might change from device to device, but you can very easily find, okay, this is my system partition. I know what it's pointing to. I can now back up that partition manually if I want and pull it to my machine to look through it, maybe make modifications, or I can make modifications on the phone and then flash that back over if I made it back up. So that was on the Nexus 5x. Let's exit out of that. I will now plug in the Motorola X4. I will ADB into that again, clear the screen. We'll let me clear the screen once I've gotten into that. I'll just do this. Okay, anyway, CD dev again block boot devices by name. I guess it was the same. For some reason, I thought one of the devices was a little different, but again, I can list out here. I can see all the partitions for this and if I was to do more, I can go through them. Now on this device, this is a newer device. You can see that we have a boot partition and then we also have a boot A and a boot B. Okay, and they are different partitions. So boot A is at 44 and boot B is at 45. If we go down, we can also see the same for system. There's going to be a system A and a system B, which are different partitions, partitions 65 and 66. But if you look at just your system partition, you can see it right now it's pointing to system A and boot is probably pointing to boot A. So why do you have a system A and a system B or a vendor B and a vendor A and you have these multi partitions? They do that to help prevent your system from crashing on updates. So basically, when your system pulls down an update, it's going to your system right now in this case is running on system A. It's going to download the update to partition system B and then try to boot to that. If it fails to boot, like the update was corrupted, it will flip back to system A without breaking your system, in which case you can try the update again and hopefully it would work. So on these newer phones, it's going to take up more space on your device, but they are going to have two partitions for all those things to prevent your device from getting bricked on an update is basically what it's for. But the system's booting is always looking for system and then it knows which partition to so system says, okay, look at in this case system A, it goes to system A, system A says look at this partition and that's what it's going to boot from. And when it does the update, it will swap this. Now, when you're in the recovery, in this case, the TWRP, when you go to reboot, there's usually an option down at the bottom whether you want to boot to slot A or slot B, and that's what it's talking about. And if one fails, you can hopefully switch back to the other. So there's a bit of security there in that your system hopefully won't be bricked on a failed modification of the system. So that's why you have a lot more partitions with A's and B's on some of these newer devices. And that's fairly common these days. So again, on these devices, let me just exit out of there, clear the screen and go back in to find which partition is which on an Android device you will CD into dev. And if you're familiar with Linux systems or Unix systems or Unix like systems, you know that dev is where your devices are. And in a Unix or Unix like system such as Linux, which is what Android is, you are going to have all your hardware are basically files. So you can point to any of these files and read them like a file. So if I was to come in here and I was to go to block device boot device by name, and I can now if I want to I can cat out something like I'll do because it's pretty small the logo just logo. Or maybe it's C logo is what I'm looking for. I can cat that out. No, just logo. Again, different devices have different names for stuff. And you can see it's blod gibberish in this case because that is a binary file but you're reading it like a file and you can actually back it up that way which is what we're going to look at in a future video. But I hope that you did find this useful or interesting and maybe you will find it more useful after we look at it more in future videos. So I do thank you for watching. Please visit filmsbychrist.com. That's Chris the K. Again, if you were to go to my website looks like this. There's a search bar here you can type in something like Android and you have to spell it right and it'll bring up all my videos on Android TWRP and you'll bring up my videos on TWRP our fast boot and I do go over those things in more detail so you know go ahead and check those out if you are a beginner at this and you're trying to figure out how to unlock your boot loader which is a little different for different devices but you can find more information in these and again some of these are older and Android does change some of the things I do in some of these may not work on newer Android devices which is kind of annoying but that's just how life is with Android so thanks for watching and I hope that you have a great day.