cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
461
Views
0
Helpful
0
Replies

5G NF SMF Configuration automation

nisheeth
Level 1
Level 1

Hi

I am trying to automate configuration update 5G Network Function SMF.

I am coding in java and using MAAPI class and created an api service to read the config file and update the same config using ncs_cli

In t

/ncs:devices/device{TEST_SMF1}/config
2023-11-02 19:01:19.388 INFO 65161 --- [nio-8989-exec-2] com.tailf.maapi.Maapi : MAAPI_LOAD_CONFIG_CMDS (tid:55072505,flags:[MAAPI_CONFIG_C, MAAPI_CONFIG_MERGE],cmds: profile dnn test_nso_utsmf21_3
mode offline
) -->
2023-11-02 19:01:19.448 ERROR 65161 --- [nio-8989-exec-2] c.t.t.services.Test_SMF_Service : com.tailf.conf.ConfException:
syntax error: unknown command
Error: on line 1: profile dnn test_nso_testsmf_1


com.tailf.conf.ConfException:
syntax error: unknown command
Error: on line 1: profile dnn test_nso_testsmf_1

he file I have defined the configuration as 

config
   profile dnn test_nso_testsmf_1
   mode offline
end

Manually I do this way

ncs_cli -C -u admin

ncs_cli -C -u admin

User admin last logged in 2023-11-03T02:00:13.493919+00:00, to nsfpol72, from 10.114.188.71 using cli-ssh
admin connected from 10.114.188.71 using ssh on nsfpol72
admin@ncs# config
Entering configuration mode terminal
Current configuration users:
admin@ncs(config)# devices device TEST_SMF1
admin@ncs(config-device-TEST_SMF1)# config
admin@ncs(config-config)# profile dnn TEST_SMF_0
admin@ncs(config-dnn-TEST_SMF_0)# mode offline
admin@ncs(config-dnn-TEST_SMF_0)# end
Uncommitted changes found, commit them? [yes/no/CANCEL] yes
Commit complete.
admin@ncs# show running-config devices device TEST_SMF1 config profile dnn TEST_SMF_0
devices device TEST_SMF1
config
profile dnn TEST_SMF_0
mode offline
!
!
!
admin@ncs#

Please let me know what is the syntax error issue for the command line

 

 

 

0 Replies 0