Commit Graph

58 Commits

Author SHA1 Message Date
Zuul ff76c8dd6a Merge "Add video enumeration to InventoryManagement" 2020-09-25 13:07:17 +00:00
Mudit d341ab4b3c Add video enumeration to InventoryManagement
Change-Id: Ia14ae67fea9d69ba27ebd43f6043b817f6cc5eff
Closes-Bug: #1894940
2020-09-25 07:54:27 -04:00
Christopher Dearborn 1aaaf93f7c Fix issue with reset_idrac on some servers
This patch increases the amount of time to sleep before checking to see
if the iDRAC is ready following a reset to 60 seconds. 30 seconds was
too short for some servers.

Change-Id: I9252a2d56b852f72efcf571bf7d8e70cbb7cd874
2020-08-03 09:34:22 -04:00
Christopher Dearborn fef6ffa789 Remove deprecated change phys disk state results
Remove the deprecated is_reboot_required and commit_required_ids keys
from the results returned by the change_physical_disk_state method.

Change-Id: I0899597d2aa82d8075ce1c6be33968d992b17c84
2020-04-28 09:56:41 -04:00
mpardhi23 c3bb9606aa Add the ability to manage RAID settings
This patch adds the ability to get and set the settings for RAID
settings.

Change-Id: Ifc63ca7d9a30378e75b160739b709a1264ffe550
2020-04-02 15:21:05 -04:00
mpardhi23 ceef78a938 Take Lifecycle Controller out of recovery mode
This patch is to check if a node is in recovery mode and take it
out of recovery mode by setting LifecycleControllerState attribute
value to 'Enabled'.

Modified list_lifecycle_settings() method to use
utils.list_settings() for retrieving lifecycle settings.

Change-Id: I4287f317b2413b70cd00fd4cf8aa69bff6ae5e2f
2019-06-17 04:52:24 -04:00
mpardhi23 bcce3bdc6b Check LCStatus instead of MessageID to determine if an iDRAC is ready
We are currently checking the MessageID to determine if an iDRAC
is ready. This patch is to check the value of LCStatus instead of
MessageID. If the value of LCStatus is "0", then the iDRAC is
considered ready.

Change-Id: I3426c226c4bb3cdcc95b98e9b203f100bb6777d5
2019-05-14 16:43:30 +00:00
Zuul a34705b1bb Merge "Add realtime support to drive conversion" 2019-05-10 17:40:28 +00:00
Christopher Dearborn ff312640d8 Add realtime support to drive conversion
This patch updates change_physical_disk_state() so that it returns the
actual results of drive conversion on each controller.  This allows the
caller to use the returned information for realtime drive conversion.

This patch also deprecates returning the is_reboot_required and
commit_required_ids keys in the dictionary.

Change-Id: I10f4a44660e70f0cd8efd0ca9e8e96cb46751a61
2019-05-09 14:38:12 -04:00
Christopher Dearborn caff41164f Consider a BOSS card a RAID controller
This fixes the is_raid_controller method so that it returns true
for a BOSS controller in addition to normal RAID controllers.

Change-Id: Iedd3179b8b2b6e3815709cc1acfd6a3059e42399
2019-04-23 09:42:58 -04:00
mpardhi23 6857a6d000 Implement ResetConfig and ClearForeignConfig functionality
For raid deletion, existing delete_virtual_disk functionality is not
freeing up foreign drives and spares, so have added ResetConfig and
ClearForeignConfig functionality for freeing up foreign drives and
spares.

Change-Id: I76390dc4fcf8de2fe5aa3d660f77edcef4a4dec1
2019-04-16 04:38:19 +00:00
Christopher Dearborn e204c367ab Fix iDRAC reset
The current code waits for 3 consecutive failed pings, each 10 seconds
apart to determine that an iDRAC has gone down during an iDRAC reset.
This is too long for some servers, as the iDRAC may come back up before
the 3rd ping failure.  This results in a failure to detect the iDRAC
going down, which causes a timeout on the reset.

This patch changes the code to wait for only 2 consecutive ping
failures, which is what our highly tested downstream code does.

