How to expand filesystem or resize the partition within osmc on Rpi2,3

Actually, it doesn’t - it creates a new partition to fill the card. There’s nothing built in to OSMC to do what you want AFAIK. You can’t expand a mounted partition so you would have to issue parted commands while running from the 4G card.

If you don’t want to do that and you do have the 4G card still, you can use [How to] Make periodic backups of whole OSMC system. Running from the smaller card, download osmc-restore from the git and go

sudo ./osmc-restore -f /