树莓派启动报错
1、问题描述:
给树莓派更新了内核后,启动时出现该问题。
2、解决方法
sudo vi /etc/rc.local #打开启动失败的rc.local文件
#!/bin/sh -e # 将该行改成第2行就行了
#!/bin/bash #酱紫...
# 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.
# Print the IP address
_IP=$(hostname -I) || true
if [ "$_IP" ]; then
printf "My IP address is %s\n" "$_IP"
fi
config wlan0 192.168.1.117 #固定IP地址
exit 0
3、完成后的测试
sudo reboot # 重启树莓派
成功!