diff options
author | Pau Espin Pedrol <pespin@sysmocom.de> | 2019-10-11 21:17:40 +0200 |
---|---|---|
committer | laforge <laforge@osmocom.org> | 2019-10-22 19:38:53 +0000 |
commit | dec38c141694412f7c114bcbf01cf71beacb73e0 (patch) | |
tree | 04223e08ad6d6781c3288566079902adaee52703 | |
parent | 80b135581909fef595d48436ab04dbcb147e3895 (diff) |
ss7: Log local and remote address set upon ASP restart
Change-Id: I35c2581923ed3e1f7aff6c137ddf356882bac621
-rw-r--r-- | src/osmo_ss7.c | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/src/osmo_ss7.c b/src/osmo_ss7.c index a0b931e..e7e688d 100644 --- a/src/osmo_ss7.c +++ b/src/osmo_ss7.c @@ -465,7 +465,7 @@ int osmo_ss7_user_register(struct osmo_ss7_instance *inst, uint8_t service_ind, * \param[in] inst SS7 instance for which we register the user * \param[in] service_ind Service (ISUP, SCCP, ...) * \param[in] user (optional) SS7 user. If present, we will not - * unregister other users + * unregister other users * \returns 0 on success; negative on error */ int osmo_ss7_user_unregister(struct osmo_ss7_instance *inst, uint8_t service_ind, struct osmo_ss7_user *user) @@ -1277,9 +1277,13 @@ int osmo_ss7_asp_restart(struct osmo_ss7_asp *asp) { int rc; enum xua_asp_role role; + char bufloc[512], bufrem[512]; OSMO_ASSERT(ss7_initialized); - LOGPASP(asp, DLSS7, LOGL_INFO, "Restarting ASP\n"); + osmo_ss7_asp_peer_snprintf(bufloc, sizeof(bufloc), &asp->cfg.local); + osmo_ss7_asp_peer_snprintf(bufrem, sizeof(bufrem), &asp->cfg.remote); + LOGPASP(asp, DLSS7, LOGL_INFO, "Restarting ASP %s, %s ==> %s\n", + asp->cfg.name, bufloc, bufrem); if (!asp->cfg.is_server) { /* We are in client mode now */ @@ -1312,7 +1316,7 @@ int osmo_ss7_asp_restart(struct osmo_ss7_asp *asp) rc = osmo_stream_cli_open(asp->client); if (rc < 0) { LOGPASP(asp, DLSS7, LOGL_ERROR, "Unable to open stream" - " client for ASP %s\n", asp->cfg.name); + " client for ASP %s, %s ==> %s\n", asp->cfg.name, bufloc, bufrem); /* we don't return error in here because osmo_stream_cli_open() will continue to retry (due to timeout being explicitly set with osmo_stream_cli_set_reconnect_timeout() above) to connect so the error is transient */ |