php -i | grep php.ini komutu ile hangi dizinde olduğunu bulabilirsin. Daha sonra safe_mode ile alakalı satırı bulup değişikliği yapabilirsin.