vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB4 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=251)
-   -   Attachments in File Upload Manager (https://vborg.vbsupport.ru/showthread.php?t=325541)

ed762 08-23-2017 06:57 PM

Attachments in File Upload Manager
 
Does anyone know which one of the scheduled task is responsible for cleaning attachments that are not used in the file upload manager? It looks whatever cron it is supposed to be does not work, so none of the attachment gets cleaned up.

Dave 08-23-2017 07:03 PM

I believe /includes/cron/cleanup2.php around line 64 to 72.

ed762 08-24-2017 06:06 PM

Find the lines. The cron ( Vb 4.2.3 ) is not working and images are still sitting in the file management even after 1 hour.

Does anyone know the reason why this is not working? Has anyone manually deleted the images that are no longer associated with any posts? How did you go about cleaning it up?

Dave 08-24-2017 06:21 PM

Is the refcount column value in the Filedata table 0 of said attachment(s)?

ed762 08-24-2017 08:02 PM

None of the attachments have "0" in the refcount at all . Is that why the cron fail?

Dave 08-24-2017 08:16 PM

Yes. refcount is the reference count (or the number of references to that attachment). It has a strict check of 0 against it, which is why it doesn't delete the attachments.

Stingray27 08-24-2017 09:28 PM

Quote:

Originally Posted by ed762 (Post 2589570)
None of the attachments have "0" in the refcount at all . Is that why the cron fail?

Its not failing then, its doing its job.
Attachments with a ref count > 0 should never be deleted.

ed762 08-25-2017 09:22 AM

Quote:

Originally Posted by Dave (Post 2589571)
Yes. refcount is the reference count (or the number of references to that attachment). It has a strict check of 0 against it, which is why it doesn't delete the attachments.

Is this a bug within VB? because obviously there is a large number of images that are not in use by any threads.

Anyway to manually fix it?

Dave 08-25-2017 11:52 AM

I'm not aware of any bugs regarding attachments in the latest version of vBulletin.

Kane@airrifle 08-25-2017 11:52 AM

Quote:

Originally Posted by ed762 (Post 2589566)
Find the lines. The cron ( Vb 4.2.3 ) is not working and images are still sitting in the file management even after 1 hour.

Does anyone know the reason why this is not working? Has anyone manually deleted the images that are no longer associated with any posts? How did you go about cleaning it up?

Yes but it is obviously fraught with danger. You need to triple check everything and backup first.

I used the queries from this post: https://www.vbulletin.com/forum/foru...00#post3948600

There was a VBIV open for the failing cron cleanup, not sure if it was fixed in 4.2.3


All times are GMT. The time now is 01:15 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01223 seconds
  • Memory Usage 1,732KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (3)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete