Okay, thanks for clarifying, but please keep in mind that I'm not a true novice and yet so far, far from an expert, so I think it could come in handy to document it somewhere (if it hasn't already been), to prevent more questions... Just my two cents.
As for the pace of the project, I feel like we have hit maturity in the script/rules and are ready to mark it as stable. There are no outstanding bugs (that I'm aware of) and functionality is at a point I am happy with that can work around most users setups, along with things like smart lock file/usb detection.
It has definitely made a huge progress, no doubt about it and I truly appreciate and respect your effort and commitment in helping others out. Hat's off to you.
Next up: a sh*tload of data... Might be just a coincidence, but after following your instructions (unban all), I did a clean (?) reboot, initiated from the WebUI, and noticed this in my logfiles after the restart:
Code:
Jun 14 07:45:53 dMP17 Skynet: [ERROR] USB Not Found After 6 Retries - Please Fix Immediately!
Jun 14 07:45:53 dMP17 Skynet: [ERROR] When Fixed Run ( sh /jffs/scripts/firewall debug restart )
/dev/sdb1 has already been mounted at this point, which is a small 4 Gb mini USB 2.0 thumb drive used only for nvram-save (backups are stored on the stick too, but copied to a NAS when finished). Swap on /dev/sda1 (on a Kingston 64Gb USB 3.0 DataTraveler, with two partitions: linux-swap and data (=ext4)) has already been mounted and activated too, prior to the error mentioned above. So the USB stick is there, just the partition Skynet is looking for (datat) appears to not have been mounted yet. These are the loglines prior to the error above:
Code:
<snip>
Jun 14 07:45:37 dMP17 kernel: scsi 0:0:0:0: Direct-Access Kingston DataTraveler 3.0 PMAP PQ: 0 ANSI: 6
Jun 14 07:45:37 dMP17 kernel: sd 0:0:0:0: Attached scsi generic sg0 type 0
Jun 14 07:45:37 dMP17 kernel: scsi 1:0:0:0: Direct-Access Generic STORAGE DEVICE 0250 PQ: 0 ANSI: 0
Jun 14 07:45:38 dMP17 kernel: sd 1:0:0:0: Attached scsi generic sg1 type 0
Jun 14 07:45:38 dMP17 kernel: sd 1:0:0:0: [sdb] 7698432 512-byte logical blocks: (3.94 GB/3.67 GiB)
Jun 14 07:45:38 dMP17 kernel: sd 1:0:0:0: [sdb] Write Protect is off
Jun 14 07:45:38 dMP17 kernel: sd 1:0:0:0: [sdb] Mode Sense: 0b 00 00 08
Jun 14 07:45:38 dMP17 kernel: sd 1:0:0:0: [sdb] Assuming drive cache: write through
Jun 14 07:45:38 dMP17 kernel: sd 1:0:0:0: [sdb] Assuming drive cache: write through
Jun 14 07:45:38 dMP17 kernel: sdb: sdb1
Jun 14 07:45:38 dMP17 kernel: sd 1:0:0:0: [sdb] Assuming drive cache: write through
Jun 14 07:45:38 dMP17 kernel: sd 1:0:0:0: [sdb] Attached SCSI removable disk
Jun 14 07:45:38 dMP17 kernel: sd 0:0:0:0: [sda] 122945536 512-byte logical blocks: (62.9 GB/58.6 GiB)
Jun 14 07:45:38 dMP17 kernel: sd 0:0:0:0: [sda] Write Protect is off
Jun 14 07:45:38 dMP17 kernel: sd 0:0:0:0: [sda] Mode Sense: 23 00 00 00
Jun 14 07:45:38 dMP17 kernel: sd 0:0:0:0: [sda] Assuming drive cache: write through
Jun 14 07:45:38 dMP17 kernel: sd 0:0:0:0: [sda] Assuming drive cache: write through
Jun 14 07:45:38 dMP17 kernel: sda: sda1 sda2
Jun 14 07:45:38 dMP17 kernel: sd 0:0:0:0: [sda] Assuming drive cache: write through
Jun 14 07:45:38 dMP17 kernel: sd 0:0:0:0: [sda] Attached SCSI removable disk
Jun 14 07:45:38 dMP17 start_nat_rules: apply the nat_rules(/tmp/nat_rules_eth0_eth0)!
Jun 14 07:45:39 dMP17 kernel: EXT2-fs (sdb1): warning: mounting unchecked fs, running e2fsck is recommended
Jun 14 07:45:39 dMP17 hotplug: USB ext2 fs at /dev/sdb1 mounted on /tmp/mnt/ASUS
Jun 14 07:45:39 dMP17 usb: USB ext2 fs at /dev/sdb1 mounted on /tmp/mnt/ASUS.
Jun 14 07:45:40 dMP17 kernel: nf_conntrack_rtsp v0.6.21 loading
Jun 14 07:45:40 dMP17 kernel: nf_nat_rtsp v0.6.21 loading
Jun 14 07:45:40 dMP17 script: Running /jffs/scripts/post-mount (args: /tmp/mnt/ASUS)
Jun 14 07:45:40 dMP17 kernel: Adding 524284k swap on /dev/sda1. Priority:-1 extents:1 across:524284k
Jun 14 07:45:40 dMP17 script: Running /jffs/scripts/firewall-start (args: eth0)
I assume the ext2 warning shows up just because it's a non-journaling fs. For some reason, I don't know why, as both the USB-drives are permanently connected at the back of the router, on the highest point in the living room, where even my cats can't get to, /dev/sda2 appears to have an issue, or at least diskmon believes so, because shortly after the Skynet error, the log shows:
Code:
Jun 14 07:45:57 dMP17 kernel: EXT4-fs (sda2): recovery complete
Jun 14 07:45:57 dMP17 hotplug: USB ext4 fs at /dev/sda2 mounted on /tmp/mnt/data
Jun 14 07:45:57 dMP17 usb: USB ext4 fs at /dev/sda2 mounted on /tmp/mnt/data.
Jun 14 07:45:57 dMP17 kernel: EXT4-fs (sda2): mounted filesystem with ordered data mode. Opts: user_xattr
Jun 14 07:45:57 dMP17 rc_service: ntp 1129:notify_rc restart_diskmon
Jun 14 07:45:57 dMP17 disk_monitor: Finish
Jun 14 07:45:58 dMP17 client: bound xxx.xxx.xxx.xxx via xxx.xxx.xxx.xxx during 3600 seconds.
Jun 14 07:45:58 dMP17 script: Running /jffs/scripts/post-mount (args: /tmp/mnt/data)
Jun 14 07:45:59 dMP17 start_nat_rules: apply the nat_rules(/tmp/nat_rules_eth0_eth0)!
Jun 14 07:46:00 dMP17 rc_service: service 1303:notify_rc restart_dnsmasq
Jun 14 07:46:00 dMP17 rc_service: waitting "start_firewall" via ...
Jun 14 07:46:00 dMP17 monitor: be idle
Jun 14 07:46:01 dMP17 script: Running /jffs/scripts/firewall-start (args: eth0)
Jun 14 07:46:01 dMP17 dnsmasq: exiting on receipt of SIGTERM
Jun 14 07:46:01 dMP17 ntpd: ntpd 4.2.8p9-win@1.3728 Sat Mar 18 09:20:25 UTC 2017 (2): Starting
Jun 14 07:46:01 dMP17 ntpd: Command line: ntpd -c /jffs/etc/ntp.conf
Jun 14 07:46:01 dMP17 ntpd: proto: precision = 1.682 usec (-19)
Jun 14 07:46:01 dMP17 ntpd: Listen normally on 0 lo 127.0.0.1:123
Jun 14 07:46:01 dMP17 ntpd: Listen normally on 1 br0 192.168.1.1:123
Jun 14 07:46:01 dMP17 ntpd: Listening on routing socket on fd #18 for interface updates
Jun 14 07:46:01 dMP17 config: Appending content of /jffs/configs/dnsmasq.conf.add.
Jun 14 07:46:01 dMP17 script: Running /jffs/scripts/dnsmasq.postconf (args: /etc/dnsmasq.conf)
Jun 14 07:46:02 dMP17 marco: Started ntpd from /jffs/scripts/services-start.
Jun 14 07:46:03 dMP17 marco: AB-Solution added entries via /jffs/scripts/post-mount
Jun 14 07:46:03 dMP17 marco: Started pixelserv-tls (AB-Solution) from /jffs/scripts/services-start.
Jun 14 07:46:03 dMP17 pixelserv: pixelserv-tls version: v35.HZ12.Kj compiled: May 30 2017 22:33:13 options: 192.168.1.2
Jun 14 07:46:03 dMP17 rc_service: service 1361:notify_rc restart_httpd
Jun 14 07:46:03 dMP17 rc_service: waitting "restart_dnsmasq" via ...
Jun 14 07:46:03 dMP17 pixelserv: Listening on :192.168.1.2:80
Jun 14 07:46:03 dMP17 pixelserv: Listening on :192.168.1.2:443
Jun 14 07:46:04 dMP17 marco: AB-Solution added entries via ab_dnsmasq_postconf.sh
Jun 14 07:46:04 dMP17 marco: AB-Solution linked ab_dnsmasq_postconf.sh via /jffs/scripts/dnsmasq.postconf
Jun 14 07:46:04 dMP17 kernel: DROP IN=eth0 OUT= MAC=2c:4d:54:49:71:30:00:01:5c:79:5c:46:08:00 SRC=93.159.194.117 DST=xxx.xxx.xxx.xxx LEN=40 TOS=0x00 PREC=0x00 TTL=245 ID=51139 PROTO=TCP SPT=11256 DPT=2323 SEQ=0 ACK=0 WINDOW=65535 RES=0x00 SYN URGP=0
Jun 14 07:46:04 dMP17 RT-AC68U_WHITE: start httpd
Jun 14 07:46:06 dMP17 rc_service: hotplug 996:notify_rc restart_nasapps
Jun 14 07:46:06 dMP17 iTunes: daemon is stopped
Jun 14 07:46:06 dMP17 Server: daemon is stopped
Jun 14 07:46:08 dMP17 Server: smb daemon is stopped
Jun 14 07:46:08 dMP17 kernel: gro disabled
Jun 14 07:46:08 dMP17 Timemachine: daemon is stopped
Jun 14 07:46:08 dMP17 kernel: gro enabled with interval 2
Jun 14 07:46:13 dMP17 Skynet: [INFO] Startup Initiated ... ... ...
Jun 14 07:46:13 dMP17 kernel: ip_set: protocol 6
Jun 14 07:46:15 dMP17 Skynet: [Complete] 0 IPs / 0 Ranges Banned. 0 New IPs / 0 New Ranges Banned. 0 Inbound / 0 Outbound Connections Blocked! [3s]
I assume the first line in the part above shows how diskmon uses the journaling fs to check and/or fixes any errors it has detected. Please do correct me if I'm wrong. Skynet still appears to be running in the background, as it apparently found a way to restart or becomes active when /mnt/data gets mounted
@ 07:46:13. Not sure whether I need to restart in debug mode? It appears to run just fine, even as we speak:
Code:
Jun 14 09:00:01 dMP17 Skynet: [Complete] 0 IPs / 0 Ranges Banned. 0 New IPs / 0 New Ranges Banned. 0 Inbound / 0 Outbound Connections Blocked! [1s]
Maybe it's nothing, but as it differs from regular behaviour, I thought it might be worth mentioning.
And yes, I'm an autist and I'm proud of it