Closes-Bug: 1816195
Change-Id: Iac21d5eb722834089cbe4a2e7e19370a951951f0
2019-02-15 17:14:29 -05:00
Zuul 45569a427f Merge "Add a real-time option when commit RAID creation/deletion in python-dracclient." 2019-01-31 17:05:07 +00:00
digambar 9069b1e416 Add a real-time option when commit RAID creation/deletion
in python-dracclient.

Change-Id: I3ada0e51235941620c9f27796da9790a182fb0e4
2019-01-31 10:32:00 +00:00
Zuul 82480155bf Merge "Fixes problem in is_boss_controller function" 2019-01-24 12:31:03 +00:00
David Paterson 5ec4f3dc1f Fixes problem in is_boss_controller function
We need to make sure we check model name of controller
starts with "BOSS"

Change-Id: I0b8608bad4ffc1f6c5bcf5ae36d9c0c76478260b
2019-01-21 17:20:01 -06:00
Rachit7194 e177d47521 Remove deprecated commit_required parameter from python-dracclient
Change-Id: Ic37afe82d6b98433ee60142ed3ee429c48de727d
2019-01-08 05:12:02 -05:00
David Paterson bef7a0a8ce Add change_physical_disk_state function to client
Build a list of controllers which had disks converted
to or from RAID/JBOD and inidicate if a reboot is required.

The following steps allow the caller to retrieve a list of
controllers that have disks comverted to the specified
RAID status:
- Examine all disks in the system and filter out any that
are not attached to a RAID/BOSS controller.
- Inspect the controllers' disks to see if there are
disks that need to be converted. If a disk is already in
the desired status the disk is ignored, otherwise
it is converted. This function also handles failed or
unknown disk status appropriately and will raise exception(s)
where needed.
- Finally a dict is returned containing a list of controller
IDs for controllers whom had any of their disks converted,
and whether a reboot is required.

Typically the caller would then create a config job for the
list of controllers returned to finalize the RAID
configuration and reboot the node if necessary.

Change-Id: I5229f7699c9ca1d5b72a54b4ddcea6313b440836
Co-Authored-By: Christopher Dearborn <Christopher.Dearborn@dell.com>
2018-10-19 18:43:44 -04:00
Zuul f823194b2e Merge "Adds ability to reset iDRAC" 2018-10-05 16:26:55 +00:00
Mark Beierl 88023841ef Adds ability to reset iDRAC
Adds new function to reset the iDRAC and wait for it
to become operational again.

Change-Id: Ia8dc0b97e02fc5f2c4d39b6b6d90456c1cfc5b7a
Co-Authored-By: Christopher Dearborn <christopher.dearborn@dell.com>
2018-09-27 20:03:05 -04:00
Mark Beierl 6599e7f814 Define constants for types of reboot job
Adds constants, instead of arbitrary strings, for specifying the type
of reboot job.

Change-Id: I4f404bdb158899b4d0f50f87a120a222f4bd5939
2018-08-23 15:34:57 -04:00
Zuul 01858e0d41 Merge "Add support for NIC configuration" 2018-08-11 12:57:23 +00:00
Zuul 589ee04c83 Merge "Added is_jbod_capable method to raid resource" 2018-08-11 12:50:53 +00:00
Zuul ee12ec65e7 Merge "Delete Job API" 2018-08-11 12:50:53 +00:00
digambar 0960fba23a Add ability to retrieve system properties
Change-Id: I7ae6efb913895c86aab838481b6025c8a17a42ee
2018-08-10 05:34:28 -05:00
Mark Beierl 96fa6965db Delete Job API
Adds the ability to delete jobs from the iDRAC job queue.

Change-Id: I0e34cc850b968533782af45ef6e61206a3f04949
Co-Authored-By: Richard G. Pioso <richard.pioso@dell.com>
2018-08-08 09:21:28 -04:00
Mark Beierl 8836c0dedf Add support for NIC configuration
Adds APIs that support listing and setting NIC attributes
by name.

