A drivetrain consists of all your components such as a crankset, chain, derailleurs, and chainrings. A groupset is a set of components that are optimized to work best with each other. A complete groupset will come with components that are all from the same family of parts like Shimano XT or SRAM GX Eagle.