I faced this problem on two different machines (both lightdm + plasma desktop, on both I happily used this combination on Ubuntu 16.04 but once I upgraded to 18.04, or soon afterwards, I lost all my groups).
Switched to sddm on both, it helped. So mayhaps lightdm should be dropped or downgraded, the issue is fairly critical (usb doesn't work, sudo has issues, pluggable devices don't work).
Picture in my case:
- after lightdm login
$ id
uid=1000(marcin) gid=1000(marcin) groups=1000(marcin)
- after sddm login
$ id
uid=1000(marcink) gid=1000(marcink) groups=1000(marcin),4(adm),24(cdrom),27(sudo),30(dip),46(plugdev),109(netdev),113(lpadmin),128(sambashare),147(lxd),999(docker)
I faced this problem on two different machines (both lightdm + plasma desktop, on both I happily used this combination on Ubuntu 16.04 but once I upgraded to 18.04, or soon afterwards, I lost all my groups).
Switched to sddm on both, it helped. So mayhaps lightdm should be dropped or downgraded, the issue is fairly critical (usb doesn't work, sudo has issues, pluggable devices don't work).
Picture in my case:
- after lightdm login
$ id
uid=1000(marcin) gid=1000(marcin) groups=1000(marcin)
- after sddm login
$ id 1000(marcink) gid=1000(marcink) groups= 1000(marcin) ,4(adm) ,24(cdrom) ,27(sudo) ,30(dip) ,46(plugdev) ,109(netdev) ,113(lpadmin) ,128(sambashare ),147(lxd) ,999(docker)
uid=