SSID and Program lost on power off and up (or no)

I have two Yun, that contain a temperature recorder. Each 10 minutes, the date, time and 3 temperatures are recorded into a file.
The #1 is mounted near by the solar water heating system for monitoring purpose at the bottom of the building, the #2 is used as development system connected on my laptop PC.

If the power goes down and up, the #1 loose the program and parameters. The supply is a IPhone USB block 230 VAC charger. I must go down the staircases with my portable PC, set the SSID parameters of the Wifi and reload the Arduino part of the program.
The #2 is powered by the USB of my PC; each day a switch it on/off and it recover all parameters, and re-run the Arduino program.
Any idea why? Does the rise of fall time of the 5V have a mentioned speed value in order to keep the program and Wifi parameters?
I noticed that the +5V is no more 4.56V on the Yun.