Is it safe to resize my Slackware partitions after removing my Mint 10 partitions?
Hello:
I've reached a point in my Slackware journey where I feel confident enough to remove my Mint 10 linux. It used to be my 'go to distro' when I trashed my Slackware installation. Now, I have Slax on a USB and I think that is enough. Mint 10 occupies /dev/sda5 (root) and /dev/sda6 (home) while Slackware occupies /dev/sda7 (root) and /dev/sda8 (home). If I delete the /dev/sda5 & /dev/sda6 partitions, can I very safely resize /dev/sda7 and /dev/sda8 to use the space freed up? Thanks, |
Quote:
Kind regards |
I've had quite good luck using parted to re-size ext partitions, your mileage may vary. Back up your PC *before* you attempt deleting, re-sizing in the event that things go awry. Good luck.
http://www.gnu.org/software/parted/ http://gparted.sourceforge.net/livecd.php |
I may be wrong but I believe you can only resize into adjacent partitions, so that may give you issues. LVMs make resizing a much more pleasurable experience but they obviously add another level of complexity to deal with.
|
It's someone who noticed that our OP want to MOVE DOWN AND RESIZE these partitions? :D
|
Hello:
I am waiting for my 'dd' back ups of /dev/sda7 & /dev/sda8 to complete. Is the fact that sda5 & sda6 are before my Slackware partitions a problem? Would it be better to, after my backups complete, delete all 4 of my linux partitions and then create 2 new ones and then restore from my back up, or, is this even possible from a 'dd' back up living on my external hard drive? Thanks, |
Well, that method can work if you use EXT2/3/4FS. If you use the condition that these new partitions are somewhat bigger than the original.
Create the new partitioning, DD it back and use resize2fs for resizing the filesystems in the right sizes. Then, mount the target root partition and reconfigure it for the new partition layout. Enjoy! :) |
I always backup the system partition (you call it root) as tar.gz file using the command such as:
tar czf /path/to/the/backup/directory/name_of_the_backup_file.tgz * As for the data partition (you call it home) I always backup it as is on the external drive using the command such as: rsync -av /source/directory /destination/directory In the past I did backup of Windows XP system using dd command. The result wasn't satisfactory. When I tried to restore the system with dd command on the partition smaller than the original one Windows XP refused to work. On the other hand when I tried to restore it on the bigger partition then the original one I wasted some space because I wasn't able to resize that partition. Linux can cause other problems. Assuming the system you backed up was on /dev/sda7 partition and the bootloader was installed on the same partition and you try to restore it on /dev/sda5 partition the result will be a mess. So I suggest to use tar to backup system partition and rsync to backup data partition. |
Quote:
My Slackware partitions are ext4 and so is my back up partition on my external USB drive. Actually, I am so confused right now that I can't formulate the questions! I've got to think about all of this. Thanks for the food for thought.:) |
If you create a successful `dd` backup you can delete the other partitions and create two new ones of satisfactory size (though they must be at least as big as they are now) and restore the filesystem onto the new partitions. However, when you first boot, the filesystem has not been resized so although it is living in a bigger partition you will not have access to more space. Luckily ext4 filesystems can be resized using resize2fs as stated, so you can then resize the filesystem to take up the rest of the room in each partition and then you're golden. However since the partition names may be different you may have to modify /etc/fstab and /etc/lilo.conf (don't forget to run lilo) to accommodate the new device names.
If you do make a mistake or can't figure it out, you should be able to reinstall Slackware on the resized partitions and get at any data stored in the dd backups by mounting the images and pulling any files you need. |
Quote:
|
Quote:
I don't understand.:confused: I have an external USB hard disk on which there are 2 partitions: 1 ntfs & 1 ext4. I did my back ups like this where /dev/sdb2 is mounted at /tmp/USBdrv: Code:
# dd if=/dev/sda8 of=/tmp/USBdrv/slackhome.img bs=64k Thanks, |
Quote:
|
if /tmp/USBdrv/ is where your external is mounted, then that's just fine. ;)
I had Ubuntu on /dev/sda1, Windows on /dev/sda2, and slackware on /dev/sda3, and I deleted my Ubuntu partition, and moved the other two over, and I've had no problems. (Although I have no /dev/sda1 :P) |
Quote:
Do I need to down load and install resize2fs before doing any of this? If so, I will have to do new back ups, right? Also, am I to use the installed 'KDE Partition Manager' to do all this? Thanks, |
All times are GMT -5. The time now is 09:02 AM. |