You are not logged in.
Pages: 1
I would like to know if it's possible to merge two ext4 partitions to create one ext4 partition with files untouched. I have / and /opt on separate partition and would like /opt to be on the same partition as /. Is it doable without system format?
Offline
what about just copying /opt to your root folder and then resize your root partition... isn't that the same?
Offline
In order to ease the operation, start your system using a live cd.
First, you need to mount both partitions in your live environment. Lets say one of them is mounted too /mnt/root, and the other to /mnt/opt
Second, you create a new subfolder in /mnt/root called opt, so that you now have a path /mnt/root/opt
Then, you copy all the files from /mnt/opt over to /mnt/root/opt. I hope you have enough space for this operation
When thats done, unmount both partitions, and use the disk partitioning tool of your choice to remove the /opt partition and make the / partition larger.
If you need more detailed help on how to do any of these, please ask. I hope I outlined the steps clearly
Offline
Thanks. I'll give it a shot. What Live CD do You recommend?
Can you write a very short tutorial about mounting drives? (I'm afraid I'd mount them in read-only mode or something like that propably )
PS.: My fstab:
#
# /etc/fstab: static file system information
#
# <file system> <dir> <type> <options> <dump> <pass>
none /dev/pts devpts defaults 0 0
none /dev/shm tmpfs defaults 0 0
#Linux drives
UUID=1e68d1ae-5f08-4a45-92f3-d5a9b3720902 / ext4 defaults 0 0
UUID= swap swap defaults 0 0
UUID=9d234111-34f5-4e05-b690-e2e724ac2cfd /home ext4 defaults 0 0
UUID=08d10b10-cea7-4ade-8041-99ae46e61b9a /opt ext4 defaults 0 0
#USB in VirtualBox
none /proc/bus/usb usbfs auto,busgid=108,busmode=0775,devgid=108,devmode=0666 0 0
Yeah, I know, swap isn't working. I would like to get rid of it entirely (I have enough RAM), so another good reason to use Live CD.
Offline
I have a Ubuntu live cd laying around that I use for such tasks, seeing it boots into something graphical and it has gparted, my favourite partition editor. You could just aswell use the Arch install medium, it's also a live cd, with just a bash shell. If you feel comfortable using fdisk and the likes, go crazy.
In order to mount the root partition, you could issue
# mount /dev/disk/by-uuid/1e68d1ae-5f08-4a45-92f3-d5a9b3720902 /mnt/root
Although I think when using a full featured live cd such as Ubuntu, it should give you options to mount it through Nautilus (the file manager). You may need root rights in order to write on them, but in a live environment thats no issue.
Offline
Pages: 1