Skip to content

Support uploading openbmc firmware in parallel

chenglch edited this page Oct 12, 2017 · 1 revision

The main purpose of this design is to help solve the issue of #4055 [1].

[1] https://github.com/xcat2/xcat-core/issues/4055

Background

As the http async perl library do not provide the interface to upload large attachment, xcat is using curl command to upload file to the openbmc side. As shell command is called in block mode, the original implementation call only upload files sequentially. For a large cluster, this is unacceptable.

Solution

This design hope to reuse the old frame as far as possible. The shell command will be called within the child process for each node. When the command ends, the parent process will extract the node from process id and continue the state machine depends on its return code. Some example like below:

while (1) { 
        last unless ($wait_node_num);
        while (my ($response, $handle_id) = $async->wait_for_next_response) {
            deal_with_response($handle_id, $response);
        }
        while ((my $cpid = waitpid(-1, WNOHANG)) > 0) {
            if ($child_node_map{$cpid}) {
                my $node = $child_node_map{$cpid};
                my $rc = $? >> 8;
                if ($rc != 0) {
                    $wait_node_num--;
                } else {
                    $status_info{ $node_info{$node}{cur_status} }->{process}->($node, undef);
                }
                delete $child_node_map{$cpid};
            }
        }
    } 

Plan

  1. Complete the state machine, fork and wait framework for the firmware upload.
  2. Reuse this framework to upload the ssh key ( By Xu Wei)
  3. error handling for uploading/activating for rflash https://github.com/xcat2/xcat-core/issues/4063
  4. Run rflash in background https://github.com/xcat2/xcat-core/issues/3671

News

History

  • Oct 22, 2010: xCAT 2.5 released.
  • Apr 30, 2010: xCAT 2.4 is released.
  • Oct 31, 2009: xCAT 2.3 released. xCAT's 10 year anniversary!
  • Apr 16, 2009: xCAT 2.2 released.
  • Oct 31, 2008: xCAT 2.1 released.
  • Sep 12, 2008: Support for xCAT 2 can now be purchased!
  • June 9, 2008: xCAT breaths life into (at the time) the fastest supercomputer on the planet
  • May 30, 2008: xCAT 2.0 for Linux officially released!
  • Oct 31, 2007: IBM open sources xCAT 2.0 to allow collaboration among all of the xCAT users.
  • Oct 31, 1999: xCAT 1.0 is born!
    xCAT started out as a project in IBM developed by Egan Ford. It was quickly adopted by customers and IBM manufacturing sites to rapidly deploy clusters.
Clone this wiki locally