Commit Graph

412 Commits

Author SHA1 Message Date
Andreas Jaeger 3e5483d1dc Retire repository
Fuel (from openstack namespace) and fuel-ccp (in x namespace)
repositories are unused and ready to retire.

This change removes all content from the repository and adds the usual
README file to point out that the repository is retired following the
process from
https://docs.openstack.org/infra/manual/drivers.html#retiring-a-project

See also
http://lists.openstack.org/pipermail/openstack-discuss/2019-December/011647.html

Depends-On: https://review.opendev.org/699362
Change-Id: If0c2011947c9eb63f59093812b5f9f95ce56a6f8
2019-12-18 09:39:30 +01:00
Vladimir Sharshov (warpc) 039ce9e0b8 Do not send data about nodes in case of task deployment
Nailgun use data about nodes in stop deployment respond
to reset it to discovory state which is unexpected behavior
for already provisioned nodes in case of task deployment

Change-Id: I39de8a8afd627b0bf209d9a7f6ad6e19abd99016
Partial-Bug: #1672964
2017-03-28 16:39:03 +03:00
Jenkins cbec1d0887 Merge "Add command_prefix field to puppet mcagent" 2017-03-21 13:30:01 +00:00
Vladimir Sharshov (warpc) 496212798e Fix wrong ready status instead of stopped for stop deployment
Report ready status for node means successful node status
which can be get if all tasks was passed with ready and skipped
statuses.

Same effect can be get if Astute mark node as skipped. In this
case we also get equal status 'successful'.

So we need ask node about skipped statuses before ask it about
successful status to prevent losing context about stop
deployment operation.

Change-Id: I3c042425cab800de0bfc4e03f29414b145f44983
Closes-Bug: #1672964
2017-03-17 20:48:52 +03:00
Vladimir Kozhukalov ec4abb2573 Add command_prefix field to puppet mcagent
This will allow to run puppet with environment variables.
E.g. FACTER_foo=bar puppet apply ...

Change-Id: I1e435262e810ead46689078513607f6a99a19043
Implements: blueprint get-rid-cobbler-dnsmasq
(cherry picked from commit c734b03042)
2017-03-15 11:49:35 +03:00
Vladimir Sharshov (warpc) 892894bfb5 task_deploy: no implicit conversion of String into Integer
Now Astute will not calculate fault tolerance groups and
critical node uids twice.

Change-Id: I3bf2dd0ffc0fc74fd9c670bd50b32e3285ae7e2a
Closes-Bug: #1669499
2017-03-02 19:16:31 +03:00
Vladimir Sharshov (warpc) c489e972ff Add retries for upload tasks: upload_file and upload_files
Some of mcollective client for some reason can ignore task
from Astute. For such cases Astute shoult retry it request.

Also:
- refactoring tasks to support class hook post_initialize
  instead of super
- change @task and @ctx to equal instance methods
- removed old fixtures

Change-Id: I96613f53303fd71acc437d2f8f47b599bcf3b5d9
2017-02-16 19:06:49 +03:00
Vladimir Sharshov (warpc) 003a0a0efd Astute do not respect debug option for puppet task
Run cluster with enable debug option do not affect
puppet task which always run with debug disable.

It is happened because Nailgun send debug option which
Astute setup for every task, but puppet task required
puppet_debug option to control it behavior. This code
will connect this parameters.

Change-Id: I8df68105aa699e83673c39a0f03bb22673171d6f
Closes-Bug: #1662512
2017-02-07 17:13:35 +03:00
Vladimir Kozhukalov 64d62086e8 Move not provisioned nodes to error status
When there are lot of nodes to provision and we provision
them by chunks, we could fail in the middle due to "Too many
nodes failed to provision". If so, we need to append those
nodes where we did not started provision at all to the list
of failed nodes. Otherwise, those nodes will be reported
as 'provisioned' with progress = 100 and rebooted.
But for some reasons we bind all nodes before starting provision
to debian-installer profile in cobbler, and being rebooted
these not provisioned nodes will fail to boot, because since
7.0 we put empty files where cobbler expects debian-installer
kernel and initrd files. :-)

