opkg update
opkg install resize2fs
root@OpenWrt:~# df
Filesystem 1K-blocks Used Available Use% Mounted on
udev 512 0 512 0% /dev
/dev/mmcblk0p2 197209 190164 2949 98% /
tmpfs 945248 1616 943632 0% /tmp
tmpfs 512 0 512 0% /dev
/dev/mmcblk0p1 130798 22210 108588 17% /mnt/mmcblk0p1
/dev/mmcblk0p2 197209 190164 2949 98% /mnt/mmcblk0p2
fdisk /dev/mmcblk0
fdisk /dev/sda
root@OpenWrt:~# fdisk /dev/mmcblk0
Welcome to fdisk (util-linux 2.33).
Changes will remain in memory only, until you decide to write them.
Be careful before using the write command.
Command (m for help): m
Help:
DOS (MBR)
a toggle a bootable flag
b edit nested BSD disklabel
c toggle the dos compatibility flag
Generic
d delete a partition
F list free unpartitioned space
l list known partition types
n add a new partition
p print the partition table
t change a partition type
v verify the partition table
i print information about a partition
Misc
m print this menu
u change display/entry units
x extra functionality (experts only)
Script
I load disk layout from sfdisk script file
O dump disk layout to sfdisk script file
Save & Exit
w write table to disk and exit
q quit without saving changes
Create a new label
g create a new empty GPT partition table
G create a new empty SGI (IRIX) partition table
o create a new empty DOS partition table
s create a new empty Sun partition table
Command (m for help): d
Partition number (1,2, default 2):
Partition 2 has been deleted.
Command (m for help): n
Partition type
p primary (1 primary, 0 extended, 3 free)
e extended (container for logical partitions)
Select (default p):
Using default response p.
Partition number (2-4, default 2):
First sector (264192-30547967, default 264192):
Last sector, +/-sectors or +/-size{K,M,G,T,P} (264192-30547967, default 30547967):
Created a new partition 2 of type 'Linux' and of size 14.5 GiB.
Partition #2 contains a ext4 signature.
Do you want to remove the signature? [Y]es/[N]o: N
Command (m for help): w
The partition table has been altered.
Syncing disks.
resize2fs /dev/mmcblk0p2
resize2fs /dev/sda2
btrfs filesystem resize max /
root@OpenWrt:~# resize2fs /dev/mmcblk0p2
resize2fs 1.44.5 (15-Dec-2018)
Filesystem at /dev/mmcblk0p2 is mounted on /; on-line resizing required
old_desc_blocks = 1, new_desc_blocks = 58
The filesystem on /dev/mmcblk0p2 is now 15141888 (1k) blocks long.
reboot
root@OpenWrt:~# df
Filesystem 1K-blocks Used Available Use% Mounted on
udev 512 0 512 0% /dev
/dev/mmcblk0p2 14670958 191357 14475505 1% /
tmpfs 945248 924 944324 0% /tmp
tmpfs 512 0 512 0% /dev
/dev/mmcblk0p1 130798 22210 108588 17% /mnt/mmcblk0p1
btrfs filesystem resize max /