:doc:`StorageGateway <../../storagegateway>` / Client / update_gateway_software_now

***************************
update_gateway_software_now
***************************



.. py:method:: StorageGateway.Client.update_gateway_software_now(**kwargs)

  

  Updates the gateway virtual machine (VM) software. The request immediately triggers the software update.

   

  .. note::

    

    When you make this request, you get a ``200 OK`` success response immediately. However, it might take some time for the update to complete. You can call  DescribeGatewayInformation to verify the gateway is in the ``STATE_RUNNING`` state.

    

   

  .. warning::

     

    A software update forces a system restart of your gateway. You can minimize the chance of any disruption to your applications by increasing your iSCSI Initiators' timeouts. For more information about increasing iSCSI Initiator timeouts for Windows and Linux, see `Customizing your Windows iSCSI settings <https://docs.aws.amazon.com/storagegateway/latest/userguide/ConfiguringiSCSIClientInitiatorWindowsClient.html#CustomizeWindowsiSCSISettings>`__ and `Customizing your Linux iSCSI settings <https://docs.aws.amazon.com/storagegateway/latest/userguide/ConfiguringiSCSIClientInitiatorRedHatClient.html#CustomizeLinuxiSCSISettings>`__, respectively.

    

  

  See also: `AWS API Documentation <https://docs.aws.amazon.com/goto/WebAPI/storagegateway-2013-06-30/UpdateGatewaySoftwareNow>`_  


  **Request Syntax**
  ::

    response = client.update_gateway_software_now(
        GatewayARN='string'
    )
    
  :type GatewayARN: string
  :param GatewayARN: **[REQUIRED]** 

    The Amazon Resource Name (ARN) of the gateway. Use the  ListGateways operation to return a list of gateways for your account and Amazon Web Services Region.

    

  
  
  :rtype: dict
  :returns: 
    
    **Response Syntax**

    
    ::

      {
          'GatewayARN': 'string'
      }
      
    **Response Structure**

    

    - *(dict) --* 

      A JSON object containing the Amazon Resource Name (ARN) of the gateway that was updated.

      
      

      - **GatewayARN** *(string) --* 

        The Amazon Resource Name (ARN) of the gateway. Use the  ListGateways operation to return a list of gateways for your account and Amazon Web Services Region.

        
  
  **Exceptions**
  
  *   :py:class:`StorageGateway.Client.exceptions.InvalidGatewayRequestException`

  
  *   :py:class:`StorageGateway.Client.exceptions.InternalServerError`

  

  **Examples**

  Updates the gateway virtual machine (VM) software. The request immediately triggers the software update.
  ::

    response = client.update_gateway_software_now(
        GatewayARN='arn:aws:storagegateway:us-east-1:111122223333:gateway/sgw-12A3456B',
    )
    
    print(response)

  
  Expected Output:
  ::

    {
        'GatewayARN': 'arn:aws:storagegateway:us-east-1:111122223333:gateway/sgw-12A3456B',
        'ResponseMetadata': {
            '...': '...',
        },
    }

  