Change-Id: Ie836a3603b6bb49e3f296c10147d58ae745c3f6b
Co-Authored-By: Richard G. Pioso <richard.pioso@dell.com>
2018-07-27 15:48:07 -04:00
Mark Beierl dcf4e2d280 Add ability to schedule jobs
Adds an optional start time to allow configuration changes
to be scheduled for a future time.

Co-Authored-By: Christopher Dearborn <christopher.dearborn@dell.com>
Co-Authored-By: Richard G. Pioso <richard.pioso@dell.com>
Change-Id: Ia1f02fd2f8a25efa8bb924bd9d50394cbf5d2034
2018-07-06 15:27:46 -04:00
David Paterson 1d203354a2 Added is_jbod_capable method to raid resource
Some RAID controllers support JBOD (passthrough) mode, while others do not.
This method determines if the passed RAID controller supports JBOD mode.
Note: that the controller must have at least one disk in the non-RAID or ready
state, or this method will be unable to determine if the RAID controller
supports JBOD mode, and an exception will be thrown.

Co-Authored-By: Christopher Dearborn <Christopher.Dearborn@dell.com>
Change-Id: I62d8f92197faf6a6b4fe8a72da5c1a6a79d2af82
2018-06-29 11:20:09 -04:00
Zuul 7626bcc857 Merge "Add ability to set iDRAC card settings" 2018-02-19 12:03:36 +00:00
Zuul 0c168ee6ec Merge "Separate reboot required from commit required" 2018-02-19 11:58:45 +00:00
Christopher Dearborn b327b0811f Add ability to set iDRAC card settings
This patch adds the ability to set iDRAC card settings.

Change-Id: I117e5ed0af1469dc316a30abcfa384d3c773ed1f
2018-02-08 10:13:35 -05:00
Christopher Dearborn 72ea2323e5 Separate reboot required from commit required
This patch separates indicators for reboot required and commit required.
It does this by adding two new keys (is_reboot_required and
is_commit_required) to the dictionary returned by set/create/modify
operations while continuing to return the commit_required key for
backwards compatibility.

The commit_required key should be considered deprecated at this time and
it will be removed in a future patch.

The is_reboot_required key has an enumerated value that can have three
possible values: true, optional, and false.  This allows the return of
optional for RAID operations that can return this value.

Change-Id: I70e52868f10bfafb30bbb38b85888bc4ec8e65ae
Closes-Bug: 1732549
2018-01-22 09:36:53 -05:00
Christopher Dearborn aca79f0e8c Allow invoke without checking the return value
Some versions of firmware for at least 13G hardware can return a
failure return value and a message indicating success on certain
invoke calls.  This patch modifies invoke so that it can be used to
execute the invoke command and return the result without raising an
exception if the return value indicates a failure.  This allows the
caller to inspect the returned message to determine success or failure.

Change-Id: I85a1d234d17ae601ed984109c8aa668aaf86eae2
2018-01-11 16:00:38 -05:00
Richard Pioso bcfe996deb Simplify wait_until_idrac_is_ready() calls
This change simplifies the internal calls to
dracclient.client.WSManClient.wait_until_idrac_is_ready() by no longer
passing arguments. That makes the code cleaner and easier to understand.
It contains no functional change.

The arguments no longer need to be passed, because that function's
default parameter values are now None, which means use the values that
were provided when the WSManClient object was created. The default
values provided at creation are equal to the arguments that were being
explicitly passed.

Change-Id: I70237bb9eda49a98c55a452b7f534a1e720696bb
Related-Bug: #1697558
2017-07-28 18:58:26 -04:00
Richard Pioso 3207d9e1bc Enumerate operations can wait until iDRAC is ready
Web Services Management (WS-Management and WS-Man) Enumerate operations
can fail or return invalid results when issued to an integrated Dell
Remote Access Controller (iDRAC) whose Lifecycle Controller remote
service is not "ready". The following are examples of failures which
have been observed:

+ The result of Enumerate is an error.
+ Enumerate succeeds, but no items are returned when they are known to
exist.
+ Enumerate succeeds, but items for all those known to exist are not
returned.