Change-Id: I2a401b80614ee7dd5a10931b9b50bcff066f790f
Closes-Bug: #1656269
(cherry picked from commit 570049ca1f)
2017-01-16 15:12:18 +03:00
Jenkins d411a2e0f2 Merge "Network problem tolerance puppet status check" 2017-01-06 11:53:16 +00:00
Vladimir Sharshov (warpc) 7c0485eb1a Network problem tolerance puppet status check
Connection between node and Astute can be lost some
times, so we need more tries to get info about task
status on node.

Two changes:

- instead of 1 try Astute will run 6 tries with 10
timeout for every attempt;
- it will process such behavior for puppet using separately
  retries: puppet_undefined_retries

Instead of full puppet retry status retry is safety because
it is idempotent.

Puppet undefined retries can be setup using Astute config
or sending undefined_retries in puppet task parameters same
way as for usual retries. Most important thing: it will refresh
to original value every time when Astute get defined answer.

Change-Id: Ie86576a3400be5a6b11041c8e6acf89abf3bbd51
Related-Bug: #1653210
Closes-Bug: #1653737
2017-01-05 18:02:18 +03:00
Vladimir Sharshov (warpc) b0752c7a78 Fix fail detection for provisioning
Add test to prevent such behavior in future

Change-Id: If833723f0301f2008e6aabfc888d0bdf693f4f2e
Partial-Bug: #1653210
2016-12-30 12:45:13 +03:00
Jenkins 06fe7856f6 Merge "Upload file task timeout support" 2016-12-28 14:50:06 +00:00
Vladimir Sharshov (warpc) dc47550460 Use async shell call for provision
This change allow to use async shell task based on
puppet to run provision commands.

It is transition change between old run way of image
provision and provision as graph which will also
used async shell to run.

It is more fault tolerance way to provision because
temporary problem with connection between master node
and provisioning node do not block or fail provision.

Important notice: it is allow only if bootstrap image
has puppet and daemonize packages which is true for 9.2
or higher releases.

Change-Id: Ie634fae9b63bf0c103ec8926647af75b57cefe23
Related-Bug: #1644618
2016-12-27 19:51:57 +03:00
Vladimir Sharshov (warpc) f475c45dfc Upload file task timeout support
Astute will not retry and will not wait around 10 minutes for
every node which connection was missed in case of
upload file task. For now it will wait only default upload
timeout.

Default timeout for upload now can be setup in config. For now
it is 60 seconds. Also upload file task now support timeout
parameter which will overide default.

Change-Id: Ice8207f539566a50d4eb30c04ab563c3ee1278ec
Closes-Bug: #1629031
2016-12-27 19:43:16 +03:00
Jenkins 1dc4d754b7 Merge "Speed up graph && node processing" 2016-12-16 13:59:24 +00:00
Vladimir Sharshov (warpc) e12bdbd984 Speed up graph && node processing
- in case of big number of node (more then 200) and tasks
(more then 20000), progress calculation can slow down
- remove status magent call from puppet run (decrease number
  of magent calls from 2 to 1 in case of positive scenario)

Change-Id: I70675a6bbd391d0112c594626bdb0ce7bb9e3e1e
2016-12-16 15:04:15 +03:00
Vladimir Sharshov (warpc) 3905cab1ea Compact nailgun hook error message
This change change error message by adding '\n\n' before error
details which give Fuel UI ability to hide this part of message.

Change-Id: I2e93ee3aa0aae183cd320d2438f781a975c5e70f
Closes-Bug: #1614422
2016-12-15 23:11:14 +03:00
Jenkins 5dccee10ec Merge "Revert "Support global progress for tasks"" 2016-11-23 17:26:08 +00:00
Jenkins 41bf29fea0 Merge "Set timeout for resource which is used to wrap shell tasks." 2016-11-22 09:07:10 +00:00
Jenkins 5856dc1076 Merge "Run nailgun-agent on rebooted nodes" 2016-11-14 08:59:01 +00:00
Evgeny L e4abca6827 Set timeout for resource which is used to wrap shell tasks.
Slow tasks fail, because default timeout for `exec` resource
is 300 seconds. The patch passes timeout from the task to
puppet wrapper.

