The published domestic to international offline connection time at SFO is 1 hour.
From Terminal 2 to International G, you can walk or take the AirTrain. It's a nice 15 minutes or so either way, but the thing you really have to watch out for is time to check in and clear security, as there are no airside connections out of Terminal 2 to any of the other terminals.