A Dell technical white paper [0], "Lifecycle Controller Integration --
Best Practices Guide", states that for Lifecycle Controller firmware
1.5.0 and later "The Lifecycle Controller remote service must be in a
'ready' state before running any other WSMAN commands." That applies to
almost all of the workflows and use cases documented by that paper and
supported by this project, openstack/python-dracclient.

This patch defines a new method in class dracclient.client.WSManClient,
enumerate(). It extends its base class's implementation by adding a new
parameter that indicates whether or not it should wait until the iDRAC
is ready to accept commands before issuing the Enumerate command. When
it is true, that method waits until the iDRAC is ready before issuing
the command. Since almost all Enumerate operations require the iDRAC to
be ready, the new parameter's default value is 'True'.

[0]
http://en.community.dell.com/techcenter/extras/m/white_papers/20442332

Change-Id: Ied659a4ee45b1dd55cd3a420301d866d52c838fb
Partial-Bug: #1697558
Related-Bug: #1691808
2017-07-25 17:27:42 -04:00
Richard Pioso deed7d7c1c Invoke operations can wait until iDRAC is ready
Web Services Management (WS-Management and WS-Man) Invoke operations can
fail when issued to an integrated Dell Remote Access Controller (iDRAC)
whose Lifecycle Controller remote service is not "ready".

A Dell technical white paper [0], "Lifecycle Controller Integration --
Best Practices Guide", states that for Lifecycle Controller firmware
1.5.0 and later "The Lifecycle Controller remote service must be in a
'ready' state before running any other WSMAN commands." That applies to
almost all of the workflows and use cases documented by that paper and
supported by this project, openstack/python-dracclient. A notable
exception is the dracclient.client.WSManClient.is_idrac_ready() method,
which is a chicken and egg situation.

This patch adds a new parameter to the
dracclient.client.WSManClient.invoke() method that indicates whether or
not it should wait until the iDRAC is ready to accept commands before
issuing the Invoke command. When it is true, that method waits until the
iDRAC is ready before issuing the command. Since almost all Invoke
operations require the iDRAC to be ready, the new parameter's default
value is 'True'.

[0]
http://en.community.dell.com/techcenter/extras/m/white_papers/20442332

Change-Id: Ib5b9fb2a954579be40f47304c70157ab1f00d39c
Partial-Bug: #1697558
Related-Bug: #1691808
2017-07-25 17:27:39 -04:00
Richard Pioso c75969dd8d Parameterize iDRAC is ready retries at class level
Web Services Management (WS-Management and WS-Man) requests/commands can
fail or return invalid results when issued to an integrated Dell Remote
Access Controller (iDRAC) whose Lifecycle Controller remote service is
not "ready". Specifically, that applies to the WS-Man Enumerate and
Invoke operations.

A Dell technical white paper [0], "Lifecycle Controller Integration --
Best Practices Guide", states that for Lifecycle Controller firmware
1.5.0 and later "The Lifecycle Controller remote service must be in a
'ready' state before running any other WSMAN commands." That applies to
almost all of the workflows and use cases documented by that paper and
supported by this project, openstack/python-dracclient. That document
describes how to determine the readiness of the Lifecycle Controller
remote service.

This patch parameterizes the iDRAC is ready retry behavior at the class
level. That makes it possible for consumers of this project, such as
project openstack/ironic, to configure it library API-wide.

Additionally, this patch improves the names of the parameters to class
__init__() methods that control the retry behavior on SSL errors, so
that they are not confused with those added by this patch. Finally, it
defines constants for the default values of the retry behavior on SSL
errors and iDRAC is ready retry parameters, and utilizes those new
constants.

[0]
http://en.community.dell.com/techcenter/extras/m/white_papers/20442332

Change-Id: Ie866466a8ddf587a24c6d25ab903ec7b24022ffd
Partial-Bug: #1697558
Related-Bug: #1691272
Related-Bug: #1691808
2017-07-24 19:29:15 -04:00
Jenkins bb3313de14 Merge "Refactor iDRAC is ready functionality" 2017-07-13 18:56:35 +00:00
Richard Pioso 10df06f6c3 Refactor iDRAC is ready functionality
Web Services Management (WS-Management and WS-Man) requests/commands can
fail or return invalid results when issued to an Integrated Dell Remote
Access Controller (iDRAC) whose Lifecycle Controller remote service is
not "ready". Specifically, that applies to the WS-Man Enumerate and
Invoke operations.

