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

***************
disable_gateway
***************



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

  

  Disables a tape gateway when the gateway is no longer functioning. For example, if your gateway VM is damaged, you can disable the gateway so you can recover virtual tapes.

   

  Use this operation for a tape gateway that is not reachable or not functioning. This operation is only supported in the tape gateway type.

   

  .. warning::

     

    After a gateway is disabled, it cannot be enabled.

    

  

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


  **Request Syntax**
  ::

    response = client.disable_gateway(
        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) --* 

      DisableGatewayOutput

      
      

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

        The unique Amazon Resource Name (ARN) of the disabled gateway.

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

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

  

  **Examples**

  Disables a gateway when the gateway is no longer functioning. Use this operation for a gateway-VTL that is not reachable or not functioning.
  ::

    response = client.disable_gateway(
        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': {
            '...': '...',
        },
    }

  