Can I resize "/" partition?

General support questions
mashiro2004
Posts: 68
Joined: 2018/12/08 21:46:22
Location: Italy

Re: Can I resize "/" partition?

Post by mashiro2004 » 2019/01/07 12:42:29

AHHH, possible cause is that you must reload partition table:

partprobe /dev/sdb

hack3rcon
Posts: 757
Joined: 2014/11/24 11:04:37

Re: Can I resize "/" partition?

Post by hack3rcon » 2019/01/07 12:53:06

mashiro2004 wrote:
2019/01/07 12:31:26
hack3rcon wrote:
2019/01/07 12:27:00
mashiro2004 wrote:
2019/01/07 12:18:54


Have you unmounted sdb1? if not unmount it ad re-launch commands
I umounted partitions.
try this way:

parted
select /dev/sdb
resizepart
1
Good.
I can define how much size I need to add. Thank you.
Can I merge them without losing any data on both partitions?

mashiro2004
Posts: 68
Joined: 2018/12/08 21:46:22
Location: Italy

Re: Can I resize "/" partition?

Post by mashiro2004 » 2019/01/07 13:10:21

hack3rcon wrote:
2019/01/07 12:53:06
mashiro2004 wrote:
2019/01/07 12:31:26
hack3rcon wrote:
2019/01/07 12:27:00


I umounted partitions.
try this way:

parted
select /dev/sdb
resizepart
1
Good.
I can define how much size I need to add. Thank you.
Can I merge them without losing any data on both partitions?
Now you have only one partition.... sdb1, sdb2 is deleted.... Yes you don't loose data but i recommend you to make a backup....

hack3rcon
Posts: 757
Joined: 2014/11/24 11:04:37

Re: Can I resize "/" partition?

Post by hack3rcon » 2019/01/08 06:26:39

mashiro2004 wrote:
2019/01/07 13:10:21
hack3rcon wrote:
2019/01/07 12:53:06
mashiro2004 wrote:
2019/01/07 12:31:26

try this way:

parted
select /dev/sdb
resizepart
1
Good.
I can define how much size I need to add. Thank you.
Can I merge them without losing any data on both partitions?
Now you have only one partition.... sdb1, sdb2 is deleted.... Yes you don't loose data but i recommend you to make a backup....
When I deleted a partition, I never lose data? I mean is data on "sdb1".

mashiro2004
Posts: 68
Joined: 2018/12/08 21:46:22
Location: Italy

Re: Can I resize "/" partition?

Post by mashiro2004 » 2019/01/08 10:40:50

hack3rcon wrote:
2019/01/08 06:26:39
mashiro2004 wrote:
2019/01/07 13:10:21
hack3rcon wrote:
2019/01/07 12:53:06


Good.
I can define how much size I need to add. Thank you.
Can I merge them without losing any data on both partitions?
Now you have only one partition.... sdb1, sdb2 is deleted.... Yes you don't loose data but i recommend you to make a backup....
When I deleted a partition, I never lose data? I mean is data on "sdb1".
No if you delete sdb2 and first you copy data on another location you data is save. You don't loose data on extend partition, but a backup of data is always recommended ;) :)

hack3rcon
Posts: 757
Joined: 2014/11/24 11:04:37

Re: Can I resize "/" partition?

Post by hack3rcon » 2019/01/08 11:08:25

mashiro2004 wrote:
2019/01/08 10:40:50
hack3rcon wrote:
2019/01/08 06:26:39
mashiro2004 wrote:
2019/01/07 13:10:21


Now you have only one partition.... sdb1, sdb2 is deleted.... Yes you don't loose data but i recommend you to make a backup....
When I deleted a partition, I never lose data? I mean is data on "sdb1".
No if you delete sdb2 and first you copy data on another location you data is save. You don't loose data on extend partition, but a backup of data is always recommended ;) :)
Sorry, I mean was "sdb2". When I deleted a partition then data not lost!

User avatar
TrevorH
Site Admin
Posts: 33202
Joined: 2009/09/24 10:40:56
Location: Brighton, UK

Re: Can I resize "/" partition?

Post by TrevorH » 2019/01/08 11:18:59

The only reason you didn't lose data when you deleted /dev/sdb2 was because you previously copied the data off it to the other filesystem.

You did copy the data first, right?
The future appears to be RHEL or Debian. I think I'm going Debian.
Info for USB installs on http://wiki.centos.org/HowTos/InstallFromUSBkey
CentOS 5 and 6 are deadest, do not use them.
Use the FAQ Luke

hack3rcon
Posts: 757
Joined: 2014/11/24 11:04:37

Re: Can I resize "/" partition?

Post by hack3rcon » 2019/01/08 11:29:40

If my system just have 60GB HDD (VM) then how can I increase the size of "/" partition?

mashiro2004
Posts: 68
Joined: 2018/12/08 21:46:22
Location: Italy

Re: Can I resize "/" partition?

Post by mashiro2004 » 2019/01/08 11:48:04

hack3rcon wrote:
2019/01/08 11:29:40
If my system just have 60GB HDD (VM) then how can I increase the size of "/" partition?
The response is depending.
You can add more disk space to vm?

do you use LVM Volumes?

You can add phisical Hard Disk?

How is the actual configuration?

Bye

hack3rcon
Posts: 757
Joined: 2014/11/24 11:04:37

Re: Can I resize "/" partition?

Post by hack3rcon » 2019/01/08 12:00:00

mashiro2004 wrote:
2019/01/08 11:48:04
hack3rcon wrote:
2019/01/08 11:29:40
If my system just have 60GB HDD (VM) then how can I increase the size of "/" partition?
The response is depending.
You can add more disk space to vm?

do you use LVM Volumes?

You can add phisical Hard Disk?

How is the actual configuration?

Bye
I guess when CentOS did partitioning automatically then it create LVM? I can add Virtual HDD to my VM but I want to know can I add new HDD space to "/"!

Post Reply