What's new

amtm amtm - the Asuswrt-Merlin Terminal Menu

  • 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!

How does AMTM's nvram save/restore compare for example to Merlins export settings function, are they not the same? Will using nvram save improve backups on top of Merlins export functionality? Or is it basically the same thing.
 
Just a thought that might help more non-tech users. I edit the amtmdiskcheck.log to keep only the last few entries 5-10 as I feel the need. AMTM offers to delete the log or leave it alone. Seeing how Jack Yaz calls nano or vi to edit the ntpMerlin conf file, I though the abilty to edit the diskcheck.log from AMTM "dcl" menu choice might be handy, or maybe I'm the only weirdo who edits the file to keep only limited newer entries. :)
 
How does AMTM's nvram save/restore compare for example to Merlins export settings function, are they not the same? Will using nvram save improve backups on top of Merlins export functionality? Or is it basically the same thing.
It is additional configuration data that is being preserved.
 
Ok thanks I guess I'm just confused. Everything in AMTM is designed to be run through the command line. I thought the purpose of AMTM was to present a sort of "UI" (menus) to users to execute those scripts. ALA Diversion, Skynet, et al.

Still - easier to update this way I guess :)
One other suggestion to make nvram backups even "easier" would be to create a cron job to execute the script on a periodic basis. The following line added to a router startup script (perhaps post-mount?) executes a backup every Sunday morning at 01:25 (feel free to change to suit your preferences and frequency):
Code:
cru a nvrambu "25 1 * * Sun sh /mnt/USBDEV/nsru/nvram-save.sh"

NOTE: Change USBDEV from above to the label of your USB drive.
 
Just a thought that might help more non-tech users. I edit the amtmdiskcheck.log to keep only the last few entries 5-10 as I feel the need. AMTM offers to delete the log or leave it alone. Seeing how Jack Yaz calls nano or vi to edit the ntpMerlin conf file, I though the abilty to edit the diskcheck.log from AMTM "dcl" menu choice might be handy, or maybe I'm the only weirdo who edits the file to keep only limited newer entries. :)
If the amtm-disk-check.log is larger then 300 KB it will truncate the file by 300 lines automatically while the disk check runs.
I find that a reasonable size to keep track when multiple devices and/or partitions exist.
 
At the moment I have NVRAM Save/Restore Utility installed onto a separate usb stick which is not all the time connected to my router, but instead I connect it to my router only occasionally when I decide to do the backup.

Does amtm "remember" which version of NVRAM Save/Restore Utility I have installed atm, and when an update is available it will show the need for the NVRAM Save/Restore Utility update, even if the usb stick containing the actual installation files of the utility is not connected to my router at all?
 
If the amtm-disk-check.log is larger then 300 KB it will truncate the file by 300 lines automatically while the disk check runs.
I find that a reasonable size to keep track when multiple devices and/or partitions exist.
Who am I to think I could get even a micro step ahead of you. :p

I'll change my perspective from looking at number of dates of dcl events knowing it truncates automagically.
 
At the moment I have NVRAM Save/Restore Utility installed onto a separate usb stick which is not all the time connected to my router, but instead I connect it to my router only occasionally when I decide to do the backup.

Does amtm "remember" which version of NVRAM Save/Restore Utility I have installed atm, and when an update is available it will show the need for the NVRAM Save/Restore Utility update, even if the usb stick containing the actual installation files of the utility is not connected to my router at all?
amtm only checks the file /jffs/scripts/nsrum.
 
Who am I to think I could get even a micro step ahead of you. :p

I'll change my perspective from looking at number of dates of dcl events knowing it truncates automagically.
Code:
if [ -f "$CHKLOG" ] && [ "$(wc -c < $CHKLOG)" -gt "300000" ]; then
... does some truncating
fi
In plain English: It just works.
 
amtm upd err / using fallback server diversion.ch

Per the diversion.ch amtm page "upd err" means that "An error occurred while retrieving update info from the scripts original source." That is very clear, I get that. I am wondering what/where the primary server for updates is (different hosts for different script authors files?) if diversion.ch is the fallback server, as seen in the err msg in the attached screenshots. I did search the forum and didn't come across anything relevant but maybe i just missed it.

I'm asking because I keep getting spurious errors from amtm on every execution of "u". Each time there are different failures "[: bad number" or "upd err." I have lots of these but only attached two here. The one thing consistent in all of them is the err msg: "! using fallback server diversion.ch".

Maybe I need to nuke and reset but everything is working beautifully other than this. Any pointers greatly appreciated.

Thanks
 

Attachments

  • upd err.png
    upd err.png
    384.5 KB · Views: 242
  • fallback server.png
    fallback server.png
    373.3 KB · Views: 207
amtm upd err / using fallback server diversion.ch

