Score:1

How to Merge unpartitioned space with partitioned system disk in Ubuntu Server

br flag

I recently installed ubuntu-server and allocated 49GB for system But there was unpartitioned 1tb storage. I forgot to setup that.

Here is the result of lsblk.

NAME   MAJ:MIN RM  SIZE RO TYPE MOUNTPOINT
loop0    7:0    0 55.4M  1 loop /snap/core18/2128
loop1    7:1    0 61.8M  1 loop /snap/core20/1081
loop3    7:3    0 68.2M  1 loop /snap/lxd/21039
loop4    7:4    0 32.3M  1 loop /snap/snapd/12398
loop5    7:5    0 55.5M  1 loop /snap/core18/2074
loop7    7:7    0 61.7M  1 loop /snap/core20/1026
loop8    7:8    0 32.3M  1 loop /snap/snapd/12704
loop9    7:9    0 68.3M  1 loop /snap/lxd/21260
sda      8:0    0   50G  0 disk
├─sda1   8:1    0  512M  0 part /boot/efi
└─sda2   8:2    0 49.5G  0 part /
sdb      8:16   0    1T  0 disk
sdc      8:32   0  250G  0 disk
sr0     11:0    1 1024M  0 rom

Now I need to merge sda2 partition with sdb. sda2 partition already has services and data. Like mysql , php etc.. I need to do that process without losing data.

Note that ubuntu-server does not have a GUI, I can only connect to it through ssh to a root user, hence it has to be done using commands.

Soren A avatar
mx flag
sda, sdb and sdc are three different physical disks. You can't just merge them. If you can tell what you want to use the space form then maybe we cab give a solution.
Prasad D. Warnakulasuriya avatar
br flag
I need to use sdb space inside of sda1 drive. Inside of sda1 I have installed services. php , mysql all.
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.