What's new

[Release] AB-Solution 3 - The Ad Blocking Solution

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

Status
Not open for further replies.
thats a weird one.... AB3 has a function called set_perms_unix_format which is called several places in the script to set permissions.
Code:
set_perms_unix_format(){
if [ -d $abSolutionPath ];then
    # to files in installDir
    chmod -R a=r,a+X,u+w $abSolutionPath
    if [ "$(ls -A $abSolutionPath/$scriptsDir)" ]; then
        chmod 0755 $abSolutionPath/$scriptsDir/*
    fi
    if [ "$(ls -A $abSolutionPath/$addonDir)" ]; then
        chmod 0755 $abSolutionPath/$addonDir/*
    fi
fi
# to this script
if [ -f $abSolutionDevice/$appScript ];then
    chmod 0755 $abSolutionDevice/$appScript
    dos_to_unix $abSolutionDevice/$appScript
fi
# to entware init.d
if [ -d $initDir ];then
    chmod 0755 $initDir/*
fi

is the device itself set read only? ... can you type mount at the command line and see what the output says?
 
thats a weird one.... AB3 has a function called set_perms_unix_format which is called several places in the script to set permissions.
Code:
set_perms_unix_format(){
if [ -d $abSolutionPath ];then
    # to files in installDir
    chmod -R a=r,a+X,u+w $abSolutionPath
    if [ "$(ls -A $abSolutionPath/$scriptsDir)" ]; then
        chmod 0755 $abSolutionPath/$scriptsDir/*
    fi
    if [ "$(ls -A $abSolutionPath/$addonDir)" ]; then
        chmod 0755 $abSolutionPath/$addonDir/*
    fi
fi
# to this script
if [ -f $abSolutionDevice/$appScript ];then
    chmod 0755 $abSolutionDevice/$appScript
    dos_to_unix $abSolutionDevice/$appScript
fi
# to entware init.d
if [ -d $initDir ];then
    chmod 0755 $initDir/*
fi

is the device itself set read only? ... can you type mount at the command line and see what the output says?


Thx for the reply Tomsk.
Underneath the response from the "mount" command.
Code:
ASUSWRT-Merlin RT-N66U_3.0.0.4 Wed Nov  2 22:07:14 UTC 2016
admin@RT-N66U-3D08:/tmp/home/root# mount
rootfs on / type rootfs (rw)
/dev/root on / type squashfs (ro)
proc on /proc type proc (rw)
tmpfs on /tmp type tmpfs (rw)
devfs on /dev type tmpfs (rw,noatime)
sysfs on /sys type sysfs (rw)
devpts on /dev/pts type devpts (rw)
/dev/mtdblock4 on /jffs type jffs2 (rw,noatime)
usbfs on /proc/bus/usb type usbfs (rw)
/dev/sda1 on /tmp/mnt/Adblock type ext3 (ro,nodev,noatime,data=ordered)
admin@RT-N66U-3D08:/tmp/home/root#
 
/dev/sda1 on /tmp/mnt/Adblock type ext3 (ro,nodev,noatime,data=ordered)
your USB stick has been set as read only (ro) it needs to be set read write (rw)
 
your USB stick has been set as read only (ro) it needs to be set read write (rw)

Any idea on how to do that?
I put the stick in my laptop and used EASUS partition manager to make it EXT3.
When putting it back in the N66 it went to RW, i rebooted the router and again it showed RW but the same error stay.

I tried chmod 0777 /dev/sda1

Code:
admin@RT-N66U-3D08:/tmp/home/root# mount
rootfs on / type rootfs (rw)
/dev/root on / type squashfs (ro)
proc on /proc type proc (rw)
tmpfs on /tmp type tmpfs (rw)
devfs on /dev type tmpfs (rw,noatime)
sysfs on /sys type sysfs (rw)
devpts on /dev/pts type devpts (rw)
/dev/mtdblock4 on /jffs type jffs2 (rw,noatime)
usbfs on /proc/bus/usb type usbfs (rw)
/dev/sda1 on /tmp/mnt/Adblock type ext3 (rw,nodev,noatime,data=ordered)
admin@RT-N66U-3D08:/tmp/home/root# ./ab-solution.sh
    _   ___     ___      _      _   _
   /_\ | _ )___/ __| ___| |_  _| |_(_)___ _ _
  / _ \| _ \___\__ \/ _ \ | || |  _| / _ \ ' \
 /_/ \_\___/   |___/\___/_|\_,_|\__|_\___/_||_|

 Welcome
 This is AB-Solution 3

 looking for an installation
 found AB-Solution on /tmp/mnt/Adblock
 checking installation state

 hosts file needs an update, running [u] now
 in silent mode

-                                                           100%[==========================================================================================================================================>] 488.60K   104KB/s   in 4.7s
rm: remove '/tmp/mnt/Adblock/adblocking/backup/hosts_file1'?
cp: can't create '/tmp/mnt/Adblock/adblocking/backup/hosts_file1': File exists
/tmp/mnt/Adblock/adblocking/addon/update-hosts.add: line 104: can't create /tmp/mnt/Adblock/adblocking/temp_hosts: Read-only file system
/tmp/mnt/Adblock/adblocking/addon/update-hosts.add: line 104: can't create /tmp/mnt/Adblock/adblocking/backup/hosts_file2: Read-only file system
-                                                               [  <=>                                                                                                                                      ]  36.21K  68.4KB/s   in 0.5s
rm: remove '/tmp/mnt/Adblock/adblocking/backup/hosts_file2'?
 
Not sure what to see in the Systemlog of the GUI of the router itself.
Here is a big part of it.
Code:
Dec 20 16:10:52 custom script: Running /jffs/scripts/dnsmasq.postconf (args: /etc/dnsmasq.conf)
Dec 20 16:10:52 admin: AB-Solution added entries via ab_dnsmasq_postconf.sh
Dec 20 16:10:52 admin: AB-Solution linked dnsmasq.postconf to ab_dnsmasq_postconf.sh
Dec 20 16:10:53 dropbear[513]: Password auth succeeded for 'admin' from 192.168.1.66:56991
Dec 20 16:10:53 rc_service: ntp 422:notify_rc restart_diskmon
Dec 20 16:10:53 rc_service: waiting "restart_upnp" via ntp ...
Dec 20 16:10:53 miniupnpd[512]: shutting down MiniUPnPd
Dec 20 16:10:53 miniupnpd[605]: HTTP listening on port 43652
Dec 20 16:10:53 miniupnpd[605]: Listening for NAT-PMP/PCP traffic on port 5351
Dec 20 16:10:54 ntp: NTP update successful after 1 attempt(s)
Dec 20 16:10:54 disk monitor: be idle
Dec 20 16:11:03 kernel: JBD: sh wants too many credits (76 > 67)
Dec 20 16:11:03 kernel: EXT3-fs error (device sda1) in start_transaction: error 28
Dec 20 16:11:03 dnsmasq[597]: log failed: Read-only file system
Dec 20 16:11:03 kernel: Aborting journal on device sda1.
Dec 20 16:11:03 kernel: Remounting filesystem read-only
Dec 20 16:11:10 nmbd[461]: [2016/12/20 16:11:10, 0] nmbd/nmbd_become_lmb.c:become_local_master_stage2(392)
Dec 20 16:11:10 nmbd[461]:   Samba name server RT-N66U-3D08 is now a local master browser for workgroup WORKGROUP on subnet 192.168.1.1
Dec 20 16:11:10 nmbd[461]: [2016/12/20 16:11:10, 0] nmbd/nmbd_browsesync.c:find_domain_master_name_query_fail(351)
Dec 20 16:11:10 nmbd[461]:   find_domain_master_name_query_fail:
Dec 20 16:11:10 nmbd[461]:   Unable to find the Domain Master Browser name WORKGROUP<1b> for the workgroup WORKGROUP.
Dec 20 16:11:10 nmbd[461]:   Unable to sync browse lists in this workgroup.
Dec 20 16:11:15 crond[425]: time disparity of 3140170 minutes detected
Dec 20 16:11:18 admin: AB-Solution: download hosts file 1 failed, using backup file
Dec 20 16:15:29 admin: AB-Solution: download hosts file 1 failed, using backup file
Dec 20 16:15:30 admin: AB-Solution: download hosts file 2 failed, using backup file
Dec 20 16:15:38 admin: AB-Solution updated hosts file, 0 Domains are now blocked
Dec 20 16:15:38 rc_service: service 1118:notify_rc restart_dnsmasq
Dec 20 16:15:38 custom script: Running /jffs/scripts/dnsmasq.postconf (args: /etc/dnsmasq.conf)
Dec 20 16:15:38 rc_service: service 1137:notify_rc restart_dnsmasq
Dec 20 16:15:38 rc_service: waiting "restart_dnsmasq" via  ...
Dec 20 16:15:38 admin: AB-Solution added entries via ab_dnsmasq_postconf.sh
Dec 20 16:15:38 admin: AB-Solution linked dnsmasq.postconf to ab_dnsmasq_postconf.sh
Dec 20 16:15:38 dnsmasq[1157]: cannot open log /tmp/mnt/Adblock/adblocking/logs/dnsmasq.log: Read-only file system
Dec 20 16:15:38 dnsmasq[1157]: FAILED to start up
Dec 20 16:15:44 ntp: waiting for dnsmasq...
Dec 20 16:15:45 custom script: Running /jffs/scripts/dnsmasq.postconf (args: /etc/dnsmasq.conf)
Dec 20 16:15:45 ntp: waiting for dnsmasq...
Dec 20 16:15:45 admin: AB-Solution added entries via ab_dnsmasq_postconf.sh
Dec 20 16:15:45 admin: AB-Solution linked dnsmasq.postconf to ab_dnsmasq_postconf.sh
Dec 20 16:15:45 dnsmasq[1215]: cannot open log /tmp/mnt/Adblock/adblocking/logs/dnsmasq.log: Read-only file system
Dec 20 16:15:45 dnsmasq[1215]: FAILED to start up
Dec 20 16:15:49 ntp: waiting for dnsmasq...
Dec 20 16:15:52 ntp: start NTP update
Dec 20 16:15:52 ntp: NTP update successful after 1 attempt(s)
Dec 20 16:21:11 HTTP login: login 'admin' successful from 192.168.1.66:80
 
can you format EXT2?... it doesn't seem to like the journalling
 
can you format EXT2?... it doesn't seem to like the journalling

Yes, i will try that now.

That did the trick, now its working.

On to the next one, how to get rid of those annoying certificate erros on opening https pages:p
 
Last edited:
Some partition/format tools actually do ext4 even if you specify ext3.
Ah thats interesting information and possibly whats happened here... i believe the N66U supports EXT3 but not EXT4 ..... smack on the bottom for EASUS perhaps
 
That was interesting to read, and EASUS likely deserves more than that smack if it's true.
Any way to recognize that fake ext3?

@miniterror: You need to import the certificate into your device.
Follow kvic's tutorial here, importing the certificate.
The certificate is located at /opt/var/cache/pixelserv/ca.crt
 
That was interesting to read, and EASUS likely deserves more than that smack if it's true.
Any way to recognize that fake ext3?

@miniterror: You need to import the certificate into your device.
Follow kvic's tutorial here, importing the certificate.
The certificate is located at /opt/var/cache/pixelserv/ca.crt

Thx guys,

If you need any test on the "fake" ext3 USB i can test things for you.
Maybe you could try writing a small file from out the script to see if that is able to write to the USB stick.
If it fails abort the rest of the script?


A different note, i now have two routers where i have the pixelservthing running.
Can i have 2 certificates on my local devices as one is at work and the other one at home.
 
I forget where I ran across it. Now, I just keep a copy of GParted on a bootable USB for when I need to format or play with the partitions.. Has never failed me.
This EaseUS tool looks like a textbook 'how not to do it' example to me.
Installs crapware (WinZIP driver updater), does several splash up screens and does indeed format ext3 in a way that is unrecognizable to a full blown Linux system.
My CentOS reports at trying to mount:
Error mounting: mount: wrong fs type, bad option, bad superblock on /dev/sdc,
missing codepage or helper program, or other error
What a tool!
 
Thx guys,

If you need any test on the "fake" ext3 USB i can test things for you.
Maybe you could try writing a small file from out the script to see if that is able to write to the USB stick.
If it fails abort the rest of the script?


A different note, i now have two routers where i have the pixelservthing running.
Can i have 2 certificates on my local devices as one is at work and the other one at home.
No thanks, I just tested EaseUS, see my post.
No need to do any more from my side.

And sure, you can import as many certs as you want.
 
Maybe you could try writing a small file from out the script to see if that is able to write to the USB stick.
This is already in my local version.
Thanks.
 
I don't know what I am doing wrong here, so if someone could help me out that would be great:

1) www.di.se - it uses some ad's, of course, and they are javascript triggered from when you enter the site
2) When I use my ANDROID mobile (Samsung Note 4) from my HOME WIFI, AdBlock works just great - and everything is blocked even if javascript is turned on
3) When I use my ANDROID mobile from say work, AND I am connected over Open VPN to my home router, I do get ad's when javascript is turned on

Now #3 above should not happened as far as I am aware - or am I doing something wrong here? I am trying to use OpenVPN connection to (among other things) remove ad's - but I still have them when I am not on my Home WiFi network.

Is there something that separates OpenVPN connections from WiFi (or cable direct attached to my router) within AdBlock solution/OpenVPN?

I also believe I have asked this before, so if I have, please forgive me - I'm obviously getting older...
 
Status
Not open for further replies.

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