Per the diversion.ch amtm page "upd err" means that "An error occurred while retrieving update info from the scripts original source." That is very clear, I get that. I am wondering what/where the primary server for updates is (different hosts for different script authors files?) if diversion.ch is the fallback server, as seen in the err msg in the attached screenshots. I did search the forum and didn't come across anything relevant but maybe i just missed it.

I'm asking because I keep getting spurious errors from amtm on every execution of "u". Each time there are different failures "[: bad number" or "upd err." I have lots of these but only attached two here. The one thing consistent in all of them is the err msg: "! using fallback server diversion.ch".

Maybe I need to nuke and reset but everything is working beautifully other than this. Any pointers greatly appreciated.

Thanks
See your original post, please don't make multiple posts on this board.
Edit: Link to OP's post: https://www.snbforums.com/threads/amtm-upd-err-using-fallback-server-diversion-ch.61857/
 
Last edited:
Possible issue with the format disk (fd) option.

Yesterday, I used the format disk (fd) to wipe my USB and create 3 new partitions. Each partition accepted the name I entered except for the 3rd partition. No matter what I typed, it was labeled as sda3 after the reboot. I tried several times with the same result. I resolved by plugging the USB into my Win 10 computer and used the minitool partition wizard client to rename the partition.
 
@Xentrk may I ask how you would use a USB with 3 partitions? Curious as to any benefits I may be missing! :)
 
@Xentrk may I ask how you would use a USB with 3 partitions? Curious as to any benefits I may be missing! :)
When I first hopped on the asuswrt-merlin bus, each script was installed in their own partition. I had one dedicated to skynet, another for absolution (now diversion), another for entware and the last one for nvram save/restore utility and another for miscellaneous items. I've heard from another forum member that one partition is now the recommendation. I had six partitions on the USB before I reformatted. Going from 6 to 3 partitions was the first step. I'll probably narrow it down to one partition the next iteration. Following is how I have it setup now:

utils - entware
ASUS - NVRAM Save/Restore Utility
AC88U - skynet and swap

Each partition is 2.4 GB. skynet and the 2GB swap take up 91% of the room on the AC88U partition. I'm only at 5% for utils and 4% for ASUS. Since each script creates a directory, one partition is probably sufficient and may provide more flexibility in managing space on the USB.
 
Last edited:
@Xentrk thank you for that! I really appreciate your response. :)

You may need to increase your swap file size though. 2MB is much too small for Skynet to live! :D
 
I just used amtm format to create three partitions. The labels swp, ent and smb are working fine.

After bad experiences with one large partition, I have been using three partitions. But now I am thinking two partitions are a better idea.

If you have a large thumb drive or SSD, what is the problem with one large partition? There are two types of file system check on your router, quick and full. If the full runs, the router will take a long time to reboot and will not likely be OK when the boot completes. You can use tune2fs to disable full checking, but is this a good idea?

What is the problem with three partitions for Swap, Entware and the remaining as a Samba share? The order in which the partitions have their filesystems mounted appears to be random on reboot. So occasionally Skynet will not start because the swap partition is mounted afterwards.
 
@EmeraldDeer I would suggest having the swap file on the same partition as the Entware installation, at a minimum (the scripts 'live' because of both).

As for a Samba share? I have a NAS for that.

Btw, what do you consider a 'large' partition? I am currently using a 256GB USB drive and considering a 512GB USB drive in the near future (if it proves to be faster, as it is advertised as such). I don't think that fast USB drives, even at these capacities, are considered 'large' for the router though (asking, I may be wrong)?
 
Possible issue with the format disk (fd) option.

Yesterday, I used the format disk (fd) to wipe my USB and create 3 new partitions. Each partition accepted the name I entered except for the 3rd partition. No matter what I typed, it was labeled as sda3 after the reboot. I tried several times with the same result. I resolved by plugging the USB into my Win 10 computer and used the minitool partition wizard client to rename the partition.
Post the log file.
 
I just used amtm format to create three partitions. The labels swp, ent and smb are working fine.

After bad experiences with one large partition, I have been using three partitions. But now I am thinking two partitions are a better idea.

If you have a large thumb drive or SSD, what is the problem with one large partition? There are two types of file system check on your router, quick and full. If the full runs, the router will take a long time to reboot and will not likely be OK when the boot completes. You can use tune2fs to disable full checking, but is this a good idea?

What is the problem with three partitions for Swap, Entware and the remaining as a Samba share? The order in which the partitions have their filesystems mounted appears to be random on reboot. So occasionally Skynet will not start because the swap partition is mounted afterwards.
I think (although I'm not 100% certain) that using ext4 with journaling largely solves this issue. I have a 120 GB SSD drive, all 1 partition, and I've never had any booting issues save for the infamous AC86U shutting down completely during the reboot.

That said, I agree with having a separate partition for SMB sharing if you're going to use the router as a fileserver. But definitely put your swap on your entware partition for exactly the reason you stated.
 

Similar threads

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