1

In Reports -> Broken links page for some records it is showing

permission restrictions deny you access to this broken link

Site have only one language also, some of the broken links are showing with https link also. So I don't think the problem with protocol or language.

What is the part of link-checker cron. It was not running and i tried running it manually? But still the broken link is not showing (which I intentionally put some broken link).

What else could be the problem? How to resolve this issue?

Please suggest other than "Re-Analyze link data", that removes all old records also not showing the new one.

1

I was able to view what the links were by modifying linkchecker.pages.inc line 158 to be the following:

if (empty($nids) && empty($cids) && empty($bids) && !user_access('bypass node access')) {

With this change, assuming that you have bypass node access, you will be able to see the links instead of the annoying message. Unfortunately, the "Edit Link Settings" option will not work for these rows still, because the link data may be out of date.

In order to fix the result list for real, I ran the following drush commands, one after the other. They are defined in linkchecker.drush.inc:

drush linkchecker-analyze

Reanalyzes content for links. Recommended after module has been upgraded. This can also be done from the settings page: /admin/config/content/linkchecker

drush linkchecker-check

Check link status. (Note that this doesn't check them all, only the batch number set in your linkchecker settings.)


If necessary, you may also try running this first:

drush linkchecker-clear

Clears all link data and analyze content for links. WARNING: Custom link check settings are deleted. This can also be done from the settings page: /admin/config/content/linkchecker

0

One possible reason for your manual edit/test run not being flagged by Linkchecker is that the linkchecker scan didn't include your edit in the batch of content/data scanned.

The Linkchecker module's cron job only processes batches of content at a time (similar to Drupal's built-in search index), and may need to be run several times if there's a lot of content being generated during the course of the day.


With respect to the error message you're seeing

permission restrictions deny you access to this broken link

on the Broken Links report page, you should check to make sure the module is up-to-date.

  1. If your site is still running version 7.x-1.1, then LinkChecker may be showing the error because of the cross domain issue previously reported here: https://www.drupal.org/project/linkchecker/issues/2264181

  2. If your site is running a more recent/current version of LinkChecker, you may still be encountering the language issue if the site is old. Some content may have no language attribute (undefined), while others reflect (english). If this is the case, you can bulk set the language attribute of all the nodes. Refer to How can I set the language of nodes in bulk to existing content when making a site multilingual?

  3. This error message is also known to occur when a link points to an unpublished node or any content/view pages that require authentication/sign-in.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.