Closes-bug: #1641190
Change-Id: I8f7c2120e61144911481c83b0da391e30bbc6f2f
2016-11-11 20:40:28 +00:00
Vladimir Kuklin 1ab30505b7 Revert "Support global progress for tasks"
This reverts commit 3f21d35f35.

Change-Id: If0cf99129fdc38c40ee8322c872f6b4f9b83c0b5
Partial-bug: #1633212
2016-11-08 09:38:26 +00:00
Vladimir Sharshov (warpc) bca595a964 New version of puppet task engine
Changes:

- remove report from task engine;
- remove old logic for hangs and 'idling' statuses;
- increase code redability;
- add code docs;
- support retries in case of MClient errors for status
  and run actions;
- replace timeout raise on usual code;
- descrease waiting time for puppet run (from 120 to 10) and
  time between try (from 30 to 2);
- mcollective retry descrease from 5 to 1. Now it will use
  puppet retries if failed during network/mcollective problem
  after 1 try.

Closes-Bug: #1613396
Change-Id: I98fe3df65ef335b03eceb2c401eba12cf68ee1c8
2016-10-17 13:08:30 +03:00
Vladimir Sharshov (warpc) de9c731fc2 Run nailgun-agent on rebooted nodes
Without this change some node can be marked wrongly
as offline in Nailgun side.

Change-Id: I4a89ac101867effe6f277c2dcaa93e9b67b65875
Closes-Bug: #1626072
2016-10-13 14:09:01 +00:00
Vladimir Sharshov (warpc) 11ec66899e Support global progress for tasks
Calculate progress for cluster using simple formula

    100 * all_tasks_finished / all_tasks_total

It will works with custom graph too.

Change-Id: Iaea07ec19d80d5f344c8ecf434f771da7a608157
Closes-Bug: #1623937
2016-09-26 14:02:30 +03:00
Jenkins c11a24c052 Merge "Fix non-working zero tolerance error group" 2016-09-26 10:56:49 +00:00
Jenkins 00f10f8cfc Merge "Increase xml rpc timeout" 2016-09-23 09:32:07 +00:00
Georgy Kibardin ac2703949f Remove puppet status files right before running it
This prevents us from picking up status files from previous run when
current run hasn't written them for some reason, i.e. crash etc.

Change-Id: I83d0b4aa3c42210279b75ed7b575919d2d092ff0
Closes-Bug: #1560026
(cherry picked from commit e5311dd97b)
2016-09-21 14:53:23 +00:00
Vladimir Sharshov (warpc) 9dee3b3da7 Fix non-working zero tolerance error group
Also:

- catch divide by 0 in case of progress
- catch sutuation with report for node without current tasks

Change-Id: If4a975abf6da4ba1848be50a23f6532f649d2982
Closes-Bug: #1620858
2016-09-20 15:29:35 +03:00
Georgy Kibardin 0e93c8b6c8 Increase xml rpc timeout
With hundreds of nodes Cobbler sync cannot fit default 30 secods
timeout. Cobbler performance is going to be investigated in the next
release. By now lets just increase the timeout.

Change-Id: Ief8ff93fc808549e8d729040512a266b0c09383d
Closes-Bug: #1608700
(cherry picked from commit f030161d19)
2016-09-16 07:56:55 +00:00
Vladimir Sharshov (warpc) 67896b9a59 Zero tolerance for errors on nodes as default behavior
Without this change we do not mark deployment as error
if task on node failed.

Also use early initialize of logger for support library
Deployment

Change-Id: Ibcac4569756b34c3c1ac33f68ae203246d94d2a4
Closes-Bug: #1620858
2016-09-13 20:35:39 +03:00
Jenkins 58dd9d2f2c Merge "Pass auth token to Timmy" 2016-09-13 12:05:40 +00:00
Georgy Kibardin 5bd2ba869a Pass auth token to Timmy
So that it could authenticate in Fuel.

