MX Linux Move home to a new partition and how to use our Chroot Rescue Scan

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
hi hi there youtubers my name is Michael Pavlovic and I want to show you very briefly how to repartition a hard drive using iMix linux this video is intended for people who have done the default install of MX Linux and they use the entire hard disk drive and I've decided that later on they want to add a data partition so I have got here a virtual machine that I'm operating and I'm running live Linux at the moment and this is the the root drive of a virtual machine so what I want to do is show you very briefly what that looks like first so I'm going to pop in here and go to gparted just type part on it it's enough password in there and what do you know put the wrong password in there what is it wait clear to open up ok so here's a partitioning of the iMix system underneath all of this as a 20 gigabyte Drive allocation that I've given it and this is just the default set up so what I want to do is I want to squash this down here and make another data petition of course this is only a small driver I don't recommend doing this on a small drive but it'll give you all that you need to learn about how to do this process properly there are a few things you need to do before you get started and this was going to have a look at what that is so when you're running live what do you need to do is now to the petition so I'm going to go ahead and mount that petition and here's it here's the details of perdition what we're going to do is we want to backup the etc' you've stared now hopefully before you learn any of this you'll have backed up your whole hard drive right you're not going to do anything silly like read petitioning your root Drive or adding a home position before actually backing up your hard drive value if you haven't go ahead and do a backup and lucky backup is a good option for you right just get this get started so it's C here and and then we want to go to the if step so with its the open you didn't have to try hard just start typing what you want to find so if s T takes us straight to F step says it highlighted down here just take that and dragged it across to the desktop you want met movie didn't work we'll try it again there we go drag it across the desktop and what I'm going to show you here I'm going to go ahead and unmount this because I don't want to mount any further and that wouldn't have a look at what s there if stem looks like if step stands for filesystem table and what we see here is there are two there are two locations in there is the root that's the root petition there and there's a swap petitioner that's exactly what we saw before and we're going to go ahead and make changes to those so I'm going to show you now how to do that and then a little little key to making things work for you okay we'll close it because don't need that open anymore back to gparted and we have our petitions here so all we're going to do is resize this and to do that and it pays to make sure nothing on the drive is an operation but because we're running in in live linux it really won't matter if we leave in XY pond but here's I'm going to do I'm going to turn swap off so right click this and click on swap off right now there's no locked partition anywhere on on this storage media I'm going to go ahead and right-click this and resize now I'm just going to Reese and resize a little bit I'm am without having to and you're going to go I'm going to take a moment here just to explain how the Linux file system the exe for file system works in their storage partition when you and I think in terms of sequential storage but Linux and the xp for system doesn't think like that your first file ever planted on a Linux file system and an exception is the bootloader would be right here in the middle of a drive so as you fill your drive it's also in the middle and starts occupying space all over the place when you're resizing a drive it's got to move any files it finds that are in the path so I'm just going to resize a little bit okay rather than I mean a one let me resize down past that and as we can see here we got four point eight one one megabytes or four point eight gigabytes of your space I'm going to take that up a little bit to about halfway something like about here now at this point in time if I want to adjust it to meet to make an exact size let's say I want exactly ten gigabytes here 1/10 double oh oops and I press tab what you see here as it's grown I sleep if I want to make that eight gigabytes eight thousand you can adjust it with actual numbers as you go so we left at n 400 I'm going to go back to the team and we're going to go ahead and resize that we that's that's what the new that that's going to look like so go ahead and we hit apply and apply again and that's going to sit there and do that work for us now unfurl it they go for a short time if it looks like we're going to take ages I'm going to pause the recording and we'll come back to it later on and yes I'll pause it will see you very shortly and we're back so we're finished with the repositioning of them that you take that long because it's only a small drive but let's say on a drive of 256 Meg's or 256 gigs you might expect to wait five minutes or so anyway we're done if you want to see the details of that you can open this up and content drill down to to see whatever that every point in the time but there's no need to we're happy that it's done okay so I'm going to go ahead and close that now what I'd normally do at this point in time is on reboot the machine to make sure it's working but in this case here because I'm working on a virtual machine and I'm taking a snapshot of my virtual machine I can destroy it then restore it to the snapshot I'm just going to keep moving forward add a blinding rate right so we have now FDA 1 which is me xp for petition and SDA 2 which is a Linux wot petition the next position we're going to be putting in is going to be called SDA 3 which is a third petition and sequence but because this was first this was second this one here in the middle is going to be third so you need to be sure about how that works and what I want to do is I want a foo net refer back to this in the moment this little file here the eff step if I right click the SDA one and I click on information what we'll see here it's got a universal ID on there that's the you UID and this will amix on it but that's what it makes look for users to reference each partition now this one starts a CB de d we'll close that we look at swap and do the same here and that's B three eight three eight etc etc etc we will look at the file here the if same file we see ABCDE D just like before there's our root petition as indicated by that and B three eight three eight there's a swap petition is indicated by that and what we need to do with this is we need to add another line in here once we get home so we're just going to leave it open I'm going to minimize that for the time being I'm going to go ahead and create a new home petition so right click there click on new and make sure this is there give it a label if you want to data will do just fine we're going to use all the available space and if nothing left over and click Add go ahead and apply that and that only takes a moment because it's in a virtual machine it's a very small partition so now you have done this what we need to do is identify here does stat3 the UUID that's going to be used in here so we pop into here s do 3 or right-click that go to information and we have our UUID so we take this and we copy that across we cop it we just highlight that and ctrl C on the keyboard to copy it I mean you can right click and copy if you're a mousy type person but I tend to use a combination of mouse and keyboard and we're not going to go into this file here that we have minimized and we're going to pop in a pop it in but what I like to do is some here we go this is ends align here no let's into line there so just stretch it out lit if I can get it all on screen no I can't that won't matter too much but the glyphs just go ahead and drop take some spaces out of here now we'll take it back to you right right there we go section effect anything because it's basically a bunch of tabs right click in here and go UUID equals and paste that's a control V and this is the UUID of the new petition that we've got now of course we need to put that somewhere so we'll put a few spaces in here and we'll light will line them up sort of round about here so let's go ahead and line them up all nicely there's a swap and this is going to be home that too then you will go a couple of spaces and ext4 is going to be the petition type so let's go ahead and check change this I'm only doing this for you guys so you can see it in a nice late nicely laid out way rather than an excuse me rather than say this is what you need to do in every situation so XT so this is a SWAT petition formatted as SWAT and it's got the defaults of zero zero this one is now going to be the home petition as formatted as exp four and we're going to tell to do something with with how it's mounted so we're going to go ahead ups just signing it up again defaults will do just fine and then one zero that's just how the drivers treated but I mean you can do one one if you want to yeah that's really up to you and just make sure there's a blank there's an empty space at the end of the into that file so go ahead and save that so let's I the file file save or ctrl s so that's now saved and we're ready to roll well we think we're ready to roll but that's not quite true just yet so let's show you exactly why that is having it done all that we now see the data position here and we see the route in x16 before we can do anything we actually have to mount both petitions so we'll mount the route and then we'll mount the data and we're going to do now is I'm just going out I put the second instance of this and we have a data here we're going to have the route here so the data at this point in time is completely empty but we need to have something from home and that so let's have a look at what's in home and home we've got a folder called owner but in here we've got nothing but empty space and how can we tell seven point six gigabytes of available space down here and on this one five point three gigs available space so we now run two different drives now you can you should never just copy from one point to another and the graphical user interface what you want to be doing is using if using something like if unlike our sink so I'm going to go ahead and do that now so here's a terminal and two now I'm going to do is a different end of the right-click here so I'm going to open a terminal from within this location open a terminal here so you're filming media demo root M X 16 home and I'm going to type in or command R is y in c minus AV yes and then star we're going to take everything that's in there and we're going to drop it into here now the easy way to make sure that you don't make any mistakes is to copy that and paste it in here now for those that we're wondering what I was doing and I just I just highlight it with my right mouse button here I with my with my right now let my normal mouse button here and then I sent a collect now the mouse button that the middle button is the wheel so on your well you can just click it in and then often works very very well anyways going to go ahead and press ENTER and I made a mistake can anyone tell me what that was it was a head no permission to do so so I press the up key again press home to get to the front of that and sudo rsync off we go demo password burn we now have everything that we needed from here and here so if I go ahead and delete this the next time we boat it's going to fall over miserably if this does not suggest so get on the dough I'm going to go ahead and delete that so I'll show you the quickest way to do that open root sooner here okay there and she's gone just like that I decided shift delete so there's no recycle bin or anything no trash been involved in fact there is now just an empty folder so now this home location here I'll go back to here this home is only a placeholder and nothing else when we reboot is going to go here but before we do that we need to take the F cell file that we've created and drop it in where we and drop it under here so let's go ahead and pop in the here right-click open root through here and root again and we can disappear this one we don't need that and of course we go to Etsy and we want to put if sad back in here so I'm going to go ahead and just highlight something FST there's a fstab file down there oops I move Mouse too quickly so we'll find at the flame here's I have step here and I want you to cast your eye down here 313 kilobytes don't unfitting bytes that's the size of the file right I'm going to go ahead now AG I don't need this happen anymore I'm going to drag the Sun so we're replacing the earlier file which is around 13 bytes with this file which is 337 bytes so I'm going to go ahead replace that so now when we highlight this file we now see we got the new file surrender and 37 bytes and if we go ahead and open that there is our new file that we can see with those new defaults built into it now like I said here's a moment of truth what I need to do now is I need to reboot I'm going to pop in here and pop in here and I'm going to restart this system of course being a live Linux distribution machine it's going to want to inject the CD and then reboot normally so let's go ahead and watch what's happening here we go and here we go now I worked on the in exciting system that I did some oh gosh I I bought this Najaf beckoned sort of three years ago maybe so it's been hanging around for this long alright we're back in and let's have a got the password right now because I haven't opened this for years now I have a habit okay I might after login as root root and but do you know I can't move the path it gives a second note nope like I remember the password that's terrible okay well it's a bit of this bit of a fail of net look I'll go and sort up my passwords on this and I'll come back to the recording hey I'm back again just thought I'd backtrack a bit on what I just said and instead of coming back to you with the repaired pasture I want to show you how I'm going to go ahead and do that and I'm going to add into this little video how to use the chroot rescue and then X Linux sound we're going to hit and pose it and just to show you exactly where we are again so let's look at the data and root of x 60 never had before okay so pop into here this was about the easiest way you can possibly imagine to to get back into the system where you forgot the password and here does he chroot rescue scan we'll go ahead and click on that pass fit for demos and what it shows here is MX 16 metamorphosis forget to date and it's all reflected it so all you have to do is press ENTER to select the highlighted entry so go ahead now we're actually only next 16 and I want to show you something very very briefly here and so Who am I I am root okay and lift so these are the contents and the contents of the drive that I'm logged into and here's our home one here and what I want to do is I want to show the contents of home theory Klee this should be nothing in there LS Oh list the contents of home attempting how about that so I know I'm on the right Drive okay so now I'm going to go ahead and reset the brute the root password which I didn't know P is swd into the new UNIX password sons go go TW our for the sake of something nice needed to remember I can go ahead and change it later on and that's the root password changed simple as that so ctrl D to exit and cue to exit again done I have now reset the password on that okay rebooting and we'll mix you back in just a few seconds whereas a restart okay we're back again and of course we're still not going to be able to login as owner so the login as root I said to the four Oh root and tear lower that's better I'm logging in now of course you can always log in and you can always use the index tools to reset passwords I prefer to do another way they're mixed tools weren't kind of speak for themselves so like if you pop into here now this was 16 so it's going to be a much much older version of it and somewhere in here we'll have user manager I've probably missed it there it is right in front of my eyes you can go user manager and then that you can choose the user air change user password you can pop on it here and you can go ahead and change a password etc etc I prefer to do the command-line way so I'm going to go ahead and over the command line there as terminal so so the password Oh wnes to no password owner and new units password re in Oh W this is a mix up of word owner we now renoun control the int logout and now re you know W now of course it didn't work we wouldn't even go to listen I remember this annoying screen okay have a look having a look here we now have our home folder where the relocated home folder we have 8.1 gigabytes of free space for me if I go to the file system we have five point seven gigabytes so we have successfully added a home petition will go they can have another look elect through gparted and then we have it successfully move the petition and risk it a root password while Reddit to gain access to a system we did not have access to before perfect guys I hope this is going to really help a lot of you guys to overcome a huge fear that people have of re petitioning drives when we're done you have to be careful you have to be ultra ultra careful so what I'm going to do is I'm just going to bring forward my VM screen here they're going to right click here and then go to up there not right click normal look at the snapshots here's my snapshot better than before everything I've been doing works here so I can go ahead and replace this natural if I want to and it will go back to as it was or I can just carry on here and move on from them okay I hope this is going to help hang of a lot for further help and information please do visit the MX Linux forums and my username on there is M underscore PA V and there's plenty of people here that can help you and I live in the the time zone where I'm GMT plus 12 so I'm ahead of most of the world and you might get fast responses from others but together we can cover every one of your needs and I hope you enjoy using MX Linux this is Mike pairs out
Info
Channel: Michael Pavletich
Views: 1,494
Rating: undefined out of 5
Keywords:
Id: HgXclpM_0jM
Channel Id: undefined
Length: 21min 8sec (1268 seconds)
Published: Mon Mar 30 2020
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.