view INSTALL.FreeBSD @ 1481:c9e9f8a71946

Update to 3GPP TS 32.299 V15.7.0 (2019-06) Add AVPs: - 3GPP-OC-Rating-Group, Unsigned32, code 1321 - 3GPP-OC-Request-Type, Enumerated, code 1322 - 3GPP-OC-Specific-Reduction, Grouped, code 1320 - 3GPP-PS-Data-Off-Status-32.299, Enumerated, code 4406 - API-Content, UTF8String, code 1309 - API-Direction, Enumerated, code 1310 - API-Identifier, OctetString, code 1311 - API-Invocation-Timestamp, Time, code 1312 - API-Network-Service-Node, Enumerated, code 1315 - API-Result-Code, Unsigned32, code 1313 - API-Size, Unsigned64, code 1314 - APN-Rate-Control, Grouped, code 3933 - APN-Rate-Control-Downlink, Grouped, code 3934 - APN-Rate-Control-Uplink, Grouped, code 3935 - Access-Network-Info-Change, Grouped, code 4401 - Additional-Exception-Reports, Enumerated, code 3936 - Announcement-Identifier, Unsigned32, code 3905 - Announcement-Information, Grouped, code 3904 - Announcement-Order, Unsigned32, code 3906 - Announcing-PLMN-ID, UTF8String, code 4408 - Announcing-UE-HPLMN-Identifier, UTF8String, code 3426 - Announcing-UE-VPLMN-Identifier, UTF8String, code 3427 - Application-Specific-Data, OctetString, code 3458 - Authorised-QoS, UTF8String, code 849 - BSSID, UTF8String, code 2716 - Basic-Service-Code, Grouped, code 3411 - Bearer-Capability, OctetString, code 3412 - CN-Operator-Selection-Entity, Enumerated, code 3421 - CP-CIoT-EPS-Optimisation-Indicator, Enumerated, code 3930 - CPDT-Information, Grouped, code 3927 - Called-Identity, UTF8String, code 3916 - Called-Identity-Change, Grouped, code 3917 - Cellular-Network-Information, OctetString, code 3924 - Charging-Per-IP-CAN-Session-Indicator, Enumerated, code 4400 - Civic-Address-Information, UTF8String, code 1305 - Coverage-Info, Grouped, code 3459 - Coverage-Status, Enumerated, code 3428 - Discoveree-UE-HPLMN-Identifier, UTF8String, code 4402 - Discoveree-UE-VPLMN-Identifier, UTF8String, code 4403 - Discoverer-UE-HPLMN-Identifier, UTF8String, code 4404 - Discoverer-UE-VPLMN-Identifier, UTF8String, code 4405 - EPDG-Address, Address, code 3425 - Enhanced-Diagnostics, Grouped, code 3901 - Exposure-Function-API-Information, Grouped, code 1316 - FE-Identifier-List, UTF8String, code 4413 - Forwarding-Pending, Enumerated, code 3415 - IMS-Visited-Network-Identifier, UTF8String, code 2713 - ISUP-Cause, Grouped, code 3416 - ISUP-Cause-Diagnostics, OctetString, code 3422 - ISUP-Cause-Location, Unsigned32, code 3423 - ISUP-Cause-Value, Unsigned32, code 3424 - ISUP-Location-Number, OctetString, code 3414 - Instance-Id, UTF8String, code 3402 - Inter-UE-Transfer, Enumerated, code 3902 - Language, UTF8String, code 3914 - Layer-2-Group-ID, OctetString, code 3429 - Location-Info, Grouped, code 3460 - MBMS-Charged-Party, Enumerated, code 2323 - MSC-Address, OctetString, code 3417 - MTC-IWF-Address, Address, code 3406 - Monitored-PLMN-Identifier, UTF8String, code 3430 - Monitoring-Event-Configuration-Activity, Integer32, code 3919 - Monitoring-Event-Functionality, Integer32, code 3922 - Monitoring-Event-Information, Grouped, code 3921 - Monitoring-Event-Report-Data, Grouped, code 3920 - Monitoring-Event-Report-Number, Unsigned32, code 3923 - Monitoring-UE-HPLMN-Identifier, UTF8String, code 3431 - Monitoring-UE-Identifier, UTF8String, code 3432 - Monitoring-UE-VPLMN-Identifier, UTF8String, code 3433 - NIDD-Submission, Grouped, code 3928 - Network-Call-Reference-Number, OctetString, code 3418 - PC3-Control-Protocol-Cause, Integer32, code 3434 - PC3-EPC-Control-Protocol-Cause, Integer32, code 3435 - PC5-Radio-Technology, Enumerated, code 1300 - Play-Alternative, Enumerated, code 3913 - Privacy-Indicator, Enumerated, code 3915 - ProSe-3rd-Party-Application-ID, UTF8String, code 3440 - ProSe-Direct-Communication-Reception-Data-Container, Grouped, code 3461 - ProSe-Direct-Communication-Transmission-Data-Container, Grouped, code 3441 - ProSe-Direct-Discovery-Model, Enumerated, code 3442 - ProSe-Event-Type, Enumerated, code 3443 - ProSe-Function-IP-Address, Address, code 3444 - ProSe-Function-PLMN-Identifier, UTF8String, code 3457 - ProSe-Functionality, Enumerated, code 3445 - ProSe-Group-IP-Multicast-Address, Address, code 3446 - ProSe-Information, Grouped, code 3447 - ProSe-Range-Class, Enumerated, code 3448 - ProSe-Reason-For-Cancellation, Enumerated, code 3449 - ProSe-Request-Timestamp, Time, code 3450 - ProSe-Role-Of-UE, Enumerated, code 3451 - ProSe-Source-IP-Address, Address, code 3452 - ProSe-Target-Layer-2-ID, OctetString, code 4410 - ProSe-UE-ID, OctetString, code 3453 - ProSe-UE-to-Network-Relay-UE-ID, OctetString, code 4409 - Proximity-Alert-Indication, Enumerated, code 3454 - Proximity-Alert-Timestamp, Time, code 3455 - Proximity-Cancellation-Timestamp, Time, code 3456 - Quota-Indicator, Enumerated, code 3912 - RAN-End-Time, Time, code 1301 - RAN-Secondary-RAT-Usage-Report, Grouped, code 1302 - RAN-Start-Time, Time, code 1303 - Radio-Frequency, OctetString, code 3462 - Radio-Parameter-Set-Info, Grouped, code 3463 - Radio-Parameter-Set-Values, OctetString, code 3464 - Radio-Resources-Indicator, Integer32, code 3465 - Rate-Control-Max-Message-Size, Unsigned32, code 3937 - Rate-Control-Max-Rate, Unsigned32, code 3938 - Rate-Control-Time-Unit, Unsigned32, code 3939 - Reason-Header, UTF8String, code 3401 - Related-Change-Condition-Information, Grouped, code 3925 - Related-IMS-Charging-Identifier, UTF8String, code 2711 - Related-IMS-Charging-Identifier-Node, Address, code 2712 - Related-Trigger, Grouped, code 3926 - Relay-IP-address, Address, code 4411 - Requested-PLMN-Identifier, UTF8String, code 3436 - Requestor-PLMN-Identifier, UTF8String, code 3437 - Role-Of-ProSe-Function, Enumerated, code 3438 - Route-Header-Received, UTF8String, code 3403 - Route-Header-Transmitted, UTF8String, code 3404 - SCEF-Address, Address, code 1317 - SCS-AS-Address, Grouped, code 3940 - SCS-Address, Address, code 3941 - SCS-Realm, DiameterIdentity, code 3942 - SGi-PtP-Tunnelling-Method, Enumerated, code 3931 - SM-Device-Trigger-Indicator, Enumerated, code 3407 - SM-Device-Trigger-Information, Grouped, code 3405 - SM-Sequence-Number, Unsigned32, code 3408 - SMS-Result, Unsigned32, code 3409 - Secondary-RAT-Type, OctetString, code 1304 - Serving-Node-Identity, DiameterIdentity, code 3929 - Start-of-Charging, Time, code 3419 - TAD-Identifier, Enumerated, code 2717 - TLTRI, Unsigned32, code 1318 - TWAG-Address, Address, code 3903 - TWAN-User-Location-Info, Grouped, code 2714 - Target-IP-Address, Address, code 4412 - Teleservice, OctetString, code 3413 - Time-First-Reception, Time, code 3466 - Time-First-Transmission, Time, code 3467 - Time-Indicator, Unsigned32, code 3911 - Transmitter-Info, Grouped, code 3468 - UNI-PDU-CP-Only-Flag, Enumerated, code 3932 - UWAN-User-Location-Info, Grouped, code 3918 - Unused-Quota-Timer, Unsigned32, code 4407 - Usage-Information-Report-Sequence-Number, Integer32, code 3439 - VCS-Information, Grouped, code 3410 - VLR-Number, OctetString, code 3420 - Variable-Part, Grouped, code 3907 - Variable-Part-Order, Unsigned32, code 3908 - Variable-Part-Type, Unsigned32, code 3909 - Variable-Part-Value, UTF8String, code 3910 - WLAN-Operator-Id, Grouped, code 1306 - WLAN-Operator-Name, UTF8String, code 1307 - WLAN-PLMN-Id, UTF8String, code 1308 3GPP TS 32.299 V11.8.0 (2013-07) renamed LCS-Requestor-Id (1239) to LCS-Requestor-ID (1239). 3GPP TS 32.299 V11.8.0 (2013-07) renamed LCS-Requestor-Id-String (1240) to LCS-Requestor-ID-String (1240). 3GPP TS 32.299 V13.1.0 (2015-06) renamed PoC-User-Role-info-Units (1254) to PoC-User-Role-Info-Units (1254). 3GPP TS 32.299 V11.10.0 (2013-12) renamed Status (2702) to Status-Code (2702), and then 3GPP TS 32.299 V11.14.0 (2014-12) renamed Status-Code (2702) to Status-AS-Code (2702).
author Luke Mewburn <luke@mewburn.net>
date Thu, 26 Mar 2020 15:26:18 +1100
parents a0ab56aa089f
children 699c3fb0c57b
line wrap: on
line source

