Skip to content

Conversation

@cubercsl
Copy link
Contributor

@cubercsl cubercsl commented Aug 5, 2024

I am trying to debug domjudge main branch with adminer, but some data is not displayed correctly and I got a 502 error in the nginx log.

image
image

... - - [05/Aug/2024:14:20:09 +0000] "GET /jury/adminer?username=&db=domjudge HTTP/2.0" 200 9835 "https://.../jury/adminer?username=&db=" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/127.0.0.0 Safari/537.36"
2024/08/05 14:20:10 [error] 998059#998059: *9783 FastCGI sent in stderr: "PHP message: PHP Warning:  Undefined variable $dg in /opt/domjudge/webapp/resources/adminer.php on line 868; PHP message: PHP Warning:  Undefined variable $dg in /opt/domjudge/webapp/resources/adminer.php on line 868; PHP message: PHP Warning:  Undefined variable $dg in /opt/domjudge/webapp/resources/adminer.php on line 868; PHP message: PHP Warning:  Undefined variable $dg in /opt/domjudge/webapp/resources/adminer.php on line 868; PHP message: PHP Warning:  Undefined variable $dg in /opt/domjudge/webapp/resources/adminer.php on line 868; PHP message: PHP Warning:  Undefined variable $dg in /opt/domjudge/webapp/resources/adminer.php on line 868; PHP message: PHP Warning:  Undefined variable $dg in /opt/domjudge/webapp/resources/adminer.php on line 868; PHP message: PHP Warning:  Undefined variable $dg in /opt/domjudge/webapp/resources/adminer.php on line 868; PHP message: PHP Warning:  Undefined variable $dg in /opt/domjudge/webapp/resources/adminer.php on line 868; PHP message: PHP Warning:  Undefined variable $dg in /opt/domjudge/webapp/resources/adminer.php on line 868; PHP message: PHP Warning:  Undefined variable $dg in /opt/domjudge/webapp/resources/adminer.php on line 868; PHP message: PHP Warning:  Undefined variable $dg in /opt/domjudge/webapp/resources/adminer.php on line 868; PHP message: PHP Warning:  Undefined variable $dg in /opt/domjudge/webapp/resources/adminer.php on line 868; PHP message: PHP Warning:  Undefined variable $dg in /opt/domjudge/webapp/resources/adminer.php on line 868; PHP message: PHP Warning:  Undefined variable $dg in /opt/domjudge/webapp/resources/adminer.php on line 868; PHP message: PHP Warning:  Undefined variable $dg in /opt/domjudge/webapp/resources/adminer.php on line 868; PHP message: PHP Warning:  Undefined variable $dg in /opt/domjudge/webapp/resources/adminer.php on line 868; PHP message: PHP Warning:  Undefined variable $dg in /opt/domjudge/webapp/resources/adminer.php on line 868; PHP message
2024/08/05 14:20:10 [error] 998059#998059: *9783 upstream sent too big header while reading response header from upstream, client: ..., server: ..., request: "GET /jury/adminer?username=&db=domjudge&script=db HTTP/2.0", upstream: "fastcgi://unix:/var/run/php-fpm-domjudge.sock:", host: "localhost", referrer: "https://.../jury/adminer?username=&db=domjudge"

Replacing this $dg with $y in webapp/resources/adminer.php can resolve this issue. (This is guessed by comparing the mapping relationship between the source and compressed code variable names.)

See also: vrana/adminer#450

See also: vrana/adminer#450

Signed-off-by: cubercsl <2014cais01@gmail.com>
@nickygerritsen
Copy link
Member

The other suggestion, adding $GLOBALS['sql'] =& $GLOBALS['jush']; to the place where we include adminer, doesn't work? I find that a bit more clean.

@vmcj
Copy link
Member

vmcj commented Aug 25, 2024

@cubercsl will you implement the other method or should we do this ourselves?

@vmcj
Copy link
Member

vmcj commented Nov 16, 2024

Hi @cubercsl,

I've merged #2798 which fixes this issue in another way.

@vmcj vmcj closed this Nov 16, 2024
@cubercsl cubercsl deleted the adminer-patch branch November 16, 2024 10:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants