Enlarged /var Partition

Used GParted to grow /var partition

Background

I’ve installed Ubuntu 18.04 on my new laptop.

Problem

The /var partition was too small. The system complained that only 200 MB was left.

Solution

  1. Rebooted with my live USB.
  2. Opened GParted.
  3. Moved /tmp partition to the left and grew it to 6 GB.
  4. Grew /var partition to 16 GB
  5. Click

GParted screenshot

Results

GParted result partition table

Details [TL;DR]

Here’s the GParted generated log.

GParted Details

GParted 0.30.0 --enable-libparted-dmraid --enable-online-resize

Libparted 3.2

Move /dev/sdb4 to the left and grow it from 3.81 GiB to 6.00 GiB  00:00:22    ( SUCCESS )
    
calibrate /dev/sdb4  00:00:03    ( SUCCESS )
    
path: /dev/sdb4 (partition)
start: 1905526784
end: 1913526271
size: 7999488 (3.81 GiB)
calculate new size and position of /dev/sdb4  00:00:01    ( SUCCESS )
    
requested start: 1875781530
requested end: 1888360424
requested size: 12578895 (6.00 GiB)
new start: 1875781530
new end: 1888360424
new size: 12578895 (6.00 GiB)
check file system on /dev/sdb4 for errors and (if possible) fix them  00:00:01    ( SUCCESS )
    
e2fsck -f -y -v -C 0 '/dev/sdb4'  00:00:01    ( SUCCESS )
    
Pass 1: Checking inodes, blocks, and sizes
Pass 2: Checking directory structure
Pass 3: Checking directory connectivity
/lost+found not found. Create? yes

Pass 4: Checking reference counts
Pass 5: Checking group summary information

/dev/sdb4: ***** FILE SYSTEM WAS MODIFIED *****

19 inodes used (0.01%, out of 249984)
0 non-contiguous files (0.0%)
0 non-contiguous directories (0.0%)
# of inodes with ind/dind/tind blocks: 0/0/0
Extent depth histogram: 9
36000 blocks used (3.60%, out of 999936)
0 bad blocks
1 large file

0 regular files
8 directories
0 character device files
0 block device files
0 fifos
0 links
0 symbolic links (0 fast symbolic links)
1 socket
------------
9 files
e2fsck 1.44.1 (24-Mar-2018)
grow partition from 3.81 GiB to 18.00 GiB  00:00:03    ( SUCCESS )
    
old start: 1905526784
old end: 1913526271
old size: 7999488 (3.81 GiB)
new start: 1875781530
new end: 1913526271
new size: 37744742 (18.00 GiB)
move file system to the left  00:00:06    ( SUCCESS )
    
e2image -ra -p -o 15229570048 '/dev/sdb4'  00:00:06    ( SUCCESS )
    
e2image 1.44.1 (24-Mar-2018)
Scanning inodes...
Copied 35930 / 35930 blocks (100%) in 00:00:03 at 46.78 MB/s
shrink partition from 18.00 GiB to 3.81 GiB  00:00:03    ( SUCCESS )
    
old start: 1875781530
old end: 1913526271
old size: 37744742 (18.00 GiB)
new start: 1875781530
new end: 1883781017
new size: 7999488 (3.81 GiB)
calculate new size and position of /dev/sdb4  00:00:01    ( SUCCESS )
    
requested start: 1875781530
requested end: 1888360424
requested size: 12578895 (6.00 GiB)
new start: 1875781530
new end: 1888360424
new size: 12578895 (6.00 GiB)
check file system on /dev/sdb4 for errors and (if possible) fix them  00:00:00    ( SUCCESS )
    
e2fsck -f -y -v -C 0 '/dev/sdb4'  00:00:00    ( SUCCESS )
    
Pass 1: Checking inodes, blocks, and sizes
Pass 2: Checking directory structure
Pass 3: Checking directory connectivity
Pass 4: Checking reference counts
Pass 5: Checking group summary information

19 inodes used (0.01%, out of 249984)
0 non-contiguous files (0.0%)
0 non-contiguous directories (0.0%)
# of inodes with ind/dind/tind blocks: 0/0/0
Extent depth histogram: 9
36000 blocks used (3.60%, out of 999936)
0 bad blocks
1 large file

0 regular files
9 directories
0 character device files
0 block device files
0 fifos
0 links
0 symbolic links (0 fast symbolic links)
1 socket
------------
10 files
e2fsck 1.44.1 (24-Mar-2018)
grow partition from 3.81 GiB to 6.00 GiB  00:00:04    ( SUCCESS )
    
