Add this line, just above exit 0 (use copy/paste):
iwconfig wlan0 power off
So it should become something like this (example):
#!/bin/sh -e
#
# rc.local
#
# This script is executed at the end of each multiuser runlevel.
# Make sure that the script will "exit 0" on success or any other
# value on error.
#
# In order to enable or disable this script just change the execution
# bits.
#
# By default this script does nothing.
iwconfig wlan0 power off
exit 0
Save, close and reboot. The problem should be fixed permanently.
OK, this appears to be an effective workaround: disable power management for the wireless chipset. As follows:
Applications - Accessories - Terminal
type (use copy/paste):
gksudo gedit /etc/rc.local
Press Enter.
Add this line, just above exit 0 (use copy/paste):
iwconfig wlan0 power off
So it should become something like this (example):
#!/bin/sh -e
#
# rc.local
#
# This script is executed at the end of each multiuser runlevel.
# Make sure that the script will "exit 0" on success or any other
# value on error.
#
# In order to enable or disable this script just change the execution
# bits.
#
# By default this script does nothing.
iwconfig wlan0 power off
exit 0
Save, close and reboot. The problem should be fixed permanently.
Please report your findings.