Increase/Extend Root Filesystem Online Without Downtime & Without Losing Data Using fdisk In Linux
HTML-код
- Опубликовано: 29 июн 2020
- Learn the step by step process of how to resize a standard partition In Linux without unmounting a filesystem and without downtime. This Video showed the step by step process of increasing the root filesystem/partition online without downtime & without the loss of data :
Tutorial Documentation tekneed.com/increase-standard...
RHCSA exam practice questions: tekneed.com/ex200-rhcsa-9-exa...
RHCE/ex294 exam practice questions:
tekneed.com/rhce-ex294-exam-p...
tekneed.com/rhce-ex294-v9-exa...
#rhcsa #ex200 #linux Наука
Perfect tutorial for resizing/increasing partition size in Linux virtual machine using fdisk.
Glad it was helpful!
hello friend, how could i do a similar process with RAIDs ? i had a RAID 1 mounted with two 200gb HDs, now I'm replacing them with two 500gb ones, but as the RAID's being recovered, it's still stuck on the 200gb partitions (sda1-sdb1/sda2-sdb2). could you please help me increase these partitions so it'll match the 500gb ? thank you
You help me a lot !!!! After seeing your site I was able to increase the fuc ... xfs partition !!!
I am glad I was able to help. You are welcome
Thank you! Finally I could do that. It works fine.
You are welcome. Glad it helped
Thank you so much! saved me a ton of time
You're welcome!
it helped me a lot, thanks man!
Glad it helped!
can not using to incease root fs. it only using to extend
You are a blessing!
Thank you. You are welcome
THANK YOU BROTHER, MY BOSS IS SATISFIED
Glad I was able to help. You are welcome
Hi,
while installing cent os I have done the manual partition and give more space to the/var directory as per company requirements.
but now the space got filled with data so I am planning to add one more HDD drive,
hence my question is
is that possible to increase the size of /var?
or
i need to mount the partition to diff directory
Thank you
please guide me in this case.
Yes you can increase /var if you have space on the same disk but I am not sure about adding another disk since you did standard partitioning.
Awesome, man my macbook created a partition called EFI on my external hard drive, how do I delete it?
/dev/disk1 (external, physical):
#: TYPE NAME SIZE IDENTIFIER
0: GUID_partition_scheme *1.0 TB disk1
1: EFI EFI 209.7 MB disk1s1
2: Microsoft Basic Data ENG PAULO 999.9 GB disk1s2
Hi,
If the root and boot partition is same in that scenario can extend the partition in same manner
Yes, you can. Infact, I have had instances where my boot partition got filled up and this is the exact thing I did.
Mister, if i do this into a VPS with a cpanel like plesk installed, its possible that data loss occurs?
i say this because you remove a partition in the video, and that looks like a potential data loss cause
please, i need your help
It should work but please have your data backed-up just in case
Thank you dude, a really good tutorial. I have got the [mtd device must be supplied (device name is empty)] error in my vmware linux host machine and this video helps me to increase the size of the machine. 😅😅😅
lol...Glad it helped
I keep getting value out of range when I try to resize?
the disk likely doesn't have any free space. while using fdisk, press F, it should show you if there's any free space
it's been a year, hopefully this helps lol
on Fedora at step 5, in order to grow the size I used `sudo btrfs filesystem resize max /` instead of `xfs_growfs` or `resize2fs`
Thanks for the information
thank you so muchj man rlly appreciate itl
Glad I could help. You are welcome
If the idea is not to lose files, why did you delete the partition? As far as I know, deleting is losing files
Hi tekneed,
I have this method but not worked,
I have installed oracle linux by creating 2 partitions like /u01 having 20GB and /Dir1 having 20G the rest was given to the /
Later on i needed to increase the size of /u01 with +30G without data loss and i have a free space in my / that is 100G so.
Please assist
You said this method is not working. What is the exact error you are getting?
Thank you. Does not *gparted* do the same thing with equal performance regarding zero downtime and data loss? Kindest regards.
I haven't tried gparted with it though but it should be able to do the same thing as fdisk. The pointer is making sure the information is still in memory.
@@tekneed 👍
Well demonstrated video
Thank you. Glad you liked it
This is very well explained
Glad it was helpful. You are welcome
Hi ,
Can extending a drive that contains MySQL be corrupted after the process?
My drive is sda5 and it /var/lib/mysql
thanks!!
works!!! thanks!!!
I am glad I could help. Thanks for subscribing in advance. lol.
Thanks!
you are welcome!
Can you also decrease the file system partition using this method?
I tried to make 4 seperate partitions on my 2tb NVMe before installing Zorin but I struggled with the file settings for the partitioning so I did a clean install.
I was hoping you could resize partitions quite easily like in Windows but I'm struggling so far... 😅
Yes, you can also decrease this way. Windows is straight forward. Linux too is with LVM and not standard partitioning
for me it says permission denied when I try to do smth , my root file system is full its a 100% I cant login to my linux idk what should I do
You said you can't login, so how are you getting permission denied? Try to login as root or a sudo user. You can add sudo at the beginning of your commands.
Secondly, if you can't login because your root filesystem is full, create a rescue vm/server, attach the old one (disk) to the rescue vm as an external disk, delete some files from the root file system, and then attach it back to the main server.
sudo fdisk ? i didnt go into sudo su so try sudo fdisk because you probably didnt do sudo su
Keren bang, mama kamu pasti bangga
yo man why it shows This disk is currently in use - repartitioning is probably a bad idea.
It's recommended to umount all file systems, and swapoff all swap
partitions on this disk.
Can you give help me in doing what it says
You are probably in the filesystem's/mount point directory of the disk you are trying to resize.
How do I do it then, bro
@@wildpantsxd5189u can use a live usb
same question here @@wildpantsxd5189
TY!!!!
You are welcome
I'm trying to figure it out on My own. But, I worried that it didn't work properly :". IDK
What was the issue/error?
@@tekneed the memory size seems got a limit. '/' with 440G and the '/home/' with 50G. So any document inside home path there's no longer receive more data. :".
You earned a sub also I had to use a ext command
I am glad I could help. Thank you for subscribing.
@@tekneed sudo resize2fs /dev/sdd2 this is the resize command
@@tekneed ext4 was my file format
thank you
You're welcome 😊
What if my filesystem is not xfs and is lvm?
Then you use the lvm method(lvextend, vgextend, pvcreate, etc) to expand your partition.
This link is an example: tekneed.com/how-to-extend-or-reduce-lvm-partition-in-linux/ The video to the link is at the end of the article.
I hope this helps
after typing n in 2:43 it showed
Command (m for help): n
Partition number (3-128, default 3):
i tried typing p but it said value out of range
Probably because you need to select an extended partition. Though, I see that you are trying to extend partition 3 which should still fall within a primary partition. Select "e", i.e extended & see if it will work for you
tyvm
uwc
Keren bang
u deleted sda3 won't that cause any data loss?
it won't, as far as you haven't written/saved it yet.
I had zero loss. I had a clone of my drive my server was out of space. Had to use the ext4 command but yeah. Very easy. If you're worried use clonezilla in case
Will this work on Oracle Linux?
It should work
No it's not working. I try to and follow all steps. and after some research i found that Oracle has lock the options to extend the partition size
@@tekneed No it's not working. I try to and follow all steps. and after some research i found that Oracle has lock the options to extend the partition size
Have you deleted partition and not lost the data?
yes, but this way
nothing is deleted when it is doing this in ram. until your write the changes nothing is changed so you wont lose anything unless you mess up bad and w write at the end
Welldone boy
very nice video but you need a new microphone you sound like your talking in a tin can. its difficult to hear what your saying, also could you zoom in the printing is very small.
Thanks for the tip
a cause de toi j'ai plus de VM !!
Your procedures are pretty dangerous. If this is in production, I have to ensure I have another job to go to when this blow over :)
loool...I laughed very hard. Well, I did this in production. As a matter of fact, it was a multinational organization, and the regional data were sitting on that server. It was actually running SAP..Like I mentioned, YOU MUST DO A BACKUP OF THE SERVER , which is the right thing to do anyway ;)
It props an error on the final step
root@etisp:~# xfs_growfs /
xfs_growfs: specified file ["/"] is not on an XFS filesystem
check the type of filesystem it is. try "resize2fs /" if it's ext(n) type of filesystem.
@@tekneed This was perfect. THANKS!
Thanks!
You are welcome