See INSTALL file for general instructions on building freeDiameter.

------------------
QUICK INSTRUCTIONS
------------------

On FreeBSD-8.0 at least the following ports packages were required (should be same on FreeBSD-7.x):
 cmake flex bison gnutls

Then the cmake command had to look like:
 cmake -DFLEX_EXECUTABLE:FILEPATH=/usr/local/bin/flex -DSCTP_USE_MAPPED_ADDRESSES:BOOL=ON ...


---------------------
COMPLETE INSTRUCTIONS
---------------------

1) If you don't have freeBSD yet:
   Install minimal system + ports using initial installer /usr/sbin/sysinstall


2) Install 'cmake'

 a) from sources:
    # cd /usr/ports/devel/cmake
    # make install
    
 b) or from package (don't forget to set your PACKAGEROOT appropriately. Ex: set PACKAGEROOT=ftp://ftp.jp.freebsd.org):
    # pkg_add -v -r cmake
	
 
3) Install 'mercurial' (optional)
  (replace 'cmake' by 'mercurial' in the previous command) 

4) Install 'flex' and 'bison', same way.

5) Install 'gnutls' and 'libidn', same way also.

6) Retrieve freeDiameter source code:
   # cd ~
   # /usr/local/bin/hg clone http://www.freediameter.net/hg/freeDiameter/
   
