All new Registrations are manually reviewed and approved, so a short delay after registration may occur before your account becomes active.
resizing active partition on Debian 8 Jessie
Hello Guys.
I am hosting a Game Server on a VPS from Chapal.net . it is a cloud server and i am using the package which says 7000 PKR = Pakistani Rupees.
Here are the specs of the Cloud Server.
4GB Memory
2 Core Processor1
80GB Disk
2TB Transfer
I upgraded from 2 GB to 4 GB Package.
Earlier my HDD size was 40 GB according to plan . after upgrade it remains the same. But the hosting company confirmed that it has been upgrade but i do not see it as of yet. it seems i have to resize the current active partition of /root
root@debian:~# df -h
Filesystem Size Used Avail Use% Mounted on
udev 10M 0 10M 0% /dev
tmpfs 791M 17M 774M 3% /run
/dev/sda1 38G 14G 23G 37% /
tmpfs 2.0G 0 2.0G 0% /dev/shm
tmpfs 5.0M 0 5.0M 0% /run/lock
tmpfs 2.0G 0 2.0G 0% /sys/fs/cgroup
tmpfs 396M 0 396M 0% /run/user/1001
tmpfs 396M 0 396M 0% /run/user/0
so what command to make it 80 GB to resize the current partition which is active?
Please help.
Comments
resize2fs /dev/sda1
Likely, you'll just need to run a resize2fs command.
edit: @Ishaq's quick on the draw today
Chances are you'll probably need to extend your partition table also to use the new sector count, before extending the filesystem as mentioned above.
That normally involves deleting the / partition, and re-creating it using the original sector start point.
root@debian:~# resize2fs /dev/sda1
resize2fs 1.43.4 (31-Jan-2017)
The filesystem is already 10047744 (4k) blocks long. Nothing to do!
any idea?
You need to resize the partition too (use parted, fdisk etc.)
can you guide me over team viewer?
.1. You didn't show us how
fdisk -l
looks like..2. Why not following some guide?
Basic idea behind this is:
Write down all parameters shown in
fdisk -l
, or screen shot it.Disable and delete swap if there is one.
Delete your root partition.
Re-create your root partition using the same start position.
Activate that partition.
Run partprobe to update partition table, and do
resize2fs
as you did.here you go
root@debian:~# fdisk -l
Disk /dev/sda: 80 GiB, 85899345920 bytes, 167772160 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: dos
Disk identifier: 0xac935b07
Device Boot Start End Sectors Size Id Type
/dev/sda1 * 2048 80383999 80381952 38.3G 83 Linux
/dev/sda2 80386046 83884031 3497986 1.7G 5 Extended
/dev/sda5 80386048 83884031 3497984 1.7G 82 Linux swap / Solaris
You are kind of fucked with the secondary partition. Swapoff /dev/sda5, delete sda5, delete sda2, then resize sda1, then recreate sda2.
could you guide me?
I just did.
with command sorry if i am repeating
As I said.
If you need more help than that- pay someone to help you so you don't fuck it up.