server-manager cli not working after SM install

Bug #1730103 reported by wenqing liang
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Juniper Openstack
Status tracked in Trunk
Trunk
Fix Committed
Critical
Nitish Krishna Kaveri

Bug Description

CB R5.0-98 newton (also seen in R5.0-21 ocata)

running post install^M
10.0.0.14^M
cp: missing destination file operand after '/etc/contrail_smgr/ntp.conf'^M
Try 'cp --help' for more information.^M
dpkg: error processing package contrail-server-manager (--configure):^M
 subprocess installed post-installation script returned error exit status 1^M
Processing triggers for libc-bin (2.23-0ubuntu7) ...^M
Processing triggers for systemd (229-4ubuntu17) ...^M
Processing triggers for ureadahead (0.100.0-19) ...^M
Processing triggers for ufw (0.35-0ubuntu2) ...^M
Errors were encountered while processing:^M
 contrail-server-manager^M
E: Sub-process /usr/bin/dpkg returned an error code (1)

root@servermanager:~# server-manager status server
server-manager: command not found
root@servermanager:~# service contrail-server-manager status
â contrail-server-manager.service - LSB: Example initscript
   Loaded: loaded (/etc/init.d/contrail-server-manager; bad; vendor preset: enabled)
   Active: active (running) since Sat 2017-11-04 19:32:07 UTC; 6min ago
     Docs: man:systemd-sysv-generator(8)
  Process: 25755 ExecStart=/etc/init.d/contrail-server-manager start (code=exited, status=0/SUCCESS)
    Tasks: 2
   Memory: 70.2M
      CPU: 1.985s
   CGroup: /system.slice/contrail-server-manager.service
           ââ26000 python /opt/contrail/server_manager/ansible/sm_ansible_server.py -c /opt/contrail/server_manager/sm-config.ini

Nov 04 19:32:03 servermanager systemd[1]: Starting LSB: Example initscript...
Nov 04 19:32:03 servermanager contrail-server-manager[25755]: * Starting Contrail Server Manager contrail-server-manager
Nov 04 19:32:03 servermanager contrail-server-manager[25755]: Restarting Apache2
Nov 04 19:32:05 servermanager contrail-server-manager[25755]: Restarting Cobbler
Nov 04 19:32:06 servermanager contrail-server-manager[25755]: Doing Cobbler Sync
Nov 04 19:32:06 servermanager contrail-server-manager[25755]: Restarting Xinetd
Nov 04 19:32:07 servermanager contrail-server-manager[25755]: Starting SMgr
Nov 04 19:32:07 servermanager contrail-server-manager[25755]: Starting SMgr Ansible
Nov 04 19:32:07 servermanager contrail-server-manager[25755]: ...done.
Nov 04 19:32:07 servermanager systemd[1]: Started LSB: Example initscript.
root@servermanager:~# dpkg -l | grep contrail-server-manager
iF contrail-server-manager 5.0.0-98 all Contrail Server Manager - Server Package
ii contrail-server-manager-installer 5.0.0-98~newton all Contrail Server Manager Installer Packages - Wrapper Package for Server Manager and Related Debian Packages
root@servermanager:~#
root@servermanager:~# tailf /var/log/contrail-server-manager/debug.log
"2017-11-04 19:32:07,978-DEBUG-server_mgr_validations.py:338-__init__(): ServerMgrValidations Init"
"2017-11-04 19:32:07,981-DEBUG-server_mgr_main.py:6991-_parse_args(): Arguments read form config file {'collectors': "['127.0.0.1:8086']", 'ipmi_type': 'ipmilan', 'html_root_dir': '/var/www/html/', 'ipmi_username': 'ADMIN', 'sandesh_log_level': 'SYS_ERR', 'cobbler': 'true', 'ipmi_interface': '', 'cobbler_ip_address': '__$IPADDRESS__', 'cobbler_port': '', 'monitoring': 'true', 'listen_port': '9001', 'listen_ip_addr': '__$IPADDRESS__', 'cobbler_username': 'testing', 'docker_insecure_registries': '__$IPADDRESS__:5100', 'ansible_srvr_ip': '__$IPADDRESS__', 'puppet_agent_retry_poll_interval_seconds': '20', 'http_introspect_port': '8107', 'cobbler_password': 'testing', 'ipmi_password': 'ADMIN', 'puppet_dir': '/etc/puppet/', 'puppet_agent_retry_count': '10', 'ansible_srvr_port': '9003', 'database_name': 'smgr_data.db', 'server_manager_base_dir': '/etc/contrail_smgr/'}"
"2017-11-04 19:32:07,981-DEBUG-server_mgr_main.py:6996-_parse_args(): Arguments read form config file {'collectors': "['127.0.0.1:8086']", 'ipmi_type': 'ipmilan', 'html_root_dir': '/var/www/html/', 'ipmi_username': 'ADMIN', 'sandesh_log_level': 'SYS_ERR', 'cobbler': 'true', 'ipmi_interface': '', 'cobbler_ip_address': '__$IPADDRESS__', 'cobbler_port': '', 'monitoring': 'true', 'listen_port': '9001', 'listen_ip_addr': '__$IPADDRESS__', 'cobbler_username': 'testing', 'docker_insecure_registries': '__$IPADDRESS__:5100', 'ansible_srvr_ip': '__$IPADDRESS__', 'puppet_agent_retry_poll_interval_seconds': '20', 'http_introspect_port': '8107', 'cobbler_password': 'testing', 'ipmi_password': 'ADMIN', 'puppet_dir': '/etc/puppet/', 'puppet_agent_retry_count': '10', 'ansible_srvr_port': '9003', 'database_name': 'smgr_data.db', 'server_manager_base_dir': '/etc/contrail_smgr/'}"
"2017-11-04 19:32:07,983-DEBUG-server_mgr_mon_base_plugin.py:140-parse_args(): Arguments read from monitoring config file {'monitoring_frequency': '300', 'monitoring_plugin': 'server_mgr_ipmi_monitoring.ServerMgrIPMIMonitoring'}"
"2017-11-04 19:32:07,984-DEBUG-server_mgr_mon_base_plugin.py:161-parse_monitoring_args(): Monitoring arguments read from config."
"2017-11-04 19:32:07,997-DEBUG-server_mgr_mon_base_plugin.py:149-parse_args(): Arguments read from inventory config file {'inventory_plugin': 'server_mgr_inventory.ServerMgrInventory'}"
"2017-11-04 19:32:07,997-DEBUG-server_mgr_mon_base_plugin.py:202-parse_inventory_args(): Inventory arguments read from config."
"2017-11-04 19:32:09,400-DEBUG-server_mgr_db.py:162-__init__(): Created tables"
"2017-11-04 19:32:09,449-DEBUG-server_mgr_cobbler.py:40-__init__(): ServerMgrCobbler Init"
"2017-11-04 19:32:09,467-ERROR-server_mgr_main.py:483-__init__(): Error connecting to cobbler: gaierror(-2, 'Name or service not known')"

