How do I overwrite the controller for admin/content? On admin/content, I have created different views for articles and basic pages (the default content types created from Drupal). On admin/content, it shows Content | Article | Basic Page. When I already have Article and Basic page as separate.

On admin/content, I would like to show as Blank means no data instead of showing all data.

I tried the following code.

modules/custom/content/src/Routing/RouteSubscriber.php

namespace Drupal\content\Routing;

use Drupal\Core\Routing\RouteSubscriberBase;
use Symfony\Component\Routing\RouteCollection;

/**
 * Listens to the dynamic route events.
 */
class RouteSubscriber extends RouteSubscriberBase {

  /**
   * Used to alter routes.
   */
  protected function alterRoutes(RouteCollection $collection) {
    if ($route = $collection-&gt;get('system.admin_content')) {
      $route-&gt;setDefaults(array(
        '_controller' =&gt; '\Drupal\content\Controller\ContentOverviewController::overview',
      ));
    }
  }

}


I'm trying to override its default controller, so it show blank.

The code for the controller is the following one.

namespace Drupal\content\Controller;

use Drupal\system\Controller\SystemController;

/**
 * Class ContentOverviewController.
 */
class ContentOverviewController extends SystemController {

  /**
   * Content Overview.
   */
  public function overview($link_id) {

    $build = [
      '#markup' =&gt; $this-&gt;t('Hello World!'),
    ];
    return $build;
  }

}


The code doesn't seem to work.

I also tried to disable the content view, but that is not needed.
Check a namespace in your RouteSubscriber.php

You have 

namespace Drupal\content\Routing


Should be

namespace Drupal\mcontent\Routing


Because your custom module is mcontent (not content)