Change-Id: I67461f63eb80ef982e3d6431a3840a1f6fc92843
Closes-Bug: #1618965
2016-09-13 09:23:52 +00:00
Vladimir Kuklin a5c7f47454 Ressurect --start|--end options for graph execution
Change-Id: I22d96ed91a63d498e1e4ace69cdd50d3f6246dc3
CLoses-bug: #1612616
2016-09-12 14:50:57 +00:00
Vladimir Sharshov (warpc) 3446b69a23 Always send 100% progress status for all nodes after tasks run
Change-Id: I48b74a286640a9c0e13872bf04a3c07ed9d24d36
Closes-Bug: #1621456
2016-09-08 17:42:05 +03:00
Jenkins 5efc3170df Merge "Revert "Save error status if err data is present in dhcp checker response"" 2016-09-03 19:00:59 +00:00
Vladimir Kozhukalov db5ed8ba49 Revert "Save error status if err data is present in dhcp checker response"
This reverts commit d6a40e0590.
Also, this change pins activesupport gem version used for ruby 2.1.5

Change-Id: I4002b11fe7716a38ff2321643a8bad9af9de3fa0
Closes-Bug: #1619621
Signed-off-by: Maksim Malchuk <mmalchuk@mirantis.com>
2016-09-03 11:28:44 +03:00
Jenkins ed9bc600e9 Merge "Use summary field for sending task summary" 2016-08-29 16:26:14 +00:00
Jenkins d2cee7d49c Merge "Save error status if err data is present in dhcp checker response" 2016-08-29 14:23:29 +00:00
Denis Egorenko aca2bf3cd1 Use summary field for sending task summary
Currently Astute uses 'custom' field for sending task summary and
it's wrong, because Nailgun searching for 'summary' field.

Change-Id: Ieb01161d92f82768cbc5057b5dbb501fcf53a74f
2016-08-26 15:20:38 +03:00
Jenkins 1871fc7965 Merge "Replace Shotgun with Timmy" 2016-08-24 13:00:44 +00:00
Denis Egorenko 45abdd12bf Fetch noop_run option from deployment_options
Currently noop_run option is fetching from tasks_metadata, but from
nailgun side it is passed as deployment_option.

Change-Id: Id07c5ecd83fc37a95f7f289879459ee5d7aebd7c
2016-08-23 20:15:03 +03:00
Georgy Kibardin 0a87735a1c Replace Shotgun with Timmy
With adding some glue code.

Change-Id: Iebe3b05cac93f3cc00a611a84bb8f3764dba6ad3
implements: bp/shotgun-retirement
2016-08-22 16:29:06 +03:00
Vladimir Sharshov (warpc) 52bc1ed156 Split provision and deletion into several deployment tasks
Several changes:
- new task type 'master_shell': run task on master node using
  node context;
- new task type 'move_to_bootstrap': move non-bootstrap node to
  bootstrap, remove and add all nodes to Cobbler;
- add new task type similar to noop: skipped, stage;
- add new task type 'erase_node': erase node as task;
- refactoring reporting message: now it simple and protect
  from sending duplicate message for any formats
- allow to setup node report behavior using
  node_statuses_transitions in tasks_metadata in case of
  successful, stopped or failed

Change-Id: Iac128fc9d8c764269bebb3e95d6ba9e4a086f919
2016-08-18 21:32:45 +03:00
Denis Egorenko 30e09c10f9 Add ability to run puppet with noop
This patch adds ability to run deployment graph with noop option.
In same time, this option will be applied only to 'shell' and
'puppet' types only.

Change-Id: Ibcb275bb84dfd553ab07e6d58af753ecf96ab3a5
2016-08-18 13:23:12 +03:00
Vladimir Sharshov (warpc) 74f27bef35 Remove old deploy method 'deploy'. Do not use since 6.1.
Also remove old tests and some garbage of old provision method.

Change-Id: Idb340f7d917592c0c764f7bc25bb124fd2f014c2
2016-08-12 19:37:56 +03:00
Jenkins fa254cf7ca Merge "Remove provision using Cobbler profiles (used before 6.1)" 2016-08-08 17:05:25 +00:00
Vladimir Sharshov (warpc) 78830da25b Remove provision using Cobbler profiles (used before 6.1)
Details:

- remove old logs parser code and tests;
- remove stop deployment code for OS installers;
- remove old config variables;
- remove non-using gem 'net-ssh-multi'.

Change-Id: If938bfd8e5484f5431c645e55e7349572b19ea4c
2016-08-05 13:40:03 +03:00
Jenkins d31ce10481 Merge "Add Simulator class and command" 2016-07-29 15:45:28 +00:00