Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Network #44

Open
wants to merge 5 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions RELEASE_NOTES
Original file line number Diff line number Diff line change
@@ -1,5 +1,17 @@
Release Notes for iocStats
--------------------------
R3.1.16-ALS00.02: August 3,2021
* Changes by Mirek Dach
- Network statistics was added
- Multiple network ifs could be monitored
- db/ioc_NetStats.db
R3.1.16-ALS00.01: July 1,2021
* Changes by Mirek Dach
- Not connected Channel access links monitoring was added
- Not connected PVs in Seq programs monitoring was added
- There are two libraries built:
- libdevIocStatsSeq -> for iocs with seqencer
- libdevIocStats -> for iocs without sequencer
iocStats-R3-1-15: Nov 3, 2016
* Changes by Mark Rivers:
- Improved the layout of the medm files to avoid overlapping widgets, etc.
Expand Down
10 changes: 5 additions & 5 deletions configure/RELEASE
Original file line number Diff line number Diff line change
Expand Up @@ -5,18 +5,18 @@
#NOTE: MSI moved to CONFIG_SITE.

# SNCSEQ required only if testIocStatsApp will be built.
MAKE_TEST_IOC_APP=YES
#MAKE_TEST_IOC_APP=YES

# =============================================================
# Define the version of modules needed by
# IOC apps or other Support apps - used by testIocStatsApp
# =============================================================
SUPPORT=/usr/local/epics/R3.14.11/modules/soft/synApps_5_5/support
#SUPPORT=/usr/local/epics/R3.14.11/modules/soft/synApps_5_5/support

SNCSEQ = $(SUPPORT)/seq-2-0-12

EPICS_BASE=/afs/slac/g/spear/epics/base
#SNCSEQ = $(SUPPORT)/seq-2-0-12

EPICS_BASE=/usr/local/epics/R7.0.7/base
#NETWORK_STAT=NO
# These lines allow developers to override these RELEASE settings
# without having to modify this file directly.
-include $(TOP)/../RELEASE.local
Expand Down
10 changes: 8 additions & 2 deletions devIocStats/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,10 @@ INC += devIocStatsOSD.h

#=============================

LIBRARY_IOC = devIocStats
LIBRARY_IOC = devIocStats devIocStatsSeq

devIocStats_LIBS = $(EPICS_BASE_IOC_LIBS)
devIocStatsSeq_LIBS = $(EPICS_BASE_IOC_LIBS)
devIocStats_SYS_LIBS_solaris = kstat
devIocStats_SYS_LIBS_WIN32 += psapi

Expand All @@ -26,7 +27,11 @@ SRCS += devIocStatsString.c
SRCS += devIocStatsWaveform.c
SRCS += devIocStatsSub.c
SRCS += devIocStatsTest.c

SRCS += ioccar.c
devIocStats_SRCS += seqFunction.c
ifeq ($(NETWORK_STAT),NO)
USR_CFLAGS_Linux += -DNO_NETWORK_STAT
endif
# OSD parts
# Base 3.14 does not correctly define POSIX=NO for mingw
ifeq (mingw,$(findstring mingw, $(T_A)))
Expand All @@ -35,6 +40,7 @@ endif
SRCS += osdCpuUsage.c
SRCS += osdCpuUtilization.c
SRCS += osdFdUsage.c
SRCS += osdNetStats.c
SRCS += osdMemUsage.c
SRCS += osdWorkspaceUsage.c
SRCS += osdClustInfo.c
Expand Down
2 changes: 2 additions & 0 deletions devIocStats/devIocStats.dbd
Original file line number Diff line number Diff line change
@@ -1,9 +1,11 @@
device(ai,INST_IO,devAiStats,"IOC stats")
device(ai,INST_IO,devAiClusts,"IOC stats clusts")
device(ai,INST_IO,devAiNet,"IOC net stats")
device(ao,INST_IO,devAoStats,"IOC stats")
device(stringin,INST_IO,devStringinStats,"IOC stats")
device(stringin,INST_IO,devStringinEnvVar,"IOC env var")
device(stringin,INST_IO,devStringinEpics,"IOC epics var")
device(stringin,INST_IO,devStringinNet,"IOC net stats")
device(waveform,INST_IO,devWaveformStats,"IOC stats")
function(rebootProc)
function(scanMonInit)
Expand Down
11 changes: 11 additions & 0 deletions devIocStats/devIocStats.h
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@
#define ST_CMD "ST_CMD"
#define ENGINEER "ENGINEER"
#define LOCATION "LOCATION"
#define WIKI "WIKI"

#include "devIocStatsOSD.h"

Expand Down Expand Up @@ -112,6 +113,16 @@ extern int devIocStatsGetClusterUsage (int pool, int *pval);
/* Network Interface Errors */
extern int devIocStatsInitIFErrors (void);
extern int devIocStatsGetIFErrors (ifErrInfo *pval);
typedef struct tNetList
{
char *pcNetIf;
void *pData;
struct tNetList *next;
}tNetList;
#define NET_OK 0
#define NET_NOK 1
extern int getPacketStats(void *ifa);
extern int getIpAddr(char *pcIf,char **pcIfAddr);

/* Boot Info */
extern int devIocStatsInitBootInfo (void);
Expand Down
Loading