I realize you've re-installed Ubuntu, so the below is largely moot; however, in case somebody else has a similar problem, I'll respond fully. You may want to skip to the last paragraph for advice on avoiding this sort of problem in the future....
It sounds like /dev/sdb2
had been an extended partition that held the logical partition, /dev/sdb5
. Ordinarily, partitioning tools don't let you change the type of an extended partition, since doing so is almost always a Bad Idea. It sounds like you used some badly-written software that didn't impose such a sensible restriction, though -- or perhaps you used a low-level disk editor, which you should never do unless you're an expert on whatever you're trying to edit. In any event....
The first thing you should do is to perform a low-level backup of the entire disk, or at least of /dev/sdb2
. Something like this should do the trick:
sudo if=/dev/sdb of=/path/to/lots/of/space/sdb-backup.img
This command backs up /dev/sdb
to /path/to/lots/of/space/sdb-backup.img
, which as the name implies should be a directory with lots of free space -- at least 119.2 GiB, in your case, since that's the size of /dev/sdb
. Having a backup will enable you to recover to the current state, in case something further goes wrong -- as it might well, since any recovery attempt runs the risk of creating new and worse problems.
With the backup made, the best recovery approach is probably to delete /dev/sdb2
using Linux's fdisk
. I emphasize the use of fdisk
because I know it won't write into /dev/sdb2
, just delete the data structures that define it. I don't know if whatever you used to change the type of /dev/sdb2
might do more than this.
With that done, use TestDisk to recover your lost partition(s). This tool scans a disk for signs of filesystems and other data structures that reside in a partition, such as LVM definitions. Note that you want TestDisk to recover your LVM, not the logical volumes that reside inside it. Thus, if TestDisk gives you the option of recovering an LVM or (say) an ext4fs partition, tell it to recover the LVM. With any luck, when you reboot you'll see your LVM restored.
Using an LVM can simplify filesystem changes within the LVM, but if you need to reallocate space outside of the LVM, the LVM actually complicates matters. Some versions of GParted won't touch an LVM physical volume (partition), since it doesn't know how to resize it. To resize an LVM setup, you must jump through some extra hoops, which are described (among other places) here and here. I generally prefer creating two or three LVM partitions of varying size so that I can move logical volumes off of one of them, delete it, and re-allocate space outside of the LVM as necessary.