Page 1 of 3

QoS configuration disappears after power loss and breaks WAN

Posted: Fri Apr 20, 2012 7:02 pm
by danielkza
After a power outage today, my PPPOE WAN connection unexpectedly stopped working after my WR-1043ND and my ADSL modem rebooted. I confirmed the ADSL connection itself was fine by connecting directly to the modem, and searching a little through the configuration on Gargoyle (version 1.5.4) I found all the QoS rules and classes for download had disappeared. That is pretty bad by itself since I'll have to reinput them all, but it also broke the connection completely as a side effect. There are no error messages in either the kernel or the system logs besides the ones from other services caused by the lack of connectivity.

Is this a known issue? Can I provide any other information to help solve this problem, or are there at least any measures I can take to make it less likely to happen?

Thank you,
Daniel

Re: QoS configuration disappears after power loss and breaks

Posted: Fri Apr 20, 2012 11:52 pm
by danielkza
My QoS rules just got reset again for no apparent reason: I did a simple edit (adding one rule) and after saving everything is gone. Checking uci shows that the configuration entries are actually gone. Luckily the upload rules were intact and I could adapt them since they're very similar to my download entries.

Re: QoS configuration disappears after power loss and breaks

Posted: Sun Apr 22, 2012 2:02 am
by tals
I din't think it's a gargoyle issue, sounds more like a 1043 issue, did some googling but didn't seem to find anything conclusive. Though there was mention of settings not taking I don't think the is the issue you are experiencing. When you lose the settings are you reinputting them or reloading. If reloading might be worth clearing the settings for the whole system and reinputting it all just in case a corruption is causing the issue.

Re: QoS configuration disappears after power loss and breaks

Posted: Sun Apr 22, 2012 3:39 pm
by danielkza
tals wrote:I din't think it's a gargoyle issue, sounds more like a 1043 issue, did some googling but didn't seem to find anything conclusive. Though there was mention of settings not taking I don't think the is the issue you are experiencing. When you lose the settings are you reinputting them or reloading. If reloading might be worth clearing the settings for the whole system and reinputting it all just in case a corruption is causing the issue.
The symptons do not seem to indicate a hardware-specific problem since the /etc/config/qos_gargoyle file was not corrupted at all, it was simply missing all the download rules and classes. There are no other configurations missing either. At least to me it seems like a bug in some component that writes the qos config, but I don't know enough about Gargoyle to be more specific.

What I also find strange is that for the qos config. file to be lost on power loss it stands to reason it was being written to, which is unexpected considering I did not have the web interface open. The second loss was also unexpected since I had just remade all the rules manually (by editing the config file and deriving the download rules from the upload rules), reloaded the web interface, and all of them had shown up properly. There was no exceptional condition that would have made the web interface lose the settings. Which also points to a bug somewhere.

Finally, missing qos rules in one direction should not cause complete connectivity loss: qos should simply be disabled or some default configuration should be used instead!

Re: QoS configuration disappears after power loss and breaks

Posted: Sun Aug 12, 2012 12:03 pm
by Mikhail.Fiadosenka
danielkza wrote:My QoS rules just got reset again for no apparent reason: I did a simple edit (adding one rule) and after saving everything is gone. Checking uci shows that the configuration entries are actually gone. Luckily the upload rules were intact and I could adapt them since they're very similar to my download entries.
I've met the same issue while configuring my QoS rules. If the number of rules is not high, saving works fine. When the rules count reached 31 it was impossible to add one more rule, because after pressing 'Save' all of them are gone. More over, after rules disappeared, JavaScript on QoS page is broken and the only way to restore QoS settings - is to load backup configuration.

Today I've looked through the sources and made an attempt to intercept the POST request to "utility/run_commands.sh", that is made just after user presses 'Save' button. So, I learned that browser sends some bash script ('commands' parameter) and hash (auth cookie, i suppose).
"run_commands.sh" script simply writes the value of "commands" parameter to "/tmp/tmp.sh" and executes it.
I compared the contents of "commands" parameter, when the page had little QoS rules and when there were many of them. And in both cases the structure was similar and looked correctly.
I tried to save "tmp.sh" with "commands" to "/usr/tmp.sh" with WinSCP and execute it. WinSCP warned me that there is no response from router, I waited for half a minute and reloaded 'QoS Download' page. And all new rules were there! I've added 3 more rules and got 34 rules in total.

If Gargoyle successfully executes bash script with lots of QoS rules, generated in browser via JavaScript, then maybe the problem is somewhere between QoS management code and browser?
Is there any limitations of request size in httpd module? In my case, request was of 15.6Kb.

Re: QoS configuration disappears after power loss and breaks

Posted: Fri Aug 17, 2012 10:43 am
by yeti_z
Hi,

I have very similar issue with disappearing qos entries especially in download section. I'm running WNDR3700v1, so I'd conclude it's not hardware specific issue. Besides I had the same issue on both IE 8 and FF so I thought it's not really browser type related. I am running Gargoyle 1.5.6, but I updated because I had this issue in 1.5.4

I am wondering what could I test/check to contribute to fixing it?

Regards,
yeti_z

Re: QoS configuration disappears after power loss and breaks

Posted: Sat Nov 03, 2012 7:58 pm
by raz
Yep, same issue here (1.5.8 and prior)

Having a backup file at hand seems to be the only way to avoid the arbitrary clearing of QoS classification rules upon the slightest modification.


I have noticed that if you click on 'Save changes' and the 'Please wait while settings are applied' window disappears in under 5 seconds, then you are assured of the system 'losing' some entries, even though the qos_gargoyle file remains unchanged.

Re: QoS configuration disappears after power loss and breaks

Posted: Sun Nov 11, 2012 3:21 am
by Dev_BR
Same problem here
I was editing some qos rule.
I hav a QoS sesion opened in computer A.
I Open other sesion in other coputer and edit some qos rules and press save.

QoS become incomplete.

I thisk while I edit rules in computer B, computer A refreshed page and cause loose of data.

Re: QoS configuration disappears after power loss and breaks

Posted: Mon Nov 12, 2012 12:46 am
by ericwong
Same problem here...

I noticed it is not just QoS page, it can happen with the quota page too but less frequently..

I have reported this in the forum a few times but didn't know the real cause... although I know how to make the problem appear more frequently.

I am still hoping for a fix for this because it is very annoying...

My quick workaround is to copy the QoS configuration file from the good backup back to the router via SCP... so it saves me manually redoing the QoS every time it go haywire..

Re: QoS configuration disappears after power loss and breaks

Posted: Sun Dec 16, 2012 11:57 am
by pbix
Today I tried to reproduce this issue without success.

I added 40 rules to the download page and 35 to the upload page. Both saved without issue.

I attach an example of my download page.

It seems something other than the number of QoS rules is responsible for this situation. Running out of RAM on your router seems to me to be a likely cause. User experiencing this problem should state their router model in their posts.

Until a reliable way to reproduce this problem is reported it will not be possible to address is.