amtm - the Asuswrt-Merlin Terminal Menu

vango44

Occasional Visitor
The amtm module keeps failing to load for me on an AC86U
I was on 384.16 and had the problem so I upgraded to 384.18 and tried wiping the JFFS
I also tried disabling all the DNSSEC & DOH features temporarily.
Here's what I'm getting:

Code:
Initializing amtm for first run
 - Created /jffs/addons/amtm directory

 Getting from fwupdate.asuswrt-merlin.net
 ! Module amtm.mod download failed
 ! using fallback server diversion.ch
 ! Module amtm.mod download failed

 All download attempts failed,
 exiting amtm now.

 Check that both domains properly resolve
 on this router:
 - fwupdate.asuswrt-merlin.net
 - diversion.ch

[email protected]:~$ nslookup diversion.ch
Server:    1.1.1.1
Address 1: 1.1.1.1 one.one.one.one

Name:      diversion.ch
Address 1: 80.74.145.140 emerson.ch-meta.net
[email protected]:~$ nslookup fwupdate.asuswrt-merlin.net
Server:    1.1.1.1
Address 1: 1.1.1.1 one.one.one.one

Name:      fwupdate.asuswrt-merlin.net
Address 1: 104.18.41.167
Address 2: 104.18.40.167
Address 3: 172.67.183.16
Address 4: 2606:4700:3035::6812:29a7
Address 5: 2606:4700:3036::ac43:b710
Address 6: 2606:4700:3037::6812:28a7
[email protected]:~$
Any ideas what the issue might be?
 

thelonelycoder

Part of the Furniture
The amtm module keeps failing to load for me on an AC86U
I was on 384.16 and had the problem so I upgraded to 384.18 and tried wiping the JFFS
I also tried disabling all the DNSSEC & DOH features temporarily.
Here's what I'm getting:

Code:
Initializing amtm for first run
 - Created /jffs/addons/amtm directory

 Getting from fwupdate.asuswrt-merlin.net
 ! Module amtm.mod download failed
 ! using fallback server diversion.ch
 ! Module amtm.mod download failed

 All download attempts failed,
 exiting amtm now.

 Check that both domains properly resolve
 on this router:
 - fwupdate.asuswrt-merlin.net
 - diversion.ch

[email protected]:~$ nslookup diversion.ch
Server:    1.1.1.1
Address 1: 1.1.1.1 one.one.one.one

Name:      diversion.ch
Address 1: 80.74.145.140 emerson.ch-meta.net
[email protected]:~$ nslookup fwupdate.asuswrt-merlin.net
Server:    1.1.1.1
Address 1: 1.1.1.1 one.one.one.one

Name:      fwupdate.asuswrt-merlin.net
Address 1: 104.18.41.167
Address 2: 104.18.40.167
Address 3: 172.67.183.16
Address 4: 2606:4700:3035::6812:29a7
Address 5: 2606:4700:3036::ac43:b710
Address 6: 2606:4700:3037::6812:28a7
[email protected]:~$
Any ideas what the issue might be?
Looks good, I have no idea what goes wrong.
 

vango44

Occasional Visitor
I'm using Asus RT-AC67U running Asuswrt-Merlin 384.13_10.
I tried executing amtm for the 1st time. It asked for my color preference; after providing that it gave me the following error. I tried again and it gave the same error message; without prompting for color preference this time.

Code:
/tmp/home/root# amtm
_____________________________________________

 Initializing amtm for first run
 ! Module amtm.mod download failed
 ! using fallback server diversion.ch
 ! Module amtm.mod download failed

 All download attempts failed,
 exiting amtm now.

 Check that both domains properly resolve
 on this router:
 - fwupdate.asuswrt-merlin.net
 - diversion.ch
Anyone else facing the same issue?
Looks like aunahin has the same issue as me but never got back with a solution. I tried a manual curl command as well and still "All download attempts failed".
I'll wait a while and decide if it's worth a factory reset.
 

dazedandlost

New Around Here
Looks like aunahin has the same issue as me but never got back with a solution. I tried a manual curl command as well and still "All download attempts failed".
I'll wait a while and decide if it's worth a factory reset.
Thank you all for the amazing resources, including this forum, and the terrific work done by everyone. Blows my mind, frankly.

