1 module o-ran-software-management {
3 namespace "urn:o-ran:software-management:1.0";
6 import ietf-inet-types {
8 revision-date 2013-07-15;
11 import ietf-hardware {
15 import o-ran-hardware {
19 import o-ran-file-management {
23 organization "O-RAN Alliance";
29 "This module defines operations and configuration for the management of software packages.
30 This module is derived out of opencpe-firmware-mgmt@2014-02-06.yang
32 Copyright 2019 the O-RAN Alliance.
34 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 'AS IS'
35 AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
36 IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
37 ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE
38 LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
39 CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
40 SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
41 INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
42 CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
43 ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
44 POSSIBILITY OF SUCH DAMAGE.
46 Redistribution and use in source and binary forms, with or without
47 modification, are permitted provided that the following conditions are met:
49 * Redistributions of source code must retain the above copyright notice,
50 this list of conditions and the above disclaimer.
51 * Redistributions in binary form must reproduce the above copyright notice,
52 this list of conditions and the above disclaimer in the documentation
53 and/or other materials provided with the distribution.
54 * Neither the Members of the O-RAN Alliance nor the names of its
55 contributors may be used to endorse or promote products derived from
56 this software without specific prior written permission.";
58 revision "2019-07-03" {
62 1) backward compatible changes to correct sFTP Server Authentication .
63 2) simplifying file management and authentication to reuse from o-ran-file-management module
64 3) minor fixes according to lack of descriptions
65 4) removal of not used grouping
66 5) backward compatible changes to introduce groupings.";
68 reference "ORAN-WG4.M.0-v01.00";
71 revision "2019-02-04" {
75 1) imported model from xRAN
76 2) changed namespace and reference from xran to o-ran";
78 reference "ORAN-WG4.M.0-v01.00";
85 "Contains information about each software slot and its content.";
91 "Information about available software-slots and their software.";
97 "Name of the software package. This shall be unique to identify the software-slot.";
104 "Slot Contains software build considered as proven valid";
108 "software build is not currently used by O-RU. The software is considered by O-RU as damaged (e.g. wrong CRC)";
112 "W slot does not contain software package.";
118 description "Indicates the status of the software slot";
123 must "../status = 'VALID'";
126 "informs if software stored in particular slot is activated at the moment";
131 must "../status = 'VALID'";
134 "informs if software stored in particular slot is used at the moment";
141 "slot intended only for factory software,
142 activation of such software slot means getting back to factory defaults";
146 "slot used for updating software";
153 "Indicates the writability of the slot.
154 A Read-Only software slot is one which has a factory installed software-slot";
159 path "/hw:hardware/hw:component/o-ran-hw:product-code";
163 description "product code provided by the vendor, specific to the product. This is derived from manifest file.";
173 "Unique code of the vendor. This is derived from manifest file.";
181 "Identity associated with the software build. This is derived from manifest file.";
189 "Name of the build. This is derived from manifest file.";
194 description "The vendor-specific version string of the software build.";
201 description "List of all the files present in the software package.";
207 "Name of the file installed in the slot.";
214 "Version of the file installed in the slot";
221 "Complete path of the file stored locally";
227 description "OK - indicates that file integrity is correct";
230 description "NOK - indicates corrupted file";
236 "Result of the file integrity check (checksum calculation) during installation.";
242 grouping download-input {
244 "Grouping for sw download rpc input";
245 leaf remote-file-path {
249 "URI of the software image including username.
250 The following format is possible:
251 sftp://<username>@<host>[:<port>]/path";
254 uses o-ran-fm:credential-information;
257 grouping download-output {
259 "Grouping for sw download rpc output";
264 "Operation has been started without error.";
268 "Operation cannot be started because of error, more detailed information can be found in error-message.";
274 "Status of the software files download";
277 when "../status = 'FAILED'";
281 "Detailed error Message when the status is failed.";
284 leaf notification-timeout {
290 "Notification timeout is the time NETCONF client shall
291 wait for a 'download-event' notification from O-RU. If there is no
292 'download-event' notification received within notification-timeout,
293 NETCONF client shall assume the download timeout/failure, and follow necessary steps.";
297 grouping install-input {
299 "Grouping for sw installation rpc input";
302 path "/software-inventory/software-slot/name";
304 must "/software-inventory/software-slot[name = current()][active = 'false' and running = 'false']" {
305 error-message "software-install may be requested only against active::false and running::false slot!";
310 "software-slot to which the software shall be installed to.";
313 leaf-list file-names {
317 "Names of the files within software package to be installed";
321 grouping install-output {
323 "Grouping for sw installation rpc output";
328 "Operation has been started without error.";
332 "Operation cannot be started because of error, more detailed information can be found in error-message.";
338 "Status of the software package install.";
341 when "../status = 'FAILED'";
345 "Detailed error Message when the status is failed.";
349 grouping activate-input {
351 "Grouping for sw activation rpc input";
354 path "/software-inventory/software-slot/name";
356 must "/software-inventory/software-slot[name = current()][status = 'VALID']" {
357 error-message "software activation may be requested only on VALID slot!";
362 "Slot name on which software has to be activated.";
366 grouping activate-output {
368 "Grouping for sw activation rpc output";
373 "Operation has been started without error.";
377 "Operation cannot be started because of error, more detailed information can be found in error-message.";
383 "Status of the software files activation";
386 when "../status = 'FAILED'";
390 "Detailed error Message when the status is failed.";
393 leaf notification-timeout {
399 "Timeout on client waiting for the activate event";
403 grouping download-notification {
405 "Grouping for notification event structure for download completion";
411 "File name of downloaded software package";
418 "Operation completed succesfully";
420 enum AUTHENTICATION_ERROR {
421 description "source available, wrong credentials";
423 enum PROTOCOL_ERROR {
424 description "SFTP errors";
426 enum FILE_NOT_FOUND {
427 description "source not available.";
429 enum APPLICATION_ERROR {
430 description "Application related errors";
433 description "Timeout waiting for download";
438 "Status of finished operation execution";
441 when "../status != 'COMPLETED'";
445 "Detailed description of faulty situation";
449 grouping install-notification {
451 "Grouping for notification event structure for installation completion";
454 path "/software-inventory/software-slot/name";
458 "Name of the slot to which software was installed.";
464 "Operation completed succesfully";
467 description "operation on the file resulted in in error, disk failure, not enough disk space,
468 incompatible file format";
470 enum INTEGRITY_ERROR {
471 description "file is corrupted";
473 enum APPLICATION_ERROR {
474 description "operation failed due to internal reason";
479 "Status of finished operation execution";
482 when "../status != 'COMPLETED'";
486 "Detailed description of faulty situation";
490 grouping activation-notification {
492 "Grouping for notification event structure for activation completion";
495 path "/software-inventory/software-slot/name";
499 "Name of the slot which was activated";
506 "Operation completed succesfully";
508 enum APPLICATION_ERROR {
510 "Operation finished with error, more details can by found in error-message";
515 "Status of finished operation execution";
521 "status code return when the software is tried to activate";
524 when "../status != 'COMPLETED'";
528 "Detailed description of faulty situation";
532 // top level container
534 container software-inventory {
537 "Contains information about each software slot and its content.";
544 rpc software-download {
546 "Rpc needed to perform software download operation.";
552 uses download-output;
556 rpc software-install {
558 "Install a previously downloaded software package.";
568 rpc software-activate {
570 "Activate a previously installed software.";
575 uses activate-output;
579 // notification definitions
580 notification download-event {
581 description "Notification event structure for download completion";
582 uses download-notification;
586 notification install-event {
587 description "Notification event structure for installation completion";
588 uses install-notification;
591 notification activation-event {
592 description "Notification event structure for activation completion";
593 uses activation-notification;