6b) Make a build directory
   # mkdir fD-build
   # cd fD-build
   
7) Run cmake for freeDiameter (add other flags as you see fit, see INSTALL for more details)
   # /usr/local/bin/cmake -DFLEX_EXECUTABLE:FILEPATH=/usr/local/bin/flex -DSCTP_USE_MAPPED_ADDRESSES:BOOL=ON ../freeDiameter

8) Compile, optionnaly test
   # make
   # make test

9) Install
   # make install
   
10) Run (the install path can be changed during cmake step):
   # /usr/local/bin/freeDiameterd --help


------------------------------
app_acct test ADDITIONAL STEPS
------------------------------
Here is additional steps in order to run the test for app_acct

1) Install the required packages
  # pkg_add -v -r postgresql84-client
  # pkg_add -v -r postgresql84-server

2) Prepare access to the database:
  # echo postgresql_enable=YES >> /etc/rc.conf
  # /usr/local/etc/rc.d/postgresql initdb
  # su - pgsql
  > /usr/local/bin/pg_ctl -D /usr/local/pgsql/data -l logfile start
  > /usr/local/bin/createuser root
  Shall the new user be allowed to create databases? (y/n) y
  > logout
  # /usr/local/bin/createdb root
  # /usr/local/bin/psql root
  root=# CREATE TABLE incoming_test (
  root(# recorded_on timestamp with time zone NOT NULL,
  root(# "Accounting-Record-Type" integer,
  root(# "Session-Id" bytea,
  root(# "Accounting-Record-Number" integer,
  root(# "Route-Record1" bytea,
  root(# "Route-Record2" bytea,
  root(# "Route-Record3" bytea,
  root(# "Route-Record4" bytea );
  root=# \q

3) configure the sources
  # make edit_cache
   BUILD_APP_ACCT:BOOL=ON
   TEST_APP_ACCT:BOOL=ON
   TEST_APP_ACCT_CONNINFO:STRING="user=root dbname=root"
   
4) run the test
  # tests/testappacct -d
  or
  # make test
  
  
----------------------------------
Segmentation fault on program exit
----------------------------------

In case you encounter a segmentation fault on program termination like this:
  [...]
  freeDiameterd framework is terminated.
  Segmentation fault: 11 (core dumped)

with a backtrace like this:
  #0  0x0000000801a414a0 in ?? ()
  #1  0x0000000800f99274 in __cxa_finalize () from /lib/libc.so.7
  #2  0x0000000800f460b7 in exit () from /lib/libc.so.7
  
You may try to add the following compilation directive in cmake:
  -DSKIP_DLCLOSE:BOOL=ON

Note: this segmentation fault was experienced with:
 - FreeBSD 8.1
 - 64 bits architecture only.
 - Profiling mode only.


"Welcome to our mercurial repository"