2
0
mirror of https://github.com/xcat2/xcat-core.git synced 2025-05-30 09:36:41 +00:00

4894 Commits

Author SHA1 Message Date
chenglch
d9d0cfd42c Avoid of circular reference in a loop of rinstall (#3121)
This is a temporary fix for getadapter which will hang forever if
error happens in `rinstall stage`. The root cause is the circular
reference in `runxcmd`. As global variable `$::xcmd_outref` and
`%::xcmd_outref_hash` are used to save the output message, if the
plugin command are called with runxcmd and the plugin called also
calls another plugin with `runxcmd`, the circular reference will happen.
In this situation, if the output reponse is used in a iterator,
like:
```
   foreach my $line (@$res) {
      xCAT::MsgUtils->message("I", $rsp, $callback);
```
`$res` points to the global variable, and `MsgUtils->message` in the
runxcmd calls also add the value in the global variable, as the
iter object is changed, the loop will not be terminated.

This patch can not solve the circular reference problem, it is just
a workaround to avoid infinite loop.

Some known issues: the error message will print twice as the
`MsgUtils->message` called in runxcmd. But we can not simply remove
it as the plugin may not be called with `runxcmd`.

Error message example:

```
Error: frame10node10: mgt configuration can not be found.
frame10node10: Unable to identify plugin for this command, check relevant tables: noderes.netboot
frame10node10: Unable to identify plugin for this command, check relevant tables: noderes.netboot
Failed to run 'nodeset' against the following nodes: frame10node10
Error: failed to run command: rinstall frame10node10 runcmd=getadapter
```
partial-fix: #3046
2017-06-07 22:21:26 -05:00
Yuan Bai
cccf4b783f fix 3224 nodeset create dracut.* file in sles statelite cost too much… (#3227)
* fix 3224 nodeset create dracut.* file in sles statelite cost too much time

* polished based on comments
2017-06-07 22:21:05 -05:00
XuWei
b0fece2907 modify format of error msg for 2200 port to hash according to other msg 2017-06-06 02:10:18 -04:00
Victor Hu
1d2bac4a2a Fix typo associated with pull request #3180 2017-06-05 13:44:15 -04:00
Mark Gurevich
d861f68995 Sync usage, man and code for ipmi rvitals 2017-06-05 10:56:59 -04:00
zet809
d9bb1ace82 Merge pull request #3122 from xuweibj/bmcdiscover
Close ssl verify for bmcdiscover on Ubuntu
2017-06-05 11:28:00 +08:00
Yuan Bai
7584b71742 Merge pull request #3180 from samveen/fix_2939
[WIP]Fix for #2939: Add `-d` option for `makeknownhosts` as alias for `-r`
2017-06-05 10:10:36 +08:00
Samveen Gulati
b8fdb3c890 #2939: Add -d option alias for makeknownhosts -r 2017-06-03 03:31:52 +00:00
Mark Gurevich
56d0bdbf82 Merge pull request #3179 from whowutwut/openpower_spelling
Sync up the spelling to use:  OpenPOWER and OpenBMC
2017-06-02 16:19:58 -04:00
Victor Hu
a3a96fbb8a Merge pull request #3178 from gurevichmark/openbmc_version_check
Support rflash command -c option for OpenBMC
2017-06-02 15:25:56 -04:00
Mark Gurevich
1f4cb4e64e Development code only warning 2017-06-02 15:18:46 -04:00
Victor Hu
bf382dcd10 Sync up the spelling to use: OpenPOWER and OpenBMC 2017-06-02 15:02:02 -04:00
Mark Gurevich
f7a39006dc Support rflash command -c option for OpenBMC 2017-06-02 12:42:16 -04:00
Yuan Bai
0dae47b9a5 fix issue 3142 delete useless dracut.* files under rootimg/tmp in liteimg (#3154)
* fix issue 3142 useless dracut.* files under rootimg/tmp cause liteimg cost much time

* polished

* polished
2017-06-01 22:25:35 -05:00
Bin Xu
fe6b771add Fix #3087: nodeset improvement - using multi-process to parallelize (#3118)
* Fix #3087: nodeset improvement - using multi-process to parallelize
 - before deliver the request to xcatd, we can split the request to multiple sub-requests which contains different noderange
 - in that, xcatd could hanle those sub-requests in parallel, just like some issue multiple commands.

* refine according to the review comments:
 - not using POSIX::ceil
 - Callback is reserved for filter method

* refine codes according review comments

* make the comments right and more readable.
2017-06-01 04:22:22 -05:00
yangsong
5c4dd31844 fix issue [fvt]2.13.4 nodeset osimage have no right output if command wrong #2971 (#3147)
* fix issue#2971:  one CLI arguments validation issue is not correct for nodeset/rinstall/winstall
2017-05-31 17:36:09 +08:00
Yuan Bai
358eefed2a Merge pull request #3140 from immarvin/onrhselinux
fix issue RHEL update caused boot failure due to selinux #2996
2017-05-31 14:54:18 +08:00
Mark Gurevich
50ec268c13 Merge pull request #3135 from whowutwut/expose_rvitals
Expose the rvitals command as part of openbmc support
2017-05-30 16:21:16 -04:00
Mark Gurevich
c5d40aa00b Merge pull request #3134 from whowutwut/rvitals_options
Add support for the rvitals option for openbmc based on the defined API
2017-05-30 14:45:53 -04:00
Victor Hu
b8894ed38b Following changes based on review comments
* Modified to display altitude instead of length
  * Print an output message if there is no values returned from the BMC
2017-05-30 14:32:07 -04:00
Victor Hu
5413376a58 Sort the output of rvitals to arrange the types of sensor data together.
Removing the node out of the label in order to allow the sort to happen
on just the keywords

For debug, just print the json instead of splitting to multiple lines
2017-05-26 14:01:50 -04:00
immarvin
89bc7608f1 fix issue RHEL update caused boot failure due to selinux #2996 2017-05-25 05:30:30 -04:00
cxhong
7ff64b220f Wrong mac address showing for switchdiscover command (#3131) 2017-05-25 00:14:16 -05:00
Victor Hu
2102c7d086 Expose the rvitals command as part of openbmc support 2017-05-24 23:02:24 -04:00
Victor Hu
74769080c8 Based on the OpenBMC Sensor API, complete the development code
for the supported options based on the possible values that are
currently allowed to be returned.  As more data is added, the code
should be able to handle the printing of the data automatically
2017-05-24 22:49:14 -04:00
Victor Hu
6e14f1ee08 Incorporated the Scale into the calculation of the value returned
from openbmc-rest, so the values make more sense to humans
2017-05-24 15:46:23 -04:00
Victor Hu
0588d4e060 Add the units to the output that is being returned from
the rvitals command to make the output more similar to
existing OpenPower BMC based servers
2017-05-24 15:31:31 -04:00
XuWei
79f4ae63fa Close ssl verify for bmcdiscover on Ubuntu 2017-05-24 04:29:30 -04:00
Weihua Hu
b1964bc735 Merge pull request #3111 from cxhong/pdu
Modify pdu error message and check pdu version for different OID
2017-05-24 10:12:58 +08:00
cxhong
dc5b14fa13 Merge pull request #3059 from mattaezell/switch_findme
Enable switches to run findme for autodiscovery (#2662)
2017-05-23 11:11:26 -04:00
XuWei
75cb09d112 modified depending on comments 2017-05-23 03:41:30 -04:00
XuWei
4515d197d9 Use LWP to send https request in bmcdiscover instead of curl command 2017-05-23 02:34:15 -04:00
xuweibj
553a1891d4 Merge pull request #3112 from whowutwut/openbmc_expose
[openbmc] Open rpower and rinv commands for normal xCAT use
2017-05-23 13:26:08 +08:00
cxhong
bd60341cb6 Support ZTP process for Cumulus Switch (#3085)
* Support ZTP process for Cumulus Switch

* change name of onieztp to cumulusztp and add server ip
2017-05-22 21:45:18 -05:00
Victor Hu
e2f2d67ba8 Check the failed nodes array before printing out the (#3110)
error messages
2017-05-22 21:41:14 -05:00
Victor Hu
7f22c23bf0 Open rpower and rinv commands 2017-05-22 15:47:58 -04:00
Casandra Qiu
ea2d22887b Modify pdu error message and check pdu version for different OID 2017-05-22 15:27:11 -04:00
Mark Gurevich
327f570f7c Changes due to review 2017-05-19 16:22:21 -04:00
Mark Gurevich
4fd1aeae80 Handle openbmc transition states 2017-05-19 13:05:18 -04:00
Mark Gurevich
7dddec27e9 Merge pull request #3092 from xuweibj/rinvfirm
Modify process of rinv firm/all depending on new url
2017-05-19 07:28:52 -04:00
cxhong
ba2f34ad3d Merge pull request #3022 from jjohnson42/fixpdu
Support newer PDU firmware
2017-05-18 14:46:14 -04:00
Yuan Bai
80e5e96542 fix mtu support (#3083) 2017-05-18 01:00:50 -05:00
XuWei
7057ab5208 Modify process of rinv firm/all depending on new url 2017-05-18 01:48:11 -04:00
Victor Hu
ff4fd41e6e Merge pull request #3076 from gurevichmark/rinv_format
OpenBMC rinv sorted output
2017-05-17 22:20:37 -04:00
Mark Gurevich
e664018cc4 Changes after review comments 2017-05-17 11:27:37 -04:00
cxhong
68736a6440 Merge pull request #3037 from xuweibj/I3036
Get username and password from passwd table for openbmc discover
2017-05-17 08:55:27 -04:00
Mark Gurevich
2e017e2c10 OpenBMC rinv sorted output 2017-05-16 15:56:49 -04:00
XuWei
e2b25f57a3 Modify output for rpower state when return Quiesced 2017-05-16 04:42:06 -04:00
Matt Ezell
cc198bef12 Enable switches to run findme for autodiscovery (#2662) 2017-05-15 15:26:58 -04:00
Mark Gurevich
83e0e51944 Merge pull request #3045 from zet809/fix_issue_2577
Fix issue 2577: chdef -m should return correct warning message when s…
2017-05-15 10:16:45 -04:00