Closed gkeishin closed 7 years ago
I think the networking will be unavailable after configuring the interface with a different MAC address. It's a known issue in NCSI stack. The new MAC address isn't configured to the filter in time, meaning the BRT won't forward incoming frames whose destination MAC is the newly configured one to BMC accordingly. As we have different (NCSI) code in 4.4/5/6 and 4.7, could you please claim which release the issue was reported from?
@gwshan The driver info
root@barreleye:~# cat /etc/version 20160913033422 root@barreleye:~# cat /etc/os-release ID="openbmc-phosphor" NAME="Phosphor OpenBMC (Phosphor OpenBMC Project Reference Distro)" VERSION="v1.99.0-60" VERSION_ID="v1.99.0-60-g2b717d8-dirty" PRETTY_NAME="Phosphor OpenBMC (Phosphor OpenBMC Project Reference Distro) v1.99.0-60" BUILD_ID="v1.99.0"
@gwshan From today build as well same error
Set valid Mac address :: _GOOD PATH_ URI:https://9.3.29.119/org/openbmc/NetworkManager/Interface//action/SetHwAddress, method:Post, args:{u'data': {u'data': [u'eth0', u'00:21:cc:73:91:dd']}, u'headers': {u'Content-Type': u'application/json'}} Response code:401, Content:{ "data": { "description": "Login required" }, "message": "401 Unauthorized", "status": "error" } F FFDC Collection Started : 20160913230959974789 FFDC Collection Completed : 20160913231034179346 Set valid Mac address :: _GOOD PATH_ | FAIL |
Revert old Mac address :: _GOOD PATH_ URI:https://9.3.29.119/org/openbmc/NetworkManager/Interface//action/SetHwAddress, method:Post, args:{u'data': {u'data': [u'eth0', u'00:01:6c:80:02:78']}, u'headers': {u'Content-Type': u'application/json'}} Response code:401, Content:{ "data": { "description": "Login required" }, "message": "401 Unauthorized", "status": "error" } F FFDC Collection Started : 20160913231047281718 FFDC Collection Completed : 20160913231122420709 Revert old Mac address :: _GOOD PATH_ | FAIL |
root@barreleye:~# cat /etc/version 20160913205350 root@barreleye:~# cat /etc/os-release ID="openbmc-phosphor" NAME="Phosphor OpenBMC (Phosphor OpenBMC Project Reference Distro)" VERSION="v1.99.0-75" VERSION_ID="v1.99.0-75-gc36e20e-dirty" PRETTY_NAME="Phosphor OpenBMC (Phosphor OpenBMC Project Reference Distro) v1.99.0-75" BUILD_ID="v1.99.0" root@barreleye:~#
Changes Git (git https://github.com/openbmc/openbmc.git) network: add missing systemd dep (commit: c36e20e) (detail) Started by GitHub push by williamspatrick Revision: c36e20e583d937052a0564794fa7f8e6be3264a7
@gwshan Anything we need to know more on this... ? or is this some special mode we have to be in to access this method to set the MAC HW address..
The error 401 Unauthorized
says the REST server rejected the attempt.
I doubt it is a mapping back from the kernel. I doubt this has anything to do with timings in the NCSI stack. I expect the code to change the MAC is never executed.
ah okie.. From Journald i see message log like this
Sep 08 21:50:36 barreleye phosphor-gevent[974]:xx.xx.xx.xx - - [2016-09-08 21:50:36] "POST /org/openbmc/NetworkManager/Interface//action/SetAddress4 HTTP/1.1" 401 230 0.187601
Please check the automation, the most likely cause is an error with the login
request or failing to pass the authorization cookie.
@mdmillerii Just reran the test, the login request went fine.. but the next operation to set failed as reported
method:Post, args:{u'data': {u'data': [u'eth0', u'00:21:cc:73:91:dd']}, u'headers': {u'Content-Type': u'application/json'}} Response code:401, Content:{ "data": { "description": "Login required" }, "message": "401 Unauthorized", "status": "error" }
Send a POST request on the session object found using the
Start / End / Elapsed: 20160919 07:22:34.279 / 20160919 07:22:36.402 / 00:00:02.123
07:22:36.401 INFO Post Request using : alias=openbmc, uri=/login, data={"data": ["root", "0penBmc"]}, headers={u'Content-Type': u'application/json'}, files=None, allow_redirects=True
07:22:36.402 INFO ${resp} = Response [200]
Send a POST request on the session object found using the
Start / End / Elapsed: 20160919 07:22:36.405 / 20160919 07:22:47.303 / 00:00:10.898
07:22:47.303 INFO Post Request using : alias=openbmc, uri=/org/openbmc/NetworkManager/Interface//action/SetHwAddress, data={"data": ["eth0", "00:21:cc:73:91:dd"]}, headers={u'Content-Type': u'application/json'}, files=None, allow_redirects=True
07:22:47.303 INFO ${ret} = Response [401]
I already had the patch allowing to run below commands. I will post them together with other NCSI patches at appropriate time:
bmc# ifconfig eth0 down
bmc# Ifconfig eth0 hw ether A0:42:3F:2D:08:7E
bmc# ifconfig eth0 up
bmc# # ifconfig
eth0 Link encap:Ethernet HWaddr A0:42:3F:2D:08:7E
inet addr:10.61.161.105 Bcast:10.61.255.255 Mask:255.255.0.0
inet6 addr: fe80::a242:3fff:fe2d:87e/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:955 errors:0 dropped:0 overruns:0 frame:0
TX packets:367 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:51235 (50.0 KiB) TX bytes:23430 (22.8 KiB)
gwshan@gwshan:~$ sudo arp | grep "a0:42:3f:2d:08:7e" gwshan@gwshan:~$ sudo ping -c 1 10.61.161.105 PING 10.61.161.105 (10.61.161.105) 56(84) bytes of data. 64 bytes from 10.61.161.105: icmp_seq=1 ttl=64 time=1.62 ms |
---|---|
gwshan@gwshan:~$ sudo arp | grep "a0:42:3f:2d:08:7e" |
palm8-bmc.ozlabs.ibm.co ether a0:42:3f:2d:08:7e C eth0
@gwshan That's cool.. is changes this one going in soon :)
@gkeishin Dear George, Are we still seeing this issue?
@sivassrr This is now in extended use case.. and we haven't tested it yet. On top of that the networking test case for MAC are needed to be updated as discussed earlier..
@prkatti1 Can you take a look into this Network test
@prkatti1 As discussed, Please test using official release driver of all our network TCs and update it accordingly.
Closing this as the new network refactor code is coming in.
Looks like this REST method is restricted or not allowed via REST for setting MAC value
The interface /org/openbmc/NetworkManager/Interface//action/SetHwAddress request results in HTTPS 401 response which means HTTP_UNAUTHORIZED
So this needs to confirm with the development if this method is valid or not. If so why this 401
GOOD PATH This test case add the ip address on the interface and validates that ip address has been added or not. Expectation is the ip address should get added.
Documentation:
Send a POST request on the session object found using the Start / End / Elapsed: 20160913 10:50:42.478 / 20160913 10:50:51.358 / 00:00:08.880 10:50:51.358 INFO Post Request using : alias=openbmc, uri=/org/openbmc/NetworkManager/Interface//action/SetHwAddress, data={"data": ["eth0", "00:01:6c:80:02:78"]}, headers={u'Content-Type': u'application/json'}, files=None, allow_redirects=True
10:50:51.358 INFO ${ret} = Response [401]
Two network test cases are failing Set and revert mac value