old start: 1875781530
old end: 1883781017
old size: 7999488 (3.81 GiB)
new start: 1875781530
new end: 1888360424
new size: 12578895 (6.00 GiB)
grow file system to fill the partition  00:00:00    ( SUCCESS )
    
resize2fs -p '/dev/sdb4'  00:00:00    ( SUCCESS )
    
Resizing the filesystem on /dev/sdb4 to 1572361 (4k) blocks.
The filesystem on /dev/sdb4 is now 1572361 (4k) blocks long.

resize2fs 1.44.1 (24-Mar-2018)

========================================

Move /dev/sdb3 to the left and grow it from 3.81 GiB to 15.81 GiB  00:02:22    ( SUCCESS )
    
calibrate /dev/sdb3  00:00:01    ( SUCCESS )
    
path: /dev/sdb3 (partition)
start: 1913526272
end: 1921525759
size: 7999488 (3.81 GiB)
check file system on /dev/sdb3 for errors and (if possible) fix them  00:00:02    ( SUCCESS )
    
e2fsck -f -y -v -C 0 '/dev/sdb3'  00:00:02    ( SUCCESS )
    
Pass 1: Checking inodes, blocks, and sizes
Pass 2: Checking directory structure
Pass 3: Checking directory connectivity
Pass 4: Checking reference counts
Pass 5: Checking group summary information

13135 inodes used (5.25%, out of 249984)
100 non-contiguous files (0.8%)
8 non-contiguous directories (0.1%)
# of inodes with ind/dind/tind blocks: 0/0/0
Extent depth histogram: 12828/54
769775 blocks used (76.98%, out of 999936)
0 bad blocks
1 large file

12309 regular files
561 directories
0 character device files
0 block device files
0 fifos
9 links
256 symbolic links (245 fast symbolic links)
0 sockets
------------
13135 files
e2fsck 1.44.1 (24-Mar-2018)
grow partition from 3.81 GiB to 15.81 GiB  00:00:03    ( SUCCESS )
    
old start: 1913526272
old end: 1921525759
old size: 7999488 (3.81 GiB)
new start: 1888360448
new end: 1921525759
new size: 33165312 (15.81 GiB)
move file system to the left  00:02:07    ( SUCCESS )
    
e2image -ra -p -o 12884901888 '/dev/sdb3'  00:02:07    ( SUCCESS )
    
e2image 1.44.1 (24-Mar-2018)
Scanning inodes...
Copied 769734 / 769734 blocks (100%) in 00:01:45 at 28.64 MB/s
shrink partition from 15.81 GiB to 3.81 GiB  00:00:04    ( SUCCESS )
    
old start: 1888360448
old end: 1921525759
old size: 33165312 (15.81 GiB)
new start: 1888360448
new end: 1896359935
new size: 7999488 (3.81 GiB)
check file system on /dev/sdb3 for errors and (if possible) fix them  00:00:01    ( SUCCESS )
    
e2fsck -f -y -v -C 0 '/dev/sdb3'  00:00:01    ( SUCCESS )
    
Pass 1: Checking inodes, blocks, and sizes
Pass 2: Checking directory structure
Pass 3: Checking directory connectivity
Pass 4: Checking reference counts
Pass 5: Checking group summary information

13135 inodes used (5.25%, out of 249984)
100 non-contiguous files (0.8%)
8 non-contiguous directories (0.1%)
# of inodes with ind/dind/tind blocks: 0/0/0
Extent depth histogram: 12828/54
769775 blocks used (76.98%, out of 999936)
0 bad blocks
1 large file

12309 regular files
561 directories
0 character device files
0 block device files
0 fifos
9 links
256 symbolic links (245 fast symbolic links)
0 sockets
------------
13135 files
e2fsck 1.44.1 (24-Mar-2018)
grow partition from 3.81 GiB to 15.81 GiB  00:00:03    ( SUCCESS )
    
old start: 1888360448
old end: 1896359935
old size: 7999488 (3.81 GiB)
new start: 1888360448
new end: 1921523711
new size: 33163264 (15.81 GiB)
grow file system to fill the partition  00:00:01    ( SUCCESS )
    
resize2fs -p '/dev/sdb3'  00:00:01    ( SUCCESS )
    
Resizing the filesystem on /dev/sdb3 to 4145408 (4k) blocks.
The filesystem on /dev/sdb3 is now 4145408 (4k) blocks long.

resize2fs 1.44.1 (24-Mar-2018)

========================================


No comment

Your email address will not be published. Required fields are marked *.