The optimal temperature and reaction time for the preparation of benzocaine from p-aminobenzoic acid and ethanol can vary depending on the specific method and catalyst used. However, a common method involves using a sulfuric acid catalyst.In this case, the optimal temperature is typically around 100-110C, and the reaction time is approximately 60-90 minutes. Under these conditions, the yield of benzocaine can be up to 85-90%. It is important to note that reaction conditions may need to be adjusted depending on the specific setup and reagent purity.