Amtm is doing for me pretty much the same thing as described above. I was planning to do a clean upgrade but before I do maybe I can add an anecdote and a data point or two. I apologize that I haven’t kept a detailed record of how I got to this point, I’m not very clueful at the best of times, my memory is not the best, and I’m going to try and leave out irrelevant trivia, but anyway:

Some time ago, I noticed that amtm would run but it would not successfully “force update” but force updating Diversion (which was installed using amtm) would succeed. The router ran, and runs, without any problem that I noticed. After, among other things including a failed attempt to install skynet, I did a dirty upgrade to the latest Merlin firmware with no change. Then I did an amtm reset “r” via putty. After the reset amtm would no longer load. However, Diversion will force update and continues to run without apparent problem. I am using a vpn. At some point, I did format the jfs partition with no change.

This is what I get:

USWRT-Merlin RT-AC86U 384.18_0 Sun Jun 28 18:00:47 UTC 2020
[email protected]:/tmp/home/root# amtm
_____________________________________________

Initializing amtm for first run

Getting from fwupdate.asuswrt-merlin.net
! Module amtm.mod download failed
! using fallback server diversion.ch
! Module amtm.mod download failed

All download attempts failed,
exiting amtm now.

Check that both domains properly resolve
on this router:
- fwupdate.asuswrt-merlin.net
- diversion.ch

[email protected]:/tmp/home/root#


[email protected]:/tmp/home/root# nslookup diversion.ch
Server: 103.86.96.100
Address 1: 103.86.96.100 dns-eu-fra1.nordvpn.com

Name: diversion.ch
Address 1: 80.74.145.140 emerson.ch-meta.net
[email protected]:/tmp/home/root#


via putty:

[email protected]:/tmp/home/root# nslookup fwupdate,asuswrt-merlin.net
Server: 103.86.96.100
Address 1: 103.86.96.100 dns-eu-fra1.nordvpn.com

nslookup: can't resolve 'fwupdate,asuswrt-merlin.net'

but via Gnome terminal 3.36.1.1

:~$ nslookup fwupdate.asuswrt-merlin.net
Server: 127.0.0.53
Address: 127.0.0.53#53

Non-authoritative answer:
Name: fwupdate.asuswrt-merlin.net
Address: 104.18.40.167
Name: fwupdate.asuswrt-merlin.net
Address: 172.67.183.16
Name: fwupdate.asuswrt-merlin.net
Address: 104.18.41.167
Name: fwupdate.asuswrt-merlin.net
Address: 2606:4700:3035::6812:29a7
Name: fwupdate.asuswrt-merlin.net
Address: 2606:4700:3037::6812:28a7
Name: fwupdate.asuswrt-merlin.net
Address: 2606:4700:3036::ac43:b710


[email protected]:/tmp/home/root# diversion

i Updating ads counter...
Diversion 4.1.12 by thelonelycoder

RT-AC86U (aarch64) FW-384.18 @ 192.168.50.1

57,295 blocked domains by 1 hosts file(s)
8,334 t 550 w 18 n ads since Jul 15 17:20

/mnt/entware | Size 21.0G | Used 119.3M (1%)

d Diversion Standard enabled
c communication DivUn stats backup FWun

a ad-blocking to IP 192.168.50.2
l logging dnsmasq.log 1.8M

ep pixelserv-tls 192.168.50.2 v2.3.1

b blocking list Standard Fri @ 2:00
el edit lists 0 w 0 b 0 wb 100 yt

f follow dnsmasq.log

e exit u update more options o
____________________________________________________

What do you want to do? uu

START FILE, --- lines are not part of file
---------------------------------------------------
Diversion update log Wed, 15 Jul 2020 20:19:39 -0500
____________________________________________________


i Checking router
✔ Wireless router mode
✔ dos2unix
i Router check complete

i Checking port 443 availability
✔ Port 443 is in use by pixelserv-tls

i Probing for Entware
✔ Entware is already installed

