Infinite redirect.
I need help debugging an infinite redirect.
Using tag 2.8.0
I built meta-phosphor with raspberrypi4. See https://github.com/Proclivis/conf-meta-rasberrypi-evb.git
I setup a host entry on my ubuntu laptop in /etc/hosts
10.0.1.72 bmc
Then with firefox use url
I get a redirect to
https://bmc:18080/#/login?next=%2F
Which also redirects again.
bmcweb is not sending a cookie on the first request.
On the target, token_authorization_middleware.hpp:187 is failing the cookie authorization, probably because Firefox is not sending back the cookie it never received.
There are two failed services not running:
obmc-phosphor-sysd.service
start-ipkvm-.service
I assume these would not interfere with something as basic as cookies.
Is there something I need to configure on the target?
Mike
Sent from my iPad
Quoted 2 lines · Mike Jones
I need help debugging an infinite redirect.
Without reading the rest of your email, there is a 95% chance that this means you didn't include phosphor-webui component in your build. It is a known "bug" that has bit several people, and I've been meaning to fix it so it at least gives you some better error and/or at least doesn't redirect, but architecturally it breaks some weird boundaries a little bit (the login routes have to be aware of which other routes have been registered, which imposes an unintended ordering on the route handler) , and I've just never had the chance.
Quoted 13 lines
Using tag 2.8.0
I built meta-phosphor with raspberrypi4. See https://github.com/Proclivis/conf-meta-rasberrypi-evb.git
I setup a host entry on my ubuntu laptop in
/etc/hosts10.0.1.72 bmc
Then with firefox use url
Quoted 7 lines
I get a redirect to
https://bmc:18080/#/login?next=%2F
Which also redirects again.
bmcweb is not sending a cookie on the first request.
Nor should it. You're not logged in yet, nor have you given valid login credentials. The redirect is trying to move you to the webui, which can then present a pretty login screen. Unfortunately the webui doesn't exist, so you hit another redirect.
Quoted 7 lines
On the target, token_authorization_middleware.hpp:187 is failing the cookie authorization, probably because Firefox is not sending back the cookie it never received.
There are two failed services not running:
obmc-phosphor-sysd.service
start-ipkvm-.service
Those should be irrelevant to this issue.
Quoted 4 lines
I assume these would not interfere with something as basic as cookies.
Is there something I need to configure on the target?
See above.
Ed,
That fixed it.
Committed to the repo below.
Still fails to start the service without /var/log/redfish
Adding -DBMCWEB_ENABLE_REDFISH_DBUS_LOG=ON will fix it. Otherwise someone might consider modifying event_service_manager.hpp to create the file when missing.
I still can’t l ssh to port 2200, but my goal is to add pmbus sensors and the webui will do for that.
Anyone that wants to get raspberrypi4 running can use the repo below and it’s Readme. It will get it compiled and the webui up. Mainly is just working config files and a readme with every command I used including making the image.
Sent from my iPhone
Quoted 57 lines · Ed Tanous
Quoted 2 lines · Mike Jones
I need help debugging an infinite redirect.
Without reading the rest of your email, there is a 95% chance that this means you didn't include phosphor-webui component in your build. It is a known "bug" that has bit several people, and I've been meaning to fix it so it at least gives you some better error and/or at least doesn't redirect, but architecturally it breaks some weird boundaries a little bit (the login routes have to be aware of which other routes have been registered, which imposes an unintended ordering on the route handler) , and I've just never had the chance.
Quoted 13 lines
Using tag 2.8.0
I built meta-phosphor with raspberrypi4. See https://github.com/Proclivis/conf-meta-rasberrypi-evb.git
I setup a host entry on my ubuntu laptop in
/etc/hosts10.0.1.72 bmc
Then with firefox use url
Quoted 7 lines
I get a redirect to
https://bmc:18080/#/login?next=%2F
Which also redirects again.
bmcweb is not sending a cookie on the first request.
Nor should it. You're not logged in yet, nor have you given valid login credentials. The redirect is trying to move you to the webui, which can then present a pretty login screen. Unfortunately the webui doesn't exist, so you hit another redirect.
Quoted 7 lines
On the target, token_authorization_middleware.hpp:187 is failing the cookie authorization, probably because Firefox is not sending back the cookie it never received.
There are two failed services not running:
obmc-phosphor-sysd.service
start-ipkvm-.serviceThose should be irrelevant to this issue.
Quoted 4 lines
I assume these would not interfere with something as basic as cookies.
Is there something I need to configure on the target?
See above.
I had a reply to your other email in my drafts that I forgot to send.
-Ed
Quoted 8 lines · Mike
Ed,
That fixed it.
Committed to the repo below.
Still fails to start the service without
/var/log/redfish
Make sure you have this revert in your tree:
https://github.com/openbmc/bmcweb/commit/7f4eb5887f9a52a2832ee9b6e06749575903128a
If it still doesn't work, there's something that's a bigger problem than I thought.
Quoted 4 lines
Adding -DBMCWEB_ENABLE_REDFISH_DBUS_LOG=ON will fix it. Otherwise someone might consider modifying event_service_manager.hpp to create the file when missing.
I still can’t l ssh to port 2200, but my goal is to add pmbus sensors and the webui will do for that.
I thought by default we were on normal port 22, not 2200. Maybe you have a slightly different config.
Quoted 3 lines
Anyone that wants to get raspberrypi4 running can use the repo below and it’s Readme. It will get it compiled and the webui up. Mainly is just working config files and a readme with every command I used including making the image.
If you are able, consider opening these as patches against meta-phosphor to get it building again on mainline. (note, I haven't actually looked at the repo yet, but I suspect there were some recipe edits?)
Ed,
The repo is only config, but some of it could be moved into existing layers. Being new here, I’ll let someone with experience review it and guide me.
I still have yocto vertigo! All the loose coupling is crazy as bad as Verilog UVM test benches.
I’m longing for a good Haskel project where I feel more grounded 😀
Port 22 is a general linux login. 2200 should be a management console. It may require adding a new user. Running the console from a normal shell fails to. So I believe it is all an authentication or user setup issue.
Mike
Sent from my iPhone
Quoted 38 lines · Ed Tanous
I had a reply to your other email in my drafts that I forgot to send.
-Ed
Quoted 9 lines · Mike
Ed,
That fixed it.
Committed to the repo below.
Still fails to start the service without
/var/log/redfishMake sure you have this revert in your tree:
https://github.com/openbmc/bmcweb/commit/7f4eb5887f9a52a2832ee9b6e06749575903128aIf it still doesn't work, there's something that's a bigger problem than I thought.
Quoted 4 lines
Adding -DBMCWEB_ENABLE_REDFISH_DBUS_LOG=ON will fix it. Otherwise someone might consider modifying event_service_manager.hpp to create the file when missing.
I still can’t l ssh to port 2200, but my goal is to add pmbus sensors and the webui will do for that.
I thought by default we were on normal port 22, not 2200. Maybe you have a slightly different config.
Quoted 3 lines
Anyone that wants to get raspberrypi4 running can use the repo below and it’s Readme. It will get it compiled and the webui up. Mainly is just working config files and a readme with every command I used including making the image.
If you are able, consider opening these as patches against meta-phosphor to get it building again on mainline. (note, I haven't actually looked at the repo yet, but I suspect there were some recipe edits?)