Who uses O.T.R.W on a K24 router?

Post new topic   Reply to topic    DD-WRT Forum Index -> Broadcom SoC based Hardware
Goto page Previous  1, 2, 3  Next
Author Message
basmaf
DD-WRT Guru


Joined: 24 Feb 2011
Posts: 1074

PostPosted: Thu Jun 14, 2012 18:59    Post subject: Reply with quote
For testing.

Please test the scripts you would normally use.
And if the installation scripts works error free.

When using an older build an unmodified version of asiablock will be used.

If you can test stophammer it would be nice.
I modded the script to use asia.ham for whitelisting.

Scripts I use:
xinetd
relocate_syslog
pixelserv
pound
vlighttpd
fixtables
stophammer
asiablock
stophack
backupessential
mypage Wink

basmaf

Edit:
One more thing.
Please test 'optware_backup' script is in /opt/usr/sbin/
it will copy most user defined settings.
Cat the file for a detailed description.
Sponsor
Bird333
DD-WRT Guru


Joined: 07 Jun 2006
Posts: 809

PostPosted: Fri Jun 15, 2012 11:27    Post subject: Reply with quote
basmaf wrote:
Just run the scripts. only a reboot after installation is needed to start all correctly.

mounting to /tmp/www will be done for you.
mypage will take care of creating nvram values.
no setup needs to be done all is enabled by default.

bwmon scripts will be started with default values.
bwmon will generate a userlist for you when host names are available in the arp table otherwise auto-added will be used.
userlist is shown on the bwmon page. also it's location.

basmaf


If we got mypage and bwmon already setup do we need to uninstall those before we run this setup script?
basmaf
DD-WRT Guru


Joined: 24 Feb 2011
Posts: 1074

PostPosted: Fri Jun 15, 2012 11:37    Post subject: Reply with quote
Bird333 wrote:
If we got mypage and bwmon already setup do we need to uninstall those before we run this setup script?


No, when /opt/www folder exists, mypage will not be installed.
But i would still suggest you backup
barryware
DD-WRT Guru


Joined: 26 Jan 2008
Posts: 13049
Location: Behind The Reset Button

PostPosted: Fri Jun 15, 2012 14:03    Post subject: Reply with quote
I used my TM, formatted a fresh SD card, and installed from scratch.

The only problem, mypage didn't work until this was added to the startup script:

if [ -d /tmp/www ]; then rm -rf /tmp/www; fi
ln -s /mmc/opt/www /tmp/www

Some other issues which are no diff than using the original..

I need to turn off automount or the sd card gets mounted twice. I turned off fixtables as it is reported to not be needed with k24 builds.

Other than that, everything is fine. I have xinetd & pixelserv running as well as the blocks that are on by default. I will turn these off after it runs for a bit.

@basmaf... I like the smaller fonts on the mypage pages.

If I wanted to, how do I turn off bwmon? just make the sh file non-executable?

Nice job basmaf.. I spent hours back in the day getting mypage & bwmon running. This was easy.

Now for a little face palm on my part:

Using gparted to format my sd card, instead of deleting the existing partition on the sd card, I deleted the partition on my boot drive on my pc Embarassed

So that took a couple of hours getting my rig all restored. Thank goodness for drive images & daily data backups.

_________________
[Moderator Deleted] Shocked
basmaf
DD-WRT Guru


Joined: 24 Feb 2011
Posts: 1074

PostPosted: Fri Jun 15, 2012 15:09    Post subject: Reply with quote
barryware wrote:
The only problem, mypage didn't work until this was added to the startup script:

if [ -d /tmp/www ]; then rm -rf /tmp/www; fi
ln -s /mmc/opt/www /tmp/www

Could you post the output of `mount` i did not think about the mmc mounts.

barryware wrote:
I like the smaller fonts on the mypage pages.

From which version of mypage, I really suck @webpages so if you have some pointers.
It can be fixed it was on my list.

barryware wrote:

If I wanted to, how do I turn off bwmon? just make the sh file non-executable?

Will add an option to disable it.

For now comment start_bwmon in /opt/etc/init.d/S99mypage
removing executable flag will give you a lot of errors.
Code:
case "$rc" in
           start)
   
                   init
                   Files_Folders
#                   start_bwmon


Glad you like it so far.

About the clean format Wink
Did that once while reinstalling optware.
rm -rf * but then on root....

basmaf.
barryware
DD-WRT Guru


Joined: 26 Jan 2008
Posts: 13049
Location: Behind The Reset Button

PostPosted: Fri Jun 15, 2012 15:16    Post subject: Reply with quote
I meant I like the smaller fonts you use vs the original fonts.

root@DD-WRT_1:~# mount
rootfs on / type rootfs (rw)
/dev/root on / type squashfs (ro)
none on /dev type devfs (rw)
proc on /proc type proc (rw)
ramfs on /tmp type ramfs (rw)
/dev/mmc/disc0/part1 on /mmc type ext2 (rw,noatime)
/dev/mmc/disc0/part1 on /opt type ext2 (rw,noatime)
root@DD-WRT_1:~#

_________________
[Moderator Deleted] Shocked
basmaf
DD-WRT Guru


Joined: 24 Feb 2011
Posts: 1074

PostPosted: Fri Jun 15, 2012 17:19    Post subject: Reply with quote
Sorry misunderstood you.

