What's new

AiMesh nodes - best practices / scripts / etc

  • SNBForums Code of Conduct

    SNBForums is a community for everyone, no matter what their level of experience.

    Please be tolerant and patient of others, especially newcomers. We are all here to share and learn!

    The rules are simple: Be patient, be nice, be helpful or be gone!

bibikalka

Regular Contributor
I have a fairly feeble AiMesh setup, AC86u as the main router, and AC68u as an AiMesh node.

My main router is rebooted daily, but the node was just sitting there for weeks of uptime. Anyway, it would become somewhat flaky after a while - so then why not just reboot the AiMesh node nightly too and have it fresh in the morning?

Anyway, here is what I did. Ssh'ed into the AiMesh node, enabled jffs scripts:
Code:
nvram set jffs2_scripts="1"
nvram commit

And then I enabled the cron job for the daily reboot, and a restoration of the ssh keys so I could login from my main node without password.

Code:
admin@RT-AC68U-FF68:/jffs/scripts# cat init-start
#!/bin/sh
echo 4194304 > /proc/sys/kernel/pid_max
cru a ScheduledReboot "5 4 * * * /sbin/service 'reboot'"


admin@RT-AC68U-FF68:/jffs/scripts# cat services-start
#!/bin/sh

# Check Whether id_dropbear Private Key Exist
if [ ! -f "/tmp/home/root/.ssh/id_dropbear" ]; then
   /bin/cp -p /jffs/.ssh/id_rsa /tmp/home/root/.ssh/id_dropbear
   /bin/cp -p /jffs/.ssh/authorized_keys  /tmp/home/root/.ssh/
   /bin/cp -p /jffs/.ssh/known_hosts  /tmp/home/root/.ssh/
fi

Of course, first the correct files need to be saved in /jffs/.ssh. There are some more details here - link

It's also possible to setup some elements of amtm, such as the date restoration, and addons that don't need Entware.

Does anyone have any other good stuff to suggest for the AiMesh node specifically?
 

Latest threads

Support SNBForums w/ Amazon

If you'd like to support SNBForums, just use this link and buy anything on Amazon. Thanks!

Sign Up For SNBForums Daily Digest

Get an update of what's new every day delivered to your mailbox. Sign up here!
Top