> I am using VPP version 20.05.1 on my setup and my application is running
> vppctl commands after checking that VPP process is created , but sometimes
> it happens that though vpp process is created and vpp is running, still
> vpp doesn't accept any vppctl commands and is giving this error:
> connect (fd 3, '/run/vpp/cli.sock'): Connection refused
> Is there any way we can check from the application code that vpp is up and
> running and ready to accept vppctl commands?
Not that I know of, but you can easily retry:
int timeout = 60; // 60s timeout
for (int i=0; i<timeout; i++) {
if (connect() >= 0) break; // success
sleep(1); // wait 1s and retry
}
if (60 == i) failure(); // timeout
// use cli...
ben
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#18350): https://lists.fd.io/g/vpp-dev/message/18350
Mute This Topic: https://lists.fd.io/mt/78994326/21656
Group Owner: [email protected]
Unsubscribe: https://lists.fd.io/g/vpp-dev/unsub [[email protected]]
-=-=-=-=-=-=-=-=-=-=-=-