How is your opt mounted since part1 is mounted to /mmc & /opt
Trying to understand why you need to symlink /mmc/opt
barryware
DD-WRT Guru


Joined: 26 Jan 2008
Posts: 13049
Location: Behind The Reset Button

PostPosted: Fri Jun 15, 2012 17:51    Post subject: Reply with quote
this is my startup script mount:

mount /mmc/opt /opt

that's it.. It has always mounted to /mmc and to /mmc/opt

I think that is just the way it is with an sd card. At least it has always been that way. I believe the sd card itself (the device) mounts to /mmc when you enable sd (mmc) support.

so my sd card has one folder in the 1st ext2 partition called "opt". mmc is the device (I think) so I have to mount opt to /mmc/opt.

There is also a folder called lost&found that gparted makes when it formats the partition.

_________________
[Moderator Deleted] Shocked
basmaf
DD-WRT Guru


Joined: 24 Feb 2011
Posts: 1074

PostPosted: Fri Jun 15, 2012 18:38    Post subject: Reply with quote
Then i don't understand why the script doesn't create the symlink.

This is included in S99mypage
It's the same as you are using without /mmc
Could you try to enter commands manually to see it gives an error.
since /mmc/opt is mounted to /opt it should work.
Code:
WWW_DIR=/opt/www
if [ -d /tmp/www ]; then
   rm -rf /tmp/www
fi
ln -s ${WWW_DIR} /tmp/www


Option to disable now included in the source.
Code:
vi /opt/etc/init.d/S99mypage

# To disable BWMON set to 1
DISABLE_BWMON=0

Will be available in half and hour when svn checks out
barryware
DD-WRT Guru


Joined: 26 Jan 2008
Posts: 13049
Location: Behind The Reset Button

PostPosted: Fri Jun 15, 2012 20:09    Post subject: Reply with quote
I rem'd out the statements in startup in regard to mypage..

after a reboot, mypage just offered up a blank page.

I added a sleep 3 after the mount.. All is good..

I'm gonna leave bwmon running for now.. A tm has a 200mhz processor. I have it overclocked a bit. bwmon puts a substantial load on the router with a slow processor. It is not however, affecting my down/upload speeds.

Nice Job.. My spare is now my main.. My main is now my spare.

As soon as my RT is back as my main router, I'll do a clean install running a k26 build using a usb stick (however, you have indicated that k26 is tested)

_________________
[Moderator Deleted] Shocked
barryware
DD-WRT Guru


Joined: 26 Jan 2008
Posts: 13049
Location: Behind The Reset Button

PostPosted: Sat Jun 16, 2012 14:22    Post subject: Reply with quote
I have the new S99mypage file in place and active.

Quick Q... the cron job that resets bwmon data at the 1st of the month.. Should that show up in the gui as a cron job?

I ask because it is not showing in the gui.

_________________
[Moderator Deleted] Shocked
basmaf
DD-WRT Guru


Joined: 24 Feb 2011
Posts: 1074

PostPosted: Sat Jun 16, 2012 19:51    Post subject: Reply with quote
No it should not
A file is created in the cron dir for the script.
Makes it easier to add/remove cron jobs.
Code:
root@E4200:~# cat /tmp/cron.d/S99mypage
0 0 1 * * root /opt/etc/init.d/S99mypage reset_month
barryware
DD-WRT Guru


Joined: 26 Jan 2008
Posts: 13049
Location: Behind The Reset Button

PostPosted: Sat Jun 16, 2012 22:03    Post subject: Reply with quote
basmaf wrote:
No it should not
A file is created in the cron dir for the script.
Makes it easier to add/remove cron jobs.
Code:
root@E4200:~# cat /tmp/cron.d/S99mypage
0 0 1 * * root /opt/etc/init.d/S99mypage reset_month

Tally "ho"...

I typically do not run bwmon on this router (200mhz oc'd a bit)

so.. it is the middle of the month, I'll leave it as is with bwmon running. (unless I see a need to run k26 on a diff router) I am very interested.

kudo's basmaf... Very nice.. You Beez Da Man!

_________________
[Moderator Deleted] Shocked
Bird333
DD-WRT Guru


Joined: 07 Jun 2006
Posts: 809

PostPosted: Sun Jun 17, 2012 0:20    Post subject: Reply with quote
I would like to try the mypage with the smaller fonts. Is it possible to add a "yes or no" option to installing mypage and bwmon if you already have them installed? Then a user can have their previous install overwritten.
barryware
DD-WRT Guru


Joined: 26 Jan 2008
Posts: 13049
Location: Behind The Reset Button

PostPosted: Sun Jun 17, 2012 0:26    Post subject: Reply with quote
Bird333 wrote:
I would like to try the mypage with the smaller fonts. Is it possible to add a "yes or no" option to installing mypage and bwmon if you already have them installed? Then a user can have their previous install overwritten.

I used a fresh sd card.. Mypage is a bit diff.. Old mypage was mypage1.sh.. new = mp1.sh. That means that your nvram set will be totally diff.

So.. they are not compatable..

Just install fresh. Trust me.. Everything went very smooth excluding the things I posted about but all were easy fixes.

_________________
[Moderator Deleted] Shocked
Goto page Previous  1, 2, 3  Next Display posts from previous:    Page 2 of 3
Post new topic   Reply to topic    DD-WRT Forum Index -> Broadcom SoC based Hardware All times are GMT

Navigation

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum