我在ha-node1中使用nova service-list
,这里有一些服务,你可以看到ha-node3,都是关闭的:
[root@ha-node1 ~]# nova service-list
+----+------------------+----------+----------+---------+-------+----------------------------+-----------------+
| Id | Binary | Host | Zone | Status | State | Updated_at | Disabled Reason |
+----+------------------+----------+----------+---------+-------+----------------------------+-----------------+
| 2 | nova-consoleauth | ha-node3 | internal | enabled | down | 2017-07-27T07:17:34.000000 | - |
| 5 | nova-conductor | ha-node3 | internal | enabled | down | 2017-07-27T07:17:33.000000 | - |
| 7 | nova-cert | ha-node3 | internal | enabled | down | 2017-07-27T07:17:34.000000 | - |
| 15 | nova-scheduler | ha-node3 | internal | enabled | down | 2017-07-27T07:17:33.000000 | - |
| 22 | nova-cert | ha-node1 | internal | enabled | up | 2017-07-27T07:28:30.000000 | - |
| 29 | nova-conductor | ha-node1 | internal | enabled | up | 2017-07-27T07:28:31.000000 | - |
| 32 | nova-consoleauth | ha-node1 | internal | enabled | up | 2017-07-27T07:28:23.000000 | - |
| 33 | nova-consoleauth | ha-node2 | internal | enabled | up | 2017-07-27T07:28:33.000000 | - |
| 36 | nova-scheduler | ha-node1 | internal | enabled | up | 2017-07-27T07:28:30.000000 | - |
| 40 | nova-conductor | ha-node2 | internal | enabled | up | 2017-07-27T07:28:32.000000 | - |
| 44 | nova-cert | ha-node2 | internal | enabled | up | 2017-07-27T07:28:39.000000 | - |
| 46 | nova-scheduler | ha-node2 | internal | enabled | up | 2017-07-27T07:28:33.000000 | - |
+----+------------------+----------+----------+---------+-------+----------------------------+-----------------+
但是在ha-node3中,4个服务都处于活动状态(正在运行):
openstack-nova-consoleauth.service - OpenStack Nova VNC console auth Server
Loaded: loaded (/usr/lib/systemd/system/openstack-nova-consoleauth.service; enabled; vendor preset: disabled)
Active: active (running) since Thu 2017-07-27 10:37:26 CST; 23s ago
Main PID: 42710 (nova-consoleaut)
CGroup: /system.slice/openstack-nova-consoleauth.service
└─42710 /usr/bin/python2 /usr/bin/nova-consoleauth
Jul 27 10:37:20 ha-node3 systemd[1]: Starting OpenStack Nova VNC console auth Server...
Jul 27 10:37:26 ha-node3 nova-consoleauth[42710]: Option "verbose" from group "DEFAULT" is deprecated for removal. Its value may be silently ignored in the future.
Jul 27 10:37:26 ha-node3 nova-consoleauth[42710]: Option "rpc_backend" from group "DEFAULT" is deprecated for removal. Its value may be silently ignored in the future.
Jul 27 10:37:26 ha-node3 systemd[1]: Started OpenStack Nova VNC console auth Server.
● openstack-nova-scheduler.service - OpenStack Nova Scheduler Server
Loaded: loaded (/usr/lib/systemd/system/openstack-nova-scheduler.service; enabled; vendor preset: disabled)
Active: active (running) since Thu 2017-07-27 10:37:28 CST; 21s ago
Main PID: 42711 (nova-scheduler)
CGroup: /system.slice/openstack-nova-scheduler.service
└─42711 /usr/bin/python2 /usr/bin/nova-scheduler
Jul 27 10:37:20 ha-node3 systemd[1]: Starting OpenStack Nova Scheduler Server...
Jul 27 10:37:26 ha-node3 nova-scheduler[42711]: Option "verbose" from group "DEFAULT" is deprecated for removal. Its value may be silently ignored in the future.
Jul 27 10:37:26 ha-node3 nova-scheduler[42711]: Option "rpc_backend" from group "DEFAULT" is deprecated for removal. Its value may be silently ignored in the future.
Jul 27 10:37:28 ha-node3 systemd[1]: Started OpenStack Nova Scheduler Server.
● openstack-nova-conductor.service - OpenStack Nova Conductor Server
Loaded: loaded (/usr/lib/systemd/system/openstack-nova-conductor.service; enabled; vendor preset: disabled)
Active: active (running) since Thu 2017-07-27 10:37:27 CST; 23s ago
Main PID: 42712 (nova-conductor)
CGroup: /system.slice/openstack-nova-conductor.service
├─42712 /usr/bin/python2 /usr/bin/nova-conductor
├─42762 /usr/bin/python2 /usr/bin/nova-conductor
├─42763 /usr/bin/python2 /usr/bin/nova-conductor
├─42765 /usr/bin/python2 /usr/bin/nova-conductor
└─42776 /usr/bin/python2 /usr/bin/nova-conductor
Jul 27 10:37:20 ha-node3 systemd[1]: Starting OpenStack Nova Conductor Server...
Jul 27 10:37:26 ha-node3 nova-conductor[42712]: Option "verbose" from group "DEFAULT" is deprecated for removal. Its value may be silently ignored in the future.
Jul 27 10:37:26 ha-node3 nova-conductor[42712]: Option "rpc_backend" from group "DEFAULT" is deprecated for removal. Its value may be silently ignored in the future.
Jul 27 10:37:27 ha-node3 systemd[1]: Started OpenStack Nova Conductor Server.
● openstack-nova-novncproxy.service - OpenStack Nova NoVNC Proxy Server
Loaded: loaded (/usr/lib/systemd/system/openstack-nova-novncproxy.service; enabled; vendor preset: disabled)
Active: active (running) since Thu 2017-07-27 10:37:20 CST; 29s ago
Main PID: 42713 (nova-novncproxy)
CGroup: /system.slice/openstack-nova-novncproxy.service
└─42713 /usr/bin/python2 /usr/bin/nova-novncproxy --web /usr/share/novnc/
为什么他们陷入nova service-list
?
答案 0 :(得分:1)
最后,我发现ha-node3的日期是10分钟后ha-node1和ha-node2:
在ha-node3:
public List<ScoreCount> scoreCount(String courseId, String assignmentId){
Aggregation agg = newAggregation(
match(Criteria.where("_id.courseId").is(courseId).and("_id.assignmentId").is(assignmentId)),
bucket("overRollScore").withBoundaries(0, 20, 50, 70, 100).andOutput("score").push().as("gradeCount"));
AggregationResults<ScoreCount> averageScore = mongoTemplate.aggregate(agg, Submission.class, ScoreCount.class);
return averageScore.getMappedResults();
}
在ha-node2或ha-node1:
中[root@ha-node3 images]# date
Thu Jul 27 15:22:57 CST 2017
[root@ha-node3 images]# date
Thu Jul 27 15:23:16 CST 2017
所以我在ha-node3中使用[root@ha-node2 ~]# date
Thu Jul 27 15:34:03 CST 2017
,然后它正常工作:
ntpdate cn.pool.ntp.org