netopeer2 icon indicating copy to clipboard operation
netopeer2 copied to clipboard

callback rpc timed out error

Open sowmi18 opened this issue 3 years ago • 7 comments

Hi michalvasko,

Netopeer2 CLI 2.0.62 netopeer2-server 1.1.70 libsysrepo v1.4.122

########### netopeer cli LOGS

> user-rpc –rpc-timeout 10

ERROR
	type:     application
	tag:      operation-failed
	severity: error
	message:  Callback event "rpc" with ID 1 processing timed out.

########### SYSTEM LOGS

Oct 29 23:20:15 daemon.info netopeer2-server[1940]: Published event "operational" "/o-ran-ald-port:ald-ports-io" with ID 23.
Oct 29 23:20:15 user.notice ald_controller[2368]: Operational data request #23 recieved. xpath -> /o-ran-ald-port:ald-ports-io
Oct 29 23:20:45 user.notice wd_manager[2407]: Value is 1 for Xpath /stli_mcel-wdm:system-apps/ald_controller
Oct 29 23:20:51 daemon.info netopeer2-server[1940]: Published event "operational" "/o-ran-ald-port:ald-ports-io" with ID 24.
Oct 29 23:20:51 user.notice ald_controller[2368]: Operational data request #24 recieved. xpath -> /o-ran-ald-port:ald-ports-io
Oct 29 23:20:51 daemon.info netopeer2-server[1940]: Published event "rpc" "/o-ran-ald:ald-communication" with ID 1 priority 0 for 1 subscr.
Oct 29 23:20:51 user.notice ald_controller[2368]: RPC #1 recieved. xpath -> /o-ran-ald:ald-communication
Oct 29 23:21:28 user.notice wd_manager[2407]: Value is 1 for Xpath /stli_mcel-wdm:system-apps/ald_controller
fd = open(“/dev/ttySC0”, O_RDWR);                                       
        if (fd < 0) {                                                           
                printf(“\n failed to open /dev/ttySC0\n”);       
                return RX_FAILURE;                                              
        } else if (fdConfigure(&fd, UART_RD)) {                                 
     printf(“\n failed to configure /dev/ttySC0\n”);       
     return RX_FAILURE;                                              
        }                                                                       
                                                                                
        if (read(fd, data, len) == -1) {                                        
                printf(“\n read fail \n”);                
                return RX_FAILURE;                                              
        }                                                                       
                                                                                
        close(fd);  

I need to wait until data is received but netopeer2-cli is showing processing timed out error.I also tried by increasing the timeout value by user-rpc –rpc-timeout 10 command, still getting the same error. can you please help us on the same?

sowmi18 avatar Feb 01 '22 10:02 sowmi18

Try to increase netppeer2-server timeout by running it with -t 10, for example.

michalvasko avatar Feb 01 '22 15:02 michalvasko

Thanks!! It works Another doubt is there

user-rpc –rpc-timeout 10

ERROR type: application tag: operation-failed severity: error message: Callback event "rpc" with ID 1 processing timed out.

user-rpc –rpc-timeout 10

cli_send_recv: Timeout for receiving a reply expired.

What is the difference between these two errors?

sowmi18 avatar Feb 09 '22 09:02 sowmi18

The former means that the server timeout for a specific sysrepo RPC callback elapsed and so it sent this error to the client. The latter means that the client timeout for receiving a rpc-reply from the server elapsed.

michalvasko avatar Feb 09 '22 10:02 michalvasko

Thanks for your quick response!!

sowmi18 avatar Feb 09 '22 10:02 sowmi18

What is the default timeout value for a rpc? I set the timeout to 5 secs, but i got this error Callback event "rpc" with ID 1 processing timed out before 5 secs.

sowmi18 avatar Feb 09 '22 10:02 sowmi18

You have not specified which timeout you mean but the default server timeout for sysrepo RPC callback is here and the client rpc-reply timeout is here.

michalvasko avatar Feb 09 '22 10:02 michalvasko

Got the reason.Thanks @michalvasko

sowmi18 avatar Feb 09 '22 11:02 sowmi18