i Getting Diversion Standard from diversion.ch
✔ ash-history.div integrated
✔ functions.div integrated
✔ mount-entware.div integrated
✔ post-conf.div integrated
✔ rc.func.div integrated
✔ rotate-logs.div integrated
✔ S80pixelserv-tls integrated
✔ update-bl.div integrated
✔ webui.zip downloaded
i webui.zip extraction
✔ webui.zip extracted
✔ write-config.div integrated
✔ yt-blocking.div integrated

i Checking white and blacklists
✔ Whitelist
✔ Blacklist
✔ Wildcard blacklist

i Checking /jffs/scripts entries
✔ dnsmasq.postconf
✔ mount-entware
✔ services-stop
✔ unmount (Diversion)
✔ unmount (swap file)

i Initializing Diversion

✔ remounted WebUI
✔ blocking list

i Restarting Dnsmasq
✔ Dnsmasq restarted

i Checking dnsmasq.conf entries
✔ Additional hosts
✔ Log facility

i (Re)starting pixelserv-tls

Shutting down pixelserv-tls... done
Starting pixelserv-tls (Diversion)... done

✔ pixelserv-tls is running

i Checking cron jobs
✔ cron file found
✔ blocking list update
✔ Rotate logs
✔ Ads counter

✔ Diversion Standard v4.1.12 update complete
---------------------------------------------------
END FILE

also, via putty:
[email protected]:/tmp/home/root# ping fwupdate,asuswrt-merlin.net
ping: bad address 'fwupdate,asuswrt-merlin.net'

but via terminal:
:~$ ping fwupdate.asuswrt-merlin.net
PING fwupdate.asuswrt-merlin.net (104.18.40.167) 56(84) bytes of data.
64 bytes from 104.18.40.167 (104.18.40.167): icmp_seq=1 ttl=53 time=94.6 ms
64 bytes from 104.18.40.167 (104.18.40.167): icmp_seq=2 ttl=53 time=98.3 ms
64 bytes from 104.18.40.167 (104.18.40.167): icmp_seq=3 ttl=53 time=127 ms
64 bytes from 104.18.40.167 (104.18.40.167): icmp_seq=4 ttl=53 time=117 ms
--------------------------

I’m a bit puzzled. I would have thought that if amtm failed to update then the default version in the firmware, if there is one, would run rather than amtm refusing to run at all. Anyway, sorry for the wall of text but I hope some of it helps.
 

dazedandlost

New Around Here
I notice a typo above. If I enter the address correctly in putty, I get:
--
@RT-AC86U-4350:/tmp/home/root# nslookup fwupdate.asuswrt-merlin.net
Server: 103.86.96.100
Address 1: 103.86.96.100 dns-eu-fra1.nordvpn.com

Name: fwupdate.asuswrt-merlin.net
Address 1: 172.67.183.16
Address 2: 104.18.41.167
Address 3: 104.18.40.167
 

thelonelycoder

Part of the Furniture
Thank you all for the amazing resources, including this forum, and the terrific work done by everyone. Blows my mind, frankly.

Amtm is doing for me pretty much the same thing as described above. I was planning to do a clean upgrade but before I do maybe I can add an anecdote and a data point or two. I apologize that I haven’t kept a detailed record of how I got to this point, I’m not very clueful at the best of times, my memory is not the best, and I’m going to try and leave out irrelevant trivia, but anyway:

Some time ago, I noticed that amtm would run but it would not successfully “force update” but force updating Diversion (which was installed using amtm) would succeed. The router ran, and runs, without any problem that I noticed. After, among other things including a failed attempt to install skynet, I did a dirty upgrade to the latest Merlin firmware with no change. Then I did an amtm reset “r” via putty. After the reset amtm would no longer load. However, Diversion will force update and continues to run without apparent problem. I am using a vpn. At some point, I did format the jfs partition with no change.

This is what I get:

USWRT-Merlin RT-AC86U 384.18_0 Sun Jun 28 18:00:47 UTC 2020
[email protected]:/tmp/home/root# amtm
_____________________________________________

Initializing amtm for first run

Getting from fwupdate.asuswrt-merlin.net
! Module amtm.mod download failed
! using fallback server diversion.ch
! Module amtm.mod download failed

