Attention is currently required from: daniel, laforge, pespin.
osmith has posted comments on this change by pespin. ( https://gerrit.osmocom.org/c/osmo-pcap/+/39287?usp=email )
Change subject: server: Support storing of pcapng format
......................................................................
Patch Set 5: Code-Review+1
--
To view, visit https://gerrit.osmocom.org/c/osmo-pcap/+/39287?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email
Gerrit-MessageType: comment
Gerrit-Project: osmo-pcap
Gerrit-Branch: master
Gerrit-Change-Id: I275d28ab418a1514fa9c5c7c20f3d831cc6af8bb
Gerrit-Change-Number: 39287
Gerrit-PatchSet: 5
Gerrit-Owner: pespin <pespin(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: daniel <dwillmann(a)sysmocom.de>
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Reviewer: osmith <osmith(a)sysmocom.de>
Gerrit-Attention: laforge <laforge(a)osmocom.org>
Gerrit-Attention: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: daniel <dwillmann(a)sysmocom.de>
Gerrit-Comment-Date: Mon, 13 Jan 2025 16:46:10 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Attention is currently required from: daniel, laforge, pespin.
osmith has posted comments on this change by pespin. ( https://gerrit.osmocom.org/c/osmo-pcap/+/39265?usp=email )
Change subject: client: Support generation of pcapng file format
......................................................................
Patch Set 9: Code-Review+1
(1 comment)
File include/osmo-pcap/osmo_pcap_file.h:
https://gerrit.osmocom.org/c/osmo-pcap/+/39265/comment/f1e7c62d_b3620d38?us… :
PS8, Line 87: /* uint32_t block_total_length */
> Nope, it's fine, the field is duplicated at the end of block_body so that the file can be navigated […]
ah nice
--
To view, visit https://gerrit.osmocom.org/c/osmo-pcap/+/39265?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email
Gerrit-MessageType: comment
Gerrit-Project: osmo-pcap
Gerrit-Branch: master
Gerrit-Change-Id: I3c80518a1e53a1f77e1aca8dfa83f683f9516ad6
Gerrit-Change-Number: 39265
Gerrit-PatchSet: 9
Gerrit-Owner: pespin <pespin(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: daniel <dwillmann(a)sysmocom.de>
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Reviewer: osmith <osmith(a)sysmocom.de>
Gerrit-Attention: laforge <laforge(a)osmocom.org>
Gerrit-Attention: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: daniel <dwillmann(a)sysmocom.de>
Gerrit-Comment-Date: Mon, 13 Jan 2025 16:45:44 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: Yes
Comment-In-Reply-To: osmith <osmith(a)sysmocom.de>
Comment-In-Reply-To: pespin <pespin(a)sysmocom.de>
Attention is currently required from: csaba.sipos, fixeria, laforge.
pespin has posted comments on this change by csaba.sipos. ( https://gerrit.osmocom.org/c/osmo-bsc/+/39290?usp=email )
Change subject: nokia_site: introduce hopping control for Nokia *Site
......................................................................
Patch Set 7:
(2 comments)
File src/osmo-bsc/bts_vty.c:
https://gerrit.osmocom.org/c/osmo-bsc/+/39290/comment/f3af5b7f_a6e84c99?usp… :
PS6, Line 468: DEFUN_ATTR(cfg_bts_nokia_site_hopping_type,
> This is just a Nokia specific OML extension the BTS needs. […]
Done
https://gerrit.osmocom.org/c/osmo-bsc/+/39290/comment/5be16043_cfaa4e93?usp… :
PS6, Line 470: nokia_hopping
> Done
Unless that 0|1 numbering is a well know thing from nokia, I'd also favour to have proper string literal which are somehow self-descriptive as Vadim proposed.
--
To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/39290?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email
Gerrit-MessageType: comment
Gerrit-Project: osmo-bsc
Gerrit-Branch: master
Gerrit-Change-Id: Idb1d269d2ee80d72ede2394125e8acedf0ee8b06
Gerrit-Change-Number: 39290
Gerrit-PatchSet: 7
Gerrit-Owner: csaba.sipos <metro4(a)freemail.hu>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-CC: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-CC: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: csaba.sipos <metro4(a)freemail.hu>
Gerrit-Attention: laforge <laforge(a)osmocom.org>
Gerrit-Attention: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Comment-Date: Mon, 13 Jan 2025 16:18:43 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: csaba.sipos <metro4(a)freemail.hu>
Comment-In-Reply-To: pespin <pespin(a)sysmocom.de>
Comment-In-Reply-To: fixeria <vyanitskiy(a)sysmocom.de>
Attention is currently required from: daniel, laforge, osmith.
Hello Jenkins Builder, daniel, laforge, osmith,
I'd like you to reexamine a change. Please visit
https://gerrit.osmocom.org/c/osmo-pcap/+/39265?usp=email
to look at the new patch set (#9).
The following approvals got outdated and were removed:
Code-Review+1 by osmith, Verified+1 by Jenkins Builder
Change subject: client: Support generation of pcapng file format
......................................................................
client: Support generation of pcapng file format
Support transmitting traffic recordings in pcapng towards
osmo-pca-server based on VTY config. Old libpcap's file format
(.pcap) is still left as default to to keep backward compatibility
towards older osmo-pcap-server instances still running. Furthermore,
.pcap support is more extended than .pcapng since it's way older.
When pcapng file format is selected, osmo-pcap-client will use the same
osmo-pcap protocol used in pcap mode, but the payloads encoded in
messages will be in pcapng file format instead of pcap.
This means, for LINK_HDR message type it will encode a file header with
a payload consisting of 1 SHB + N IDB blocks (one for each network
interface being monitored).
Upon each packet recording received from the monitoring interface, it
will encode a LINK_DATA message containing a payload with a encoded
pcapng block.
This works mostly transparetly on the osmo-pcap-server side, since in
general it handles those payloads mostly transparently. Only some sanity
checks will need to be updated and improve there to account for the new
pcapng blocks. This in turn requires identifying pcap vs pcapng format
being recieved from the client, and also placing the proper file suffix
when creating the file. This will be done in a follow-up patch modyfing
the server side.
Related: SYS#5822
Change-Id: I3c80518a1e53a1f77e1aca8dfa83f683f9516ad6
---
M doc/manuals/chapters/client.adoc
M include/osmo-pcap/osmo_pcap_client.h
M include/osmo-pcap/osmo_pcap_file.h
M src/osmo_client_core.c
M src/osmo_client_network.c
M src/osmo_client_vty.c
M src/osmo_pcap_file.c
7 files changed, 534 insertions(+), 10 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/osmo-pcap refs/changes/65/39265/9
--
To view, visit https://gerrit.osmocom.org/c/osmo-pcap/+/39265?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email
Gerrit-MessageType: newpatchset
Gerrit-Project: osmo-pcap
Gerrit-Branch: master
Gerrit-Change-Id: I3c80518a1e53a1f77e1aca8dfa83f683f9516ad6
Gerrit-Change-Number: 39265
Gerrit-PatchSet: 9
Gerrit-Owner: pespin <pespin(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: daniel <dwillmann(a)sysmocom.de>
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Reviewer: osmith <osmith(a)sysmocom.de>
Gerrit-Attention: osmith <osmith(a)sysmocom.de>
Gerrit-Attention: laforge <laforge(a)osmocom.org>
Gerrit-Attention: daniel <dwillmann(a)sysmocom.de>
Attention is currently required from: daniel, laforge, osmith, pespin.
Hello Jenkins Builder, daniel, laforge, osmith,
I'd like you to reexamine a change. Please visit
https://gerrit.osmocom.org/c/osmo-pcap/+/39287?usp=email
to look at the new patch set (#5).
The following approvals got outdated and were removed:
Code-Review+1 by osmith, Verified+1 by Jenkins Builder
Change subject: server: Support storing of pcapng format
......................................................................
server: Support storing of pcapng format
Improve existing logic doing validation on payload data and generalize
the file_hdr field to account for the possibily of receiving recordings
in pcapng format.
This requires, during LINK_HDR when file header is received, discering
whether the recording is being done in pcap vs pcapng, (and in pcapng
figuring out the endianness of the file) and then applying validation
based on that knowledge.
With that knowledge, osmo-pcap-server can now store the pcap(ng) file
using the proper suffix for the file.
Related: SYS#5822
Change-Id: I275d28ab418a1514fa9c5c7c20f3d831cc6af8bb
---
M include/osmo-pcap/osmo_pcap_file.h
M include/osmo-pcap/osmo_pcap_server.h
M src/Makefile.am
M src/osmo_pcap_file.c
M src/osmo_server_network.c
M tests/rotate_localtime/Makefile.am
6 files changed, 333 insertions(+), 46 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/osmo-pcap refs/changes/87/39287/5
--
To view, visit https://gerrit.osmocom.org/c/osmo-pcap/+/39287?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email
Gerrit-MessageType: newpatchset
Gerrit-Project: osmo-pcap
Gerrit-Branch: master
Gerrit-Change-Id: I275d28ab418a1514fa9c5c7c20f3d831cc6af8bb
Gerrit-Change-Number: 39287
Gerrit-PatchSet: 5
Gerrit-Owner: pespin <pespin(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: daniel <dwillmann(a)sysmocom.de>
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Reviewer: osmith <osmith(a)sysmocom.de>
Gerrit-Attention: osmith <osmith(a)sysmocom.de>
Gerrit-Attention: laforge <laforge(a)osmocom.org>
Gerrit-Attention: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: daniel <dwillmann(a)sysmocom.de>
Attention is currently required from: daniel, laforge, osmith.
pespin has posted comments on this change by pespin. ( https://gerrit.osmocom.org/c/osmo-pcap/+/39265?usp=email )
Change subject: client: Support generation of pcapng file format
......................................................................
Patch Set 8:
(3 comments)
File doc/manuals/chapters/client.adoc:
https://gerrit.osmocom.org/c/osmo-pcap/+/39265/comment/01f3e45b_9d5c6dc3?us… :
PS8, Line 59: reate
> create
Done
File include/osmo-pcap/osmo_pcap_file.h:
https://gerrit.osmocom.org/c/osmo-pcap/+/39265/comment/0df37a3e_3053cca0?us… :
PS8, Line 87: /* uint32_t block_total_length */
> looks like a leftover, because block_total_length is already in line 85
Nope, it's fine, the field is duplicated at the end of block_body so that the file can be navigated backwards. See pcapng spec 😊
File src/osmo_client_network.c:
https://gerrit.osmocom.org/c/osmo-pcap/+/39265/comment/da2123ef_81082df2?us… :
PS8, Line 389: .
> (remove the dot?)
Done
--
To view, visit https://gerrit.osmocom.org/c/osmo-pcap/+/39265?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email
Gerrit-MessageType: comment
Gerrit-Project: osmo-pcap
Gerrit-Branch: master
Gerrit-Change-Id: I3c80518a1e53a1f77e1aca8dfa83f683f9516ad6
Gerrit-Change-Number: 39265
Gerrit-PatchSet: 8
Gerrit-Owner: pespin <pespin(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: daniel <dwillmann(a)sysmocom.de>
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Reviewer: osmith <osmith(a)sysmocom.de>
Gerrit-Attention: osmith <osmith(a)sysmocom.de>
Gerrit-Attention: laforge <laforge(a)osmocom.org>
Gerrit-Attention: daniel <dwillmann(a)sysmocom.de>
Gerrit-Comment-Date: Mon, 13 Jan 2025 16:14:31 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: osmith <osmith(a)sysmocom.de>
pespin has submitted this change. ( https://gerrit.osmocom.org/c/osmo-pcap/+/39272?usp=email )
Change subject: server: Delay reopen of pcap only until necessary
......................................................................
server: Delay reopen of pcap only until necessary
If we are asked to reopen a pcap file (eg due to external SIGUSR1) while
in the middle of receiving a data packet (we already received the header
of the segment so data will arrive soon), code exists to delay reopening
so that we can include that last packet which arrived because the time
where we were asked to reopen.
However, the new pcap file was reopened only after next packet arrived.
Instead, we want to reopen it as soon as that last packet is received,
so that a new pcap file is created. This allows better tracking eg.
empty traffic during time in between last data packet before reopen and
the next data packet arriving.
While at it, rename the variable to make it more informative, and
convert it to a bool.
Change-Id: Id79500717a2e186aac979cded340a5af6ce3035b
---
M include/osmo-pcap/osmo_pcap_server.h
M src/osmo_server_network.c
2 files changed, 8 insertions(+), 7 deletions(-)
Approvals:
Jenkins Builder: Verified
osmith: Looks good to me, approved
laforge: Looks good to me, but someone else must approve
diff --git a/include/osmo-pcap/osmo_pcap_server.h b/include/osmo-pcap/osmo_pcap_server.h
index dad81d3..030a353 100644
--- a/include/osmo-pcap/osmo_pcap_server.h
+++ b/include/osmo-pcap/osmo_pcap_server.h
@@ -97,7 +97,7 @@
/* read buffering */
int state;
int pend;
- int reopen;
+ bool reopen_delayed;
struct osmo_pcap_data *data;
/* statistics */
diff --git a/src/osmo_server_network.c b/src/osmo_server_network.c
index 55c84cf..7d46b90 100644
--- a/src/osmo_server_network.c
+++ b/src/osmo_server_network.c
@@ -686,6 +686,12 @@
OSMO_ASSERT(0);
}
+ if (conn->reopen_delayed) {
+ LOGP(DSERVER, LOGL_INFO, "Reopening log for %s now.\n", conn->name);
+ restart_pcap(conn);
+ conn->reopen_delayed = false;
+ }
+
return rc;
}
@@ -693,11 +699,6 @@
static int dispatch_read(struct osmo_pcap_conn *conn)
{
if (conn->state == STATE_INITIAL) {
- if (conn->reopen) {
- LOGP(DSERVER, LOGL_INFO, "Reopening log for %s now.\n", conn->name);
- restart_pcap(conn);
- conn->reopen = 0;
- }
return read_cb_initial(conn);
} else if (conn->state == STATE_DATA) {
return read_cb_data(conn);
@@ -874,7 +875,7 @@
restart_pcap(conn);
} else {
LOGP(DSERVER, LOGL_INFO, "Delaying %s until current packet is complete.\n", conn->name);
- conn->reopen = 1;
+ conn->reopen_delayed = true;
}
}
}
--
To view, visit https://gerrit.osmocom.org/c/osmo-pcap/+/39272?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email
Gerrit-MessageType: merged
Gerrit-Project: osmo-pcap
Gerrit-Branch: master
Gerrit-Change-Id: Id79500717a2e186aac979cded340a5af6ce3035b
Gerrit-Change-Number: 39272
Gerrit-PatchSet: 3
Gerrit-Owner: pespin <pespin(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Reviewer: osmith <osmith(a)sysmocom.de>
Gerrit-Reviewer: pespin <pespin(a)sysmocom.de>