通过SSH或者web访问URL, http://172.16.42.1:1471
输入帐号:root 密码:pineapplesareyummy(默认账号密码)
ssh连接:ssh root@172.16.42.1 输入密码:pineapplesareyummy
等到连接wifi获取ip后使用Putty登陆,修改/etc/opkg.conf为,(备用源http://ba.mirror.garr.it/mirrors/openwrt/attitude_adjustment/12.09/ar71xx/generic/packages/Packages.gz)
src/gz pineapple_packages http://downloads.openwrt.org/attitude_adjustment/12.09/ar71xx/generic/packages dest root / dest ram /tmp lists_dir ext /var/opkg-lists option overlay_root /overlay dest usb /sd dest sd /sd
首先将SD卡插在设备的卡槽中,然后在开机,开机之后,会看到设备为/dev/sda1
然后格式化SD卡,设备需要联网
opkg update
opkg install e2fsprogs
mkfs.ext4 /dev/sda1
将拷贝根目录下的所有文件到磁盘
mkdir /mnt/sda1 mount /dev/sda1 /mnt/sda1(如果已经挂载,跳过此步) mkdir /tmp/root mount -o bind / /tmp/root cp /tmp/root/* /mnt/sda1 -a umount /tmp/root
随后修改/etc/config/fstab修改前为
config global automount option from_fstab 1 option anon_mount 1 config global autoswap option from_fstab 1 option anon_swap 0 config mount option target /usb option device /dev/sda1 option fstype ext4 option options rw,sync option enabled 1 option enabled_fsck 0 config swap option device /dev/sda2 option enabled 0
修改后为:
config global automount option from_fstab 1 option anon_mount 1 config global autoswap option from_fstab 1 option anon_swap 0 config mount # option target /usb #此处是注释掉此行,也可直接删除 option device /dev/sda1 option fstype ext4 option options rw,sync option enabled 1 option is_rootfs 1 #添加这一行 option enabled_fsck 0 config swap option device /dev/sda2 option enabled 0
重启完成之后, 通过df命令, 查看, U盘已经挂载上去了