All download attempts failed,
exiting amtm now.

Check that both domains properly resolve
on this router:
- fwupdate.asuswrt-merlin.net
- diversion.ch

[email protected]:/tmp/home/root#


[email protected]:/tmp/home/root# nslookup diversion.ch
Server: 103.86.96.100
Address 1: 103.86.96.100 dns-eu-fra1.nordvpn.com

Name: diversion.ch
Address 1: 80.74.145.140 emerson.ch-meta.net
[email protected]:/tmp/home/root#


via putty:

[email protected]:/tmp/home/root# nslookup fwupdate,asuswrt-merlin.net
Server: 103.86.96.100
Address 1: 103.86.96.100 dns-eu-fra1.nordvpn.com

nslookup: can't resolve 'fwupdate,asuswrt-merlin.net'

but via Gnome terminal 3.36.1.1

:~$ nslookup fwupdate.asuswrt-merlin.net
Server: 127.0.0.53
Address: 127.0.0.53#53

Non-authoritative answer:
Name: fwupdate.asuswrt-merlin.net
Address: 104.18.40.167
Name: fwupdate.asuswrt-merlin.net
Address: 172.67.183.16
Name: fwupdate.asuswrt-merlin.net
Address: 104.18.41.167
Name: fwupdate.asuswrt-merlin.net
Address: 2606:4700:3035::6812:29a7
Name: fwupdate.asuswrt-merlin.net
Address: 2606:4700:3037::6812:28a7
Name: fwupdate.asuswrt-merlin.net
Address: 2606:4700:3036::ac43:b710


[email protected]:/tmp/home/root# diversion

i Updating ads counter...
Diversion 4.1.12 by thelonelycoder

RT-AC86U (aarch64) FW-384.18 @ 192.168.50.1

57,295 blocked domains by 1 hosts file(s)
8,334 t 550 w 18 n ads since Jul 15 17:20

/mnt/entware | Size 21.0G | Used 119.3M (1%)

d Diversion Standard enabled
c communication DivUn stats backup FWun

a ad-blocking to IP 192.168.50.2
l logging dnsmasq.log 1.8M

ep pixelserv-tls 192.168.50.2 v2.3.1

b blocking list Standard Fri @ 2:00
el edit lists 0 w 0 b 0 wb 100 yt

f follow dnsmasq.log

e exit u update more options o
____________________________________________________

What do you want to do? uu

START FILE, --- lines are not part of file
---------------------------------------------------
Diversion update log Wed, 15 Jul 2020 20:19:39 -0500
____________________________________________________


i Checking router
✔ Wireless router mode
✔ dos2unix
i Router check complete

i Checking port 443 availability
✔ Port 443 is in use by pixelserv-tls

i Probing for Entware
✔ Entware is already installed

i Getting Diversion Standard from diversion.ch
✔ ash-history.div integrated
✔ functions.div integrated
✔ mount-entware.div integrated
✔ post-conf.div integrated
✔ rc.func.div integrated
✔ rotate-logs.div integrated
✔ S80pixelserv-tls integrated
✔ update-bl.div integrated
✔ webui.zip downloaded
i webui.zip extraction
✔ webui.zip extracted
✔ write-config.div integrated
✔ yt-blocking.div integrated

i Checking white and blacklists
✔ Whitelist
✔ Blacklist
✔ Wildcard blacklist

i Checking /jffs/scripts entries
✔ dnsmasq.postconf
✔ mount-entware
✔ services-stop
✔ unmount (Diversion)
✔ unmount (swap file)

i Initializing Diversion

✔ remounted WebUI
✔ blocking list

i Restarting Dnsmasq
✔ Dnsmasq restarted

i Checking dnsmasq.conf entries
✔ Additional hosts
✔ Log facility

i (Re)starting pixelserv-tls

Shutting down pixelserv-tls... done
Starting pixelserv-tls (Diversion)... done

✔ pixelserv-tls is running

i Checking cron jobs
✔ cron file found
✔ blocking list update
✔ Rotate logs
✔ Ads counter

✔ Diversion Standard v4.1.12 update complete
---------------------------------------------------
END FILE

