I doubt that's just wood carpenter's glue. It looks more like construction adhesive and that makes more sense for this location.
Gluing is like painting: the quality of the result depends greatly on the quality of the prep work.
Yes, you absolutely want to scrape as much of the old, dried adhesive off both the floor and the bottom of the transition strip as you possibly can. You could even go so far as to sand the bottom of the transition strip to get a smooth, flat surface and even sand back some of the finish on the edge of the floor (only the part that will be covered). This will ensure you've got good surface prep for the adhesive and gluing to bare wood will give you better adhesion than gluing to a finished surface.
Make sure you get the old adhesive off of the tile side of the floor, too. You should be able to chip it off with a scraper blade or possibly an old (sacrificial) flat-blade screwdriver or chisel. That tile/stone looks like it's got a bit of a rough surface, so there should already be a good key for the adhesive to grab onto on that side.
Once you've got the new adhesive down and the transition strip in place, push the strip down, wipe up any squeeze out, then weigh down the strip with some boxes full of books, weight plates, or other similar heavy items. Let the weight sit there for at least the minimum cure time listed on the adhesive you're using.