2
0
mirror of https://github.com/xcat2/xcat-core.git synced 2025-05-22 03:32:04 +00:00

12 Commits

Author SHA1 Message Date
GONG Jie
e627f68503 Remove trailing spaces in file xCAT-server/lib/xcat/plugins/goconserver.pm 2017-12-31 23:59:59 +00:00
chenglch
2ac315cbe2 Add default logrotate configuration for gocons
Add logrotate conf for the console log files and log
of goconserver.
2018-03-27 17:11:25 +08:00
chenglch
cc588f4af1 Modify startup configuration for goconserver and conserver
After running makegocons, startup configuration would be changed
to make sure goconserver could start after rebooting. Changes
are made in makeconservercf too.
2018-03-23 16:36:42 +08:00
chenglch
25bede4130 Modify goconserver msg for SN
The message util from xCAT framework do not print where the message
comes from by default. This patch add [service host] prefix for the
message if message is from SN.
2018-03-20 15:32:50 +08:00
chenglch
e86d544242 Add makegocons -C|--cleanup to remove entries that do not exist
`rmdef` command do not help clean up the recousrces that related to
the node when removing the node. this is a technical debt. This patch
is only a work around to add -C|--cleanup option to help remove the
entries in goconserver.
2018-03-01 16:13:12 +08:00
chenglch
dd7e1d51df Add consoleenabled column to help store the console status
On diskless SN, the nodes file of goconserver is missing when
reinstalling. This patch add a column in nodehm table to help
recover the console information on service node.

```
[root@c910f03c09k04 ~]# makegocons -q

NODE                             SERVER                           STATE
c910f03c09k05                    c910f03c09k04.pok.stglabs.ibm.com error
node-7912ac1-06vag36             c910f03c09k04.pok.stglabs.ibm.com error

NODE                             SERVER                           STATE
c910f03c09k04                    c910f03c09k03.pok.stglabs.ibm.com connected
[root@c910f03c09k04 ~]# rm /var/lib/goconserver/*
rm: remove regular file ‘/var/lib/goconserver/nodes.json’? y
rm: remove regular file ‘/var/lib/goconserver/nodes.json.bak’? y
[root@c910f03c09k04 ~]# service xcatd restart
Restarting xcatd (via systemctl):                          [  OK  ]
[root@c910f03c09k04 ~]# makegocons -q

NODE                             SERVER                           STATE
c910f03c09k05                    c910f03c09k04.pok.stglabs.ibm.com error
node-7912ac1-06vag36             c910f03c09k04.pok.stglabs.ibm.com error

NODE                             SERVER                           STATE
c910f03c09k04                    c910f03c09k03.pok.stglabs.ibm.com connected
```
2018-02-09 10:34:20 +08:00
chenglch
28a84fa997 List console status with makegocons -q
Add `-q|--query [noderange]` for makegocons to list the console
status and the host server. If node is not registered in
goconserver, the status will be `unregistered`.

If console releated attribute is not defined for the specified
node but it is included in the noderange, error message for that
node will be printed at first.
2018-02-07 10:32:43 +08:00
chenglch
f09939a15a Add xcat marker in gocnoserver configuration file
Previously, it is impossible to know if the goconerver is started
by xcat. This patch add a marker in /etc/goconserver/server.conf
to help check the status. In addition, use server-cred.pem instead
of server-key.pem as it is not exist on SN.

This patch also control the service status of goconserver and conserver
when restarting the xcatd service on service node.

```
[root@sn02 ~]# chdef sn02 setupconserver=1
1 object definitions have been created or modified.
[root@sn02 ~]# service xcatd restart
Restarting xcatd (via systemctl):                          [  OK  ]
[root@sn02 ~]# ps -ef | grep conserver
root      27679      1  0 02:26 ?        00:00:00 /usr/sbin/conserver -o -O1 -d
root      27680  27679  0 02:26 ?        00:00:00 /usr/sbin/conserver -o -O1 -d
root      27756  26188  0 02:26 pts/1    00:00:00 grep --color=auto conserver
[root@sn02 ~]# chdef sn02 setupconserver=2
1 object definitions have been created or modified.
[root@sn02 ~]# service xcatd restart
Restarting xcatd (via systemctl):                          [  OK  ]
[root@sn02 ~]#
[root@sn02 ~]#
[root@sn02 ~]#
[root@sn02 ~]# ps -ef | grep conserver
root      27885      1  0 02:26 ?        00:00:00 /usr/bin/goconserver
root      27986  26188  0 02:33 pts/1    00:00:00 grep --color=auto conserver
```
2017-12-28 16:46:47 +08:00
chenglch
77b1757352 Modify the default consoleondemand based on the global setting
This commit fix the bug that consoleondemand works incorrectly.
2017-12-08 12:02:05 +08:00
chenglch
cadf5c60e1 Listen on 0.0.0.0 instead of the hostname
This patch modify the configuration of `makegocons` and `rcons`
for goconserver.

`cat /etc/goconserver/server.conf`
```
global:
  host: 0.0.0.0
  ssl_key_file: /etc/xcat/cert/server-key.pem
  ssl_cert_file: /etc/xcat/cert/server-cert.pem
  ssl_ca_cert_file: /etc/xcat/cert/ca.pem
  logfile: /var/log/goconserver/server.log
api:
  port: 12429
console:
  port: 12430
```
2017-11-29 17:18:39 +08:00
chenglch
071f336c17 Fix some bus in makegocons 2017-11-17 17:17:24 +08:00
chenglch
abab9d89c5 Add makegocons command
This patch enable goconserver service and manage the node sessions
with a new `makegocons` command.

Implement: #4215
2017-11-16 17:56:26 +08:00