Modify configuration appears: Unexpected error

grafana-server -v

Version 8.4.3 (commit: b7d2911cac, branch: HEAD)

grafana-cli -v

Grafana CLI version 8.4.3

My Grafana config is

[server]
protocol = http
domain = zysy-warning
root_url = http://zysy-warning
serve_from_sub_path = true
router_logging = true

When my IP is: 172.16.10.131
Grafana IP is: 172.16.10.130
I modified the configuration through the web page and everything went well.

BUT:
When my IP is 10.5.4.10
Grafana IP is: 172.16.10.130

An error occurs when you modify the configuration: Unexpected error

Web console: TypeError: NetworkError when attempting to fetch resource.
Browser: Firefox 98.0.1

click: Save & test (The same error occurs when you change your password.)

I considered the possibility of a cross-domain error
When I tried to use nginx for reverse acting, there was still a mistake.
But mistakes were made.
This error is not seen in /var/log/grafane/grafana.log

How should I configure it?

try using this for root_url:
root_url = %(protocol)s://%(domain)s:%(http_port)s/grafana/