also, via putty:
[email protected]:/tmp/home/root# ping fwupdate,asuswrt-merlin.net
ping: bad address 'fwupdate,asuswrt-merlin.net'

but via terminal:
:~$ ping fwupdate.asuswrt-merlin.net
PING fwupdate.asuswrt-merlin.net (104.18.40.167) 56(84) bytes of data.
64 bytes from 104.18.40.167 (104.18.40.167): icmp_seq=1 ttl=53 time=94.6 ms
64 bytes from 104.18.40.167 (104.18.40.167): icmp_seq=2 ttl=53 time=98.3 ms
64 bytes from 104.18.40.167 (104.18.40.167): icmp_seq=3 ttl=53 time=127 ms
64 bytes from 104.18.40.167 (104.18.40.167): icmp_seq=4 ttl=53 time=117 ms
--------------------------

I’m a bit puzzled. I would have thought that if amtm failed to update then the default version in the firmware, if there is one, would run rather than amtm refusing to run at all. Anyway, sorry for the wall of text but I hope some of it helps.
Diversion uses a curl connect timeout of 10s, with 3 tries, while amtm has a connect timeout of 3s with 2 tries and a max transfer time of 8s per file.
Maybe your resolving is slow, that would explain why Diversion updates successfully while amtm times out.
There is no way to change the times initially as this is the built in read-only amtm file.
See if you can bring down latency somehow.
 

dazedandlost

New Around Here
Diversion uses a curl connect timeout of 10s, with 3 tries, while amtm has a connect timeout of 3s with 2 tries and a max transfer time of 8s per file.
Maybe your resolving is slow, that would explain why Diversion updates successfully while amtm times out.
There is no way to change the times initially as this is the built in read-only amtm file.
See if you can bring down latency somehow.
Thank you, I will. Is it possible to point amtm at a local copy of the file?
 

Kenji

Occasional Visitor
I may have a stupid question .. is it possible to move amtm with all scripts? I have two usb sticks with 2 partitions each. USB 1 (partion swap file + partions empty), USB 2 (partion amtm + partion empty). I would like to move the USB 1 to the empty partition that is already pre-matematized. I would like to move amtm with the scripts. So that I don't have to reinstall amtm.

lg.
 

Attachments

QuikSilver

Very Senior Member
I may have a stupid question .. is it possible to move amtm with all scripts? I have two usb sticks with 2 partitions each. USB 1 (partion swap file + partions empty), USB 2 (partion amtm + partion empty). I would like to move the USB 1 to the empty partition that is already pre-matematized. I would like to move amtm with the scripts. So that I don't have to reinstall amtm.

lg.
AMTM started a few firmwares back being "baked into" the firmware so you would only need to reinstall those scripts. There are a few threads where people have asked how to copy or move scripts from one USB drive to another. Try searching, should show a few recent ones from within past month or so.
 

jsbeddow

Senior Member
I agree with @QuikSilver, and would add that it is often not all that hard to just format a USB drive from within amtm (ext4 with journaling is recommended), then reinstall the scripts starting with Diversion. Use the backup function from within Diversion to first get local backups (to your computer and to jffs). Upon reinstall, Diversion will find the backup on jffs. Skynet will pickup the whitelists from Diversion, at most you might have to restore other blocked ranges/ countries manually.
 

Kenji

Occasional Visitor
thank's for the Tipps. I have now done this with the backup and the router ran without problems for 3 days. Now I had to restart it via the web interface. Now I have the problem that the swapfile is no longer found .. despite being correctly mounted, amtm does not find the swapfile. the USB stick has 3 partitions. 1. for amtm, 2. for the swapfile, 3 other stuff.
I've had the problem with amtm for several months and have always been desperate. now I've tried this with a new USB stick and again the same problem. the Disk Checker Script was always installed. since the router can no longer find a swapfile, I don't have an internet connection (dnscyrpt dead). I see that the partitions exist (see screen)

Sorry for the bad translation. but I try to read a lot in forum here. which is difficult. thanks
 

Attachments

jsbeddow

