def remove(silent=None):
    """
    Interactive removal part for the ASD manager
    :param silent: If silent == '--force-yes' no question will be asked to confirm the removal
    :type silent: str
    :return: None
    """
    os.environ['OVS_LOGTYPE_OVERRIDE'] = 'file'
    print '\n' + Interactive.boxed_message(['ASD Manager removal'])

    ##############
    # VALIDATION #
    ##############
    local_client = LocalClient()
    if not local_client.file_exists(filename=Toolbox.BOOTSTRAP_FILE):
        print '\n' + Interactive.boxed_message(['The ASD Manager has already been removed'])
        sys.exit(1)

    print '  - Validating configuration file'
    config = _validate_and_retrieve_pre_config()
    if config is None or 'store' not in config:
        print '\n' + Interactive.boxed_message(['Cannot remove the ASD manager because not all information could be retrieved from the pre-configuration file'])
        sys.exit(1)

    print '  - Validating node ID'
    with open(Toolbox.BOOTSTRAP_FILE, 'r') as bs_file:
        try:
            alba_node_id = json.loads(bs_file.read())['node_id']
        except:
            print '\n' + Interactive.boxed_message(['JSON contents could not be retrieved from file {0}'.format(Toolbox.BOOTSTRAP_FILE)])
            sys.exit(1)

    print '  - Validating configuration management'
    store = config['store']
    try:
        Configuration.list(key='ovs')
    except:
        if store == 'arakoon':
            print '\n' + Interactive.boxed_message(['Could not connect to Arakoon'])
        else:
            print '\n' + Interactive.boxed_message(['Could not connect to Etcd.',
                                                    'Please make sure an Etcd proxy is available, pointing towards an OpenvStorage cluster.'])
        sys.exit(1)

    ################
    # CONFIRMATION #
    ################
    os.environ['ASD_NODE_ID'] = alba_node_id
    from source.app.api import API
    print '  - Retrieving ASD information'
    all_asds = {}
    try:
        all_asds = API.list_asds.original()
    except:
        print '  - ERROR: Failed to retrieve the ASD information'

    interactive = silent != '--force-yes'
    if interactive is True:
        message = 'Are you sure you want to continue?'
        if len(all_asds) > 0:
            print '\n\n+++ ALERT +++\n'
            message = 'DATA LOSS possible if proceeding! Continue?'

        proceed = Interactive.ask_yesno(message=message, default_value=False)
        if proceed is False:
            print '\n' + Interactive.boxed_message(['Abort removal'])
            sys.exit(1)

    ###########
    # REMOVAL #
    ###########
    print '  - Removing from configuration management'
    Configuration.uninitialize(node_id=alba_node_id)

    if len(all_asds) > 0:
        print '  - Removing disks'
        for device_id, disk_info in API.list_disks.original().iteritems():
            if disk_info['available'] is True:
                continue
            try:
                print '    - Retrieving ASD information for disk {0}'.format(disk_info['device'])
                for asd_id, asd_info in API.list_asds_disk.original(disk_id=device_id).iteritems():
                    print '      - Removing ASD {0}'.format(asd_id)
                    API.asd_delete.original(disk_id=device_id, asd_id=asd_id)
                API.delete_disk.original(disk_id=device_id)
            except Exception as ex:
                print '    - Deleting ASDs failed: {0}'.format(ex)

    print '  - Removing services'
    for service_name in API.list_maintenance_services.original()['services']:
        print '    - Removing service {0}'.format(service_name)
        API.remove_maintenance_service.original(name=service_name)
    for service_name in [WATCHER_SERVICE, MANAGER_SERVICE]:
        if ServiceManager.has_service(name=service_name, client=local_client):
            print '    - Removing service {0}'.format(service_name)
            ServiceManager.stop_service(name=service_name, client=local_client)
            ServiceManager.remove_service(name=service_name, client=local_client)

    if store == 'arakoon':
        from source.tools.configuration.arakoon_config import ArakoonConfiguration
        local_client.file_delete(filenames=ArakoonConfiguration.CACC_LOCATION)
    local_client.file_delete(filenames=Toolbox.BOOTSTRAP_FILE)
    print '\n' + Interactive.boxed_message(['ASD Manager removal completed'])
            ServiceManager.stop_service(service_name, client)

        # Migrate main configuration file
        path = '/opt/alba-asdmanager/config/config.json'
        if client.file_exists(path):
            _log('Migrating old configuration file to Etcd')
            with open(path) as config_file:
                config = json.load(config_file)
            node_id = config['main']['node_id']
            # Migrate configuration file
            EtcdConfiguration.set('/ovs/alba/asdnodes/{0}/config/main'.format(node_id), config['main'])
            EtcdConfiguration.set('/ovs/alba/asdnodes/{0}/config/main|port'.format(node_id), 8500)
            EtcdConfiguration.set('/ovs/alba/asdnodes/{0}/config/network'.format(node_id), config['network'])
            ServiceManager.add_service(service_name, client, params={'ASD_NODE_ID': node_id,
                                                                     'PORT_NUMBER': str(8500)})
            client.file_delete(path)

        # Migrate ASDs
        for filename in glob.glob('/mnt/alba-asd/*/asd.json'):
            _log('Migrating old asd configuratoin files to Etcd')
            with open(filename) as config_file:
                config = json.load(config_file)
            EtcdConfiguration.set('/ovs/alba/asds/{0}/config'.format(config['asd_id']), json.dumps(config, indent=4), raw=True)
            ServiceManager.add_service('alba-asd', client, params={'ASD': config['asd_id']}, target_name='alba-asd-{0}'.format(config['asd_id']))
            os.remove(filename)

        # Cleanup old data
        if client.dir_exists('/opt/alba-asdmanager'):
            _log('Removing old alba-asdmanager data')
            client.dir_delete('/opt/alba-asdmanager')