A Dell technical white paper [0], "Lifecycle Controller Integration --
Best Practices Guide", states that for Lifecycle Controller firmware
1.5.0 and later "The Lifecycle Controller remote service must be in a
'ready' state before running any other WSMAN commands." That applies to
almost all of the workflows and use cases documented by that paper and
supported by this project, openstack/python-dracclient. That document
describes how to determine the readiness of the Lifecycle Controller
remote service. A project commit [1] implements that.

This refactors that patch in preparation for changing the internal
implementation of the project's APIs so that they follow that best
practice. The implementation of is_idrac_ready() and
wait_until_idrac_is_ready() have been relocated further down the call
stack, to the iDRAC specialization of the WS-Man client defined by class
dracclient.client.WSManClient. Those methods continue to be available
through the API provided by class dracclient.client.Client.

No changes have been made to this project's APIs nor to any functional
behavior.

[0]
http://en.community.dell.com/techcenter/extras/m/white_papers/20442332
[1]
39253bb272

Change-Id: I87996bbca129995f6c84848ebdb0c33cfedeea53
Partial-Bug: #1697558
Related-Bug: #1691808
2017-07-10 20:55:17 -04:00
Anish Bhatt c9e33ccd4c Fetch system attributes
Change-Id: I323366268e359afbe0c7556e88cc6da936af8362
2017-07-06 14:42:34 -07:00
Jenkins e7122263c4 Merge "Fix immediate failure on SSL errors" 2017-06-16 21:48:48 +00:00
Christopher Dearborn d6edaac2a1 Fix immediate failure on SSL errors
This patch adds retry logic to communication with the iDRAC so that
intermittent SSLErrors or ConnectionErrrors will not cause an immediate
failure of the operation.

Change-Id: Idc56e961699702eca734cba1da5e56cac0ad4832
Closes-Bug: 1691272
2017-06-06 16:57:33 -04:00
Christopher Dearborn 39253bb272 Added ability to determine if an iDRAC is ready
This patch adds the ability to determine if an iDRAC is ready to accept
commands.

Change-Id: I929deada3dda7b09a6f29033fff89d9b0382aef8
Partial-Bug: 1691808
2017-05-30 16:42:02 -04:00
Anish Bhatt 15b1c2a32f Add support for idrac_card and lifecycle_controller attributes
Change-Id: I305976e639a406de19f23dcfb5207a25c6c311ba
2017-02-14 09:47:04 -08:00
Anish Bhatt 5e6b55dac3 Use InstanceId as unique attribute identifier rather than name
AttributeName just happens to be unique for everything under
DCIM_BIOS* but this is not a guarantee. Using InstanceId instead
which is guaranteed to be unique.

Discussion on the list
http://lists.openstack.org/pipermail/openstack-dev/2016-September/103602.html

Closes-Bug: #1635419
Signed-off-by: Anish Bhatt <anish.bhatt@salesforce.com>
Change-Id: I93c0f7919ecfd77642634d1d0addfe8a79aa6f57
2016-10-27 12:38:31 -07:00
Imre Farkas 157eba7a64 Add NIC enumeration to InventoryManagement
Change-Id: I32e3d8ae5103d3a0f47a9d0aa3bb9464ff575d03
2016-08-09 16:43:06 +02:00
Stig Telfer 3e9d66173b Add interface to convert disks to RAID mode
A new function, convert_physical_disks, converts disks to and from
RAID mode.  This function enables a Dell system at factory defaults
to be initialised with a RAID configuration by python-dracclient.

Change-Id: Ice40bfb47485056428a22c216990cf0a026c73d2
2016-06-07 17:15:04 +01:00
Chris Coyle b87d729dca Add memory enumeration to InventoryManagement
Change-Id: I0e58122a8d68d927b057aeedd2c127d62d9bae92
2016-04-06 15:00:11 -04:00
Jenkins f2cd8bbd8a Merge "Add documentation" 2016-04-04 16:49:13 +00:00