Senior Member
Simple answer: there is zero need to have more than one partition, other than perhaps one for so-called "other stuff". Stop trying to have a separate "dedicated" swap partition (the very old recommendation), or a swap file placed on a second partition (Entware does not really play well with this, and it is completely unnecessary). Place all the scripts and Entware files on the same partition as the amtm created swap file, and be done with it.
 

possibly2

New Around Here
Diversion uses a curl connect timeout of 10s, with 3 tries, while amtm has a connect timeout of 3s with 2 tries and a max transfer time of 8s per file.
Maybe your resolving is slow, that would explain why Diversion updates successfully while amtm times out.
There is no way to change the times initially as this is the built in read-only amtm file.
See if you can bring down latency somehow.
I have the same issue that amtm will not install anything..

Seem like a problem on the other side:
[email protected]_B1-BC38:/tmp/home/root# wget -v https://fwupdate.asuswrt-merlin.net/amtm_fw
--2020-07-26 15:26:37-- https://fwupdate.asuswrt-merlin.net/amtm_fw
Resolving fwupdate.asuswrt-merlin.net... 2606:4700:3036::ac43:b710, 104.18.41.167, 172.67.183.16, ...
Connecting to fwupdate.asuswrt-merlin.net|2606:4700:3036::ac43:b710|:443... failed: Network is unreachable.
Connecting to fwupdate.asuswrt-merlin.net|104.18.41.167|:443... connected.
HTTP request sent, awaiting response... 301 Moved Permanently
Location: https://diversion.ch/amtm_fw [following]
--2020-07-26 15:26:41-- https://diversion.ch/amtm_fw
Resolving diversion.ch... 80.74.145.140
Connecting to diversion.ch|80.74.145.140|:443... connected.
HTTP request sent, awaiting response... 301 Moved Permanently
Location: https://diversion.ch/amtm_fw/ [following]
--2020-07-26 15:26:44-- https://diversion.ch/amtm_fw/
Reusing existing connection to diversion.ch:443.
HTTP request sent, awaiting response... 403 Forbidden
2020-07-26 15:26:44 ERROR 403: Forbidden.

[email protected]_B1-BC38:/tmp/home/root# wget -v https://diversion.ch/amtm_fw
--2020-07-26 15:26:58-- https://diversion.ch/amtm_fw
Resolving diversion.ch... 80.74.145.140
Connecting to diversion.ch|80.74.145.140|:443... connected.
HTTP request sent, awaiting response... 301 Moved Permanently
Location: https://diversion.ch/amtm_fw/ [following]
--2020-07-26 15:27:02-- https://diversion.ch/amtm_fw/
Reusing existing connection to diversion.ch:443.
HTTP request sent, awaiting response... 403 Forbidden
2020-07-26 15:27:02 ERROR 403: Forbidden.

Seems like amtm install is broken?


Rgds,
P
 

Adamm

Part of the Furniture
Seem like a problem on the other side:
Your trying to wget a directory which is why your getting the 403 errors;

Code:
[email protected]:/tmp/home/root# wget -v https://fwupdate.asuswrt-merlin.net/amtm_fw/amtm.mod
--2020-07-26 23:48:34--  https://fwupdate.asuswrt-merlin.net/amtm_fw/amtm.mod
Resolving fwupdate.asuswrt-merlin.net... 2606:4700:3035::6812:29a7, 2606:4700:3037::6812:28a7, 2606:4700:3036::ac43:b710, ...
Connecting to fwupdate.asuswrt-merlin.net|2606:4700:3035::6812:29a7|:443... connected.
HTTP request sent, awaiting response... 301 Moved Permanently
Location: https://diversion.ch/amtm_fw/amtm.mod [following]
--2020-07-26 23:48:34--  https://diversion.ch/amtm_fw/amtm.mod
Resolving diversion.ch... 80.74.145.140
Connecting to diversion.ch|80.74.145.140|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 22697 (22K) [audio/x-mod]
Saving to: 'amtm.mod'

amtm.mod                                                            100%[=================================================================================================================================================================>]  22.17K  --.-KB/s    in 0s

2020-07-26 23:48:36 (150 MB/s) - 'amtm.mod' saved [22697/22697]
 

Latest threads

Sign Up For SNBForums Daily Digest

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