You can sprinkle Epsom salts around or near the hole entrances to keep the groundhog away. If these groundhogs eat your plants, you can try to place a plate filled with the salts. You must replace it after the rain.