aboutsummaryrefslogtreecommitdiffstats
path: root/openbsc/src/libbsc/bsc_vty.c
AgeCommit message (Collapse)AuthorFilesLines
2015-01-31bsc/nitb: Allow to set the GPRS mode through the ctrl commandHolger Hans Peter Freyther1-9/+2
Create a control command to read and modify the gprs mode. Use the get_string_value to indicate if the value was found or not. This is useful for the ctrl interface where I didn't want to replicate "none", "gprs" and "egprs". Share code to verify that a BTS supports the mode. Related: SYS#591
2015-01-02logging: Only compare the subscr addressHolger Hans Peter Freyther1-18/+0
Move the "logging filter imsi IMSI" into the BTS/NITB code to allow to set the gsm_subscriber and only compare it. This way we simply compare the subscriber address and don't have to care if the subscriber data is still valid.
2015-01-02lchan: Remember why a channel is broken using static stringsHolger Hans Peter Freyther1-2/+5
Remember why a channel is being marked as broken. So we can maybe understand what happend.
2014-12-30Add basic support for CBCH / SMS-CB (Cell Brroadcast)Harald Welte1-0/+50
We can now configure the pyisical channel types for CBCH either in the CCCH+SDCCH4 or in the SDCCH8 chanel combination. Depending on whether a CBCH exists on the BTS, we also generate the SI4 with matching CBCH channel description to notify the phones of the existance of the CBCH. There is now a VTY command how a SMS-CB message can be sent to a given BTS. We do not yet have any logic at all for actual scheduling of multiple CBCH RSL messages towards one or multiple BTSs yet, though.
2014-12-17bts: Add some simple dependency between different BTSHolger Hans Peter Freyther1-0/+63
E.g. for the sysmoBTS2050 we have the requirement that the first board connects before the second due clocking. The easiest point to enforce this is the BSC. Add a simple bitmask based system to allow to express dependencies for IP based systems.
2014-12-05msc: Add and use gsm_subscriber_groupJacob Erlbeck1-2/+2
Currently every subcriber object directly refers to the gsm_network which contains a flag shared by every related subscriber (keep_subscr). This adds a dependency on gsm_network even if only the function defined in gsm_subscriber_base.c are used. This patch adds a new struct gsm_subscriber_group which contains the keep_subscr flag and a back reference to the network object. The latter is not dereferenced in gsm_subscriber_base.c, so it can safely be set to NULL when only that part of the gsm_subscriber API is being used. It also changes that API to use gsm_subscriber_group instead of gsm_network parameters. Since there are some places where a pointer to the gsm_network is needed but where only a gsm_subscriber is available, a 'net' back pointer is added to the group struct, too. Nevertheless subscr group and network could be separated completely, but this is not the topic of this commit. Sponsored-by: On-Waves ehf
2014-04-11bsc: Timers are in seconds, clarify that in the online helpHolger Hans Peter Freyther1-1/+1
2014-04-04bsc/msc: Extension can never be NULL use strlen insteadHolger Hans Peter Freyther1-1/+1
Fixes: Coverity CID 1040717
2014-02-08bsc: rf_ctrl will always be created, remove the NULL checksHolger Hans Peter Freyther1-2/+2
2014-01-19TSC: Add new gsm_ts_tsc() function to resolve TSC of TSHarald Welte1-2/+1
We don't want every caller to check for ts->tsc == -1 and then using ts->trx->bts->tsc instead. Rather, introduce a new inline function to retrieve the correct value.
2014-01-19Do not expect all BTSs support TSC != BCCHarald Welte1-1/+22
We introduce a new feature indicating if the given BTS model supports a TSC that is different from the BCC (lower 3 bits of BSIC).
2014-01-16si: Add a config option to disable SI2ter/SI2bis/SI5ter/SI5bis messagesJacob Erlbeck1-0/+27
The iPhone5 (US) appears to have some issues with the SIs generated, or the nanoBTS is not sending them correctly. Add a configurable hack to put all bands into the SI2/SI5 message. It is enabled by the bts VTY command 'force-combined-si'. This is a quick change without much reflection and watching for side effects. I have verfied that a network with ARFCN 134 and neighbors ARFCN 130 and 512 do not get generate the SI2ter and announce everything inside the SI2. This patch is conceptually based on 'si: Add a hack to disable SI2ter/SI2bis/SI5ter/SI5bis messages' (692daaf2d2). Ticket: OW#1062 Sponsored-by: On-Waves ehf
2014-01-14Each BTS can be configured for speech support (other than GSM full rate)Andreas Eversberg1-0/+81
Speech codings which are not supported by BTS will be removed from the bearer capability information element after parsing. This way it is not required for the MNCC application to consider support of each BTS. Only GSM full rate is supported by default.
2014-01-09Add VTY option for Nokia BTS that does not send RELease CONFirm messageAndreas Eversberg1-1/+25
This option is a workarround for a bug found in Nokia InSite BTS firmware version 3.0.0. There is no RELease CONFirm message for local end release. Nokia MetroSite with firmware version 4.178.16 is not affected. TS 04.06 Chapter 5.4.4.4 "Local end release procedure" states that a confirm must be sent by layer 2 when receiving a local end release request. In order to correctly switch a channel (handover or assignment), local end release is required.
2013-12-18Fix: Nokia requires VTY's "oml e1" parameters alsoAndreas Eversberg1-1/+1
When writing config file, OML configuration must be written for all E1 based BTS, which includes Nokia *Site BTS.
2013-12-12vty: Address coverity issue with subscr->name never being NULLHolger Hans Peter Freyther1-1/+1
Coverity points out that subscr->name is an array and never NULL. Use strlen instead in this check. Fixes: Coverity CID 1040717
2013-11-22bsc: Add a VTY command to show the paging group for a BSC/IMSIHolger Hans Peter Freyther1-0/+35
2013-10-30vty: Use vty_install_default() instead of bsc_install_default()Jacob Erlbeck1-4/+4
Remove ournode_exit_cmd, ournode_end_cmd, and bsc_install_default() since this functionality is provided by the current libosmocore. Replace calls to bsc_install_default() by call to vty_install_default() with the following semantic patch: @rule1@ expression N; @@ - bsc_install_default(N); + vty_install_default(N); Ticket: OW#952 Sponsored-by: On-Waves ehf
2013-09-19bsc/mminfo: Patch timezone and DST in MM Info messagesJacob Erlbeck1-2/+35
This adds in-place patching of the time information in the MM INFORMATION message. The timezone in the 'Local time zone' and the 'Universal time and local time zone' information elements and the offset in the 'Network Daylight Saving Time' information element are optionally set. The new values are determined by the 'timezone' vty command in the config_net_bts node. That command is extended by an optional DST offset parameter. Tests are provided for the vty part and for the plain bsc_scan_msc_msg() function. Sponsored-by: On-Waves ehf Ticket: OW#978
2013-09-18bsc: Add vty command for setting Access control classes.Ivan Kluchnikov1-0/+54
2013-09-16vty: Cosmetic change to the writing of the bts->modelHolger Hans Peter Freyther1-8/+16
Based on the feedback of Peter from the mailinglist, move the writing code to a new method and return early if there is no bts->model.
2013-09-11ctrl: Remember last 'rf_locked' control commandJacob Erlbeck1-0/+4
This stores the last SET rf_locked control command along with a timestamp. The 'show network' vty command is extended to show this information. Ticket: OW#659
2013-09-11vty: Hide unconfigured BTS on 'write'Jacob Erlbeck1-4/+6
This prevents the application from crashing when there is a half configured BTS (e.g. by using the command 'bts 1' when there isn't a BTS 1) and the 'write' command is used.
2013-09-02vty: Use generic 'end' and 'exit' commandsJacob Erlbeck1-12/+4
Add bsc_install_default() and replace all install_default() This patch adds bsc_install_default() which calls install_default() and add 'exit' and 'end'. All other calls to install_default() are replaced by calls to bsc_install_default(). Since 'exit' and 'end' are now added automatically to each node, the explicit registrations of these commands are removed by this patch, too. The related tests succeed now without work-arounds (except for the 'config' node itself which is part of libosmocore).
2013-07-27expiration: Allow to disable the periodic location updating procedureHolger Hans Peter Freyther1-2/+21
Disable the periodic LU using "no periodic location update" VTY command. In that case set the expire_lu to 0 which will then be translated to a NULL in the database layer. This leads to a bit of copy and paste in the db_sync_subscriber method but I don't see how we could easily use 'datetime(%i, 'unixepoch')' and 'NULL' at the same time. Change the query to find expired queries to check for NOT NULL and the time being in the past. This means if there are still old subscribers in the database they might not be expired. One would need to execute a query like "UPATE Subscriber SET expire_lu = 0 WHERE expire_lu is null". The same applies when disabling the periodic LU. One would need to update the database by hand. Manual tests executed/passed: 1.) periodic LU enabled: * use gst LUTest.st to do a LU * UPDATE Subscriber SET expire_lu=datetime('now'); * observe the subscriber being expired (it was) 2.) periodic LU disabled: * use gst LUTest.st to do a LU * verify that the expire_lu is NULL in the database
2013-07-14nitb: The subscr->imsi is an array will never be NULLHolger Hans Peter Freyther1-2/+1
Array compared against 0 (NO_EFFECT) array_null: Comparing an array to null is not useful: "subscr->imsi" Fixes: Coverity CID 1040716
2013-07-03hsl: Remove the support for the HSL bts from OpenBSCHolger Hans Peter Freyther1-48/+0
The support has been implemented for an old model, we were told that newer versions would be made incompatible with OpenBSC. Ther are various warnings in the code and coverity has found some new ones. Just remove the code as we don't know of anyone using this code.
2013-06-24bsc_vty: Print human-readable string version of NM ADM STATEHarald Welte1-2/+3
2013-05-29vty: Print the state of all GPRS OML objects in show btsHolger Hans Peter Freyther1-0/+8
For debugging GB-proxy/IPA issues it is nice to see the state of the OML objects.
2013-03-17Add VTY option to set GPRS network-control-order to enable MS measurementsAndreas Eversberg1-0/+23
In order to enable GPRS downlink measurements at mobile, the network-control-order must be set to nc1.
2013-03-12IPA: Allow RSL connection to different IP address as OMLHarald Welte1-0/+29
This patch adds a new VTY command "ip.access rsl-ip A.B.C.D" at the BTS level. If you set this IP address, the BTS will be instructed to establish the RSL link to the indiciated IP address, rather than using the same as for the OML link (default). Use "ip.access rsl-ip 0" to disable the feature.
2013-03-08bsc_vty: Prevent printing -1 as unsigned integer for timeslot TSCHarald Welte1-1/+2
2013-03-03bsc: Stop "show paging" from crashing before the first pagingHolger Hans Peter Freyther1-0/+3
The paging structure is still initialized lazily and we attempt to traverse it before it is ready. The crash was discovered by Katerina. Removing the lazy initialization will take a bit of work as the gsm_data_shared is used by the osmo-bts and the OpenBSC but paging is different.
2013-03-03vty: Document some previously undocumented parametersHolger Hans Peter Freyther1-2/+2
Katerina pointed out that some nodes are not fully documented and proposed some messages. The token/timeout messages were correct, I have modified the other messages. I removed the full-stop from the PING/PONG documentation as we are normally not using a full sentence.
2013-01-28bts: Allow to exclude a BTS from the global RF lock handlingHolger Hans Peter Freyther1-0/+27
Some BTS might be in locations where they can run all the time, allow to exclude them from the global lock handling.
2013-01-15osmo-bsc: Add VTY command show positionDaniel Willmann1-0/+7
2013-01-01Stricter limits for T3212 (location update period)Daniel Willmann1-4/+3
libcommon: Default to 30min location update period libbsc: Limit VTY value for periodic update and disallow the value 0 According to GSM 04.08 Table 10.5.33 "The value 0 is used for infinite timeout value i.e. periodic updating shall not be used within the cell." This was the default value until now, but the code that deals with expiring inactive subscribers in the next commit can't handle that case so this remains a TODO for now.
2013-01-01libbsc: Make argument optional in some 'show' commandsSylvain Munaut1-6/+6
The actual command implementation was already for this, but some bad vty parsing prevented optional range arguments from working properly. Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
2012-12-23lchan: Introduce T3109 handling for the release procedureHolger Hans Peter Freyther1-1/+1
T3109 is started when the SACCH is deactivated. It is stopped when the phones sends the DISC/UA/UM on LAPDm for the main signalling link. In case of timeout the abnormal release procedure will be initiated. Make sure to not issue the SACCH Deactivate twice to avoid confusing the equipment. This is still not fully spec compliant. In case of a timeout the abnormal release handling will be started which involves starting T3111+2. The error handling should be split out of the rf channel release method, e.g. lchan_release should be called and check if the channel release was already initiated.
2012-10-18Allow setting of Control Channel Description parameters via VTYAndreas Eversberg1-0/+59
2012-08-17VTY: improve VTY prompt and make sure exit/end works everywhereHarald Welte1-4/+4
Some nodes below 'config' didn't have ournode_exit / ournode_end, and thus were not able to properly perform this function. exit should always only go back one level, while end drops us back to ENABLE_NODE. The prompt now represents the nesting level, and there's one consistent space after the final prompt character (typically #).
2012-08-17VTY: dynamically create BTS "type" command syntaxHarald Welte1-1/+13
2012-08-17BSC VTY: use numeric ranges for bts/trx/timeslot numbersHarald Welte1-8/+8
This effectively limits the number of BTSs to 256, but I think that's acceptable for now. Unfortuantely there's no decent way to dynamically update the valid number range depending on how many BTSs are actually configured in the system :/
2012-08-17dynamically generate a proper VTY reference for phys_chan_configHarald Welte1-0/+34
this uses vty_cmd_string_from_valstr() from _very_ recent libosmocore, so you have to update the library, sorry.
2012-08-17... and more VTY help fixesHarald Welte1-4/+7
2012-08-17Some more VTY documentation / help fixesHarald Welte1-6/+12
2012-08-16complete the VTY help messages so we don't get "null" in the manualHarald Welte1-41/+159
2012-07-21libbsc: Add documentation to MM INFO, LAC, TSC, CIHolger Hans Peter Freyther1-4/+6
2012-07-12move BTS-specific timezone override into sub-structureHarald Welte1-6/+8
Group all three structure members involved in bts-specific timezone handling into a sub-structure.
2012-07-04BSC VTY: Allow encryption to be set to A5/3Harald Welte1-2/+3
We are currently not checking if the BTS actually suports that cipher, and we particularly don't have any hack for ip.access which apparently seems to re-use the RSL algorithm identifier for A5/2.