Common WebUI pages takes minutes to load.
-
First excuse me to link this post to you, but I think that is important, and for me VERY Important
I have an enviroment with 16500 computers, and 60 Storage Nodes growing, with location plugin. FOG 1.5.6
And I have this statistics:
hosts table: 16.500 records
hostMAC: 2800
Tabla snapins: 210
Tabla snapinAssoc: 45.403
Tabla snapinGroupAssoc: 15390This is verified on FOG Version 1.5.6 and FOG Version 1.5.7
The problem:
The following list of pages loads two slow, a few minutes:host management -> Host general host management -> Basic Task -> Deploy host management -> Basic Task -> Snapins Group management -> Snapins Group management -> Basic Task -> Deploy Group management -> Basic Task -> Snapins Snapin management -> List All Snapins ... at least
First i think that was a database stress workload problem.
Second Speaking with @Fernando-Gietz we think that was a filter problem.
But as I was unable to create a filter that works.
Then reading the code a bit more i found that the problem is on the line 1297 on fog/lib/router/route.class.php
" ‘storagegroupname’ => $class->getStorageGroup()->get(‘name’)"if you change the lines
$class->get(),
array(
‘storagegroupname’ => $class->getStorageGroup()->get(‘name’)
)
by
$class->get()The pages goes much more faster.
I have commented that line and seems that all works correctly with our operations. But maybe is better than someone that knows what are doing take a look about that and can find a “Correct Solution”.
Free to request more explanations.
-
Would you mind trying on working-1.6? (Preferabbly the same database but on a test instance?) to see if performance is improved at all?
-
yes i can try it, are there any database change? from 1.5.6? maybe i can do a realistic test with the same stressed database.
A bit of info more:
The problem is located on snapin.class.php function getPrimaryGroup($groupID)
Maybe i cant dive a bit more on the code.
-
@EduardoTSeoane With your very advanced setup I wouldn’t suggest you go to
working-1.6
yet. If you update the DB schema there is no way back other than manually reverting the DB changes!!! I’d think it’s better we try to find the bottleneck in 1.5.x and port the fix toworking-1.6
then as well.This is verified on FOG Version 1.5.6 and FOG Version 1.5.7
Which version do you currently run?
-
@Sebastian-Roth 1.5.6 officially, and on my development/testing machine 1.5.7
-
@EduardoTSeoane I will take a closer look at this on Friday evening (CET). Won’t find the time before that.
-
@EduardoTSeoane The get primary group error is likely from the typo for the snapin checking that has ‘prmary’ rather than ‘primary’
Can you look for the file that contains ‘prmary’ and add the I to it. This may or may not help, but at least the typo will be corrected either way.
-
@Tom-Elliott @Sebastian-Roth ok i try it tomorrow and tell you if it helps.
-
@Tom-Elliott @Sebastian-Roth
Typo corrected and don’t solve the problem, i dive a bit more on the code, and now i’m on
/var/www/html/fog/lib/fog/snapin.class.phpCommenting the code into the function getPrimaryGroup($groupID) // line 367
The WebUI has reasonable performance.
Then i think that the problem is that the nested loop in fastmerge function on line 2397 of fogbase.class.php, “is not so fast hehe”, maybe it helps.
A lot of thanks for your efforts in advance.
Maybe this night i can configure de working-1.6 personal test server with my production database.
-
Here is a possible alternative for the fastmerge function.
public static function fastmerge($array1) { $others = func_get_args(); array_shift($others); $array1 = array_merge($array1,...$others); return $array1; }
Though I expect performance difference to be minimal.
More likely that the problem lies in the sheer number of it.
Possibly 1.6 is a better environment for that.
-
@Sebastian-Roth @Tom-Elliott said in Common WebUI pages takes minutes to load.:
Would you mind trying on working-1.6? (Preferabbly the same database but on a test instance?) to see if performance is improved at all?
Ok, I’m ready to start the test, plz explain me how do you want the, bugs/problems report?
-
@EduardoTSeoane said in Common WebUI pages takes minutes to load.:
Ok, I’m ready to start the test, plz explain me how do you want the, bugs/problems report?
Just report here in the forums as you did before. Or if you are keen you could also post an issue on github. Whichever suites you best.