Revision history for this message
OpenContrail Admin (ci-admin-f) wrote : [Review update] master

Review in progress for https://review.opencontrail.org/37219
Submitter: Nitish Krishna Kaveri (<email address hidden>)

Revision history for this message
OpenContrail Admin (ci-admin-f) wrote : A change has been merged

Reviewed: https://review.opencontrail.org/37219
Committed: http://github.com/Juniper/contrail-packaging/commit/3371525207fe094dde766cd1d46ddc68b2ecc86e
Submitter: Zuul (<email address hidden>)
Branch: master

commit 3371525207fe094dde766cd1d46ddc68b2ecc86e
Author: nitishkrishna <email address hidden>
Date: Mon Nov 6 10:18:53 2017 -0800

Closes-Bug: #1730103 - Wrongly set NTP.conf

Partial-Bug: #1704507 - Making preconfig ansible task

Typo in setting ntp.conf to be used in case of SM
The file is copied from sample in postinst

Change-Id: I9c7793eae844bd18372824b817e66e97a9a45de8

Revision history for this message
OpenContrail Admin (ci-admin-f) wrote : [Review update] master

Review in progress for https://review.opencontrail.org/37603
Submitter: kamlesh parmar (<email address hidden>)

Revision history for this message
OpenContrail Admin (ci-admin-f) wrote : A change has been merged

Reviewed: https://review.opencontrail.org/37603
Committed: http://github.com/Juniper/contrail-packaging/commit/ab35655f3d3fe0712ea99dbb4378dc9d49a68ab8
Submitter: Zuul (<email address hidden>)
Branch: master

commit ab35655f3d3fe0712ea99dbb4378dc9d49a68ab8
Author: Kamlesh Parmar <email address hidden>
Date: Thu Nov 16 15:01:37 2017 -0800

Closes-Bug: #1730103

correct the ntp copnfguration file name. SM is packaged with ntp.conf.sample
SO use that for copy.

Change-Id: I5d1d37f4167e3f56fc583b76f5f47eb04a797eea

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.