プロジェクト

全般

プロフィール

Vote #81179

未完了

print largest attachements, sorted by size

Admin Redmine さんが約4年前に追加. ほぼ4年前に更新.

ステータス:
New
優先度:
通常
担当者:
-
カテゴリ:
Attachments_19
対象バージョン:
-
開始日:
2022/05/09
期日:
進捗率:

0%

予定工数:
category_id:
19
version_id:
0
issue_org_id:
34431
author_id:
403162
assigned_to_id:
0
comments:
2
status_id:
1
tracker_id:
2
plus1:
0
affected_version:
closed_on:
affected_version_id:
ステータス-->[New]

説明

I just got the dreaded 90% of the filesystem in use and spend some time creating a MySQL query that helps me find the largest attachments.

mysql> select attachments.container_id,attachments.filename,sys.format_bytes(attachments.filesize),users.login from attachments right join users on attachments.author_id=users.id where container_id is not NULL order by filesize desc limit 10;
+--------------+--------------------------------+----------------------------------------+------------------+
| container_id | filename                       | sys.format_bytes(attachments.filesize) | login            |
+--------------+--------------------------------+----------------------------------------+------------------+
|        20956 | VID_20191004_083624.mp4        | 704.22 MiB                             | user1            |
|        20956 | VID_20190710_145242.mp4        | 448.04 MiB                             | user1            |
|        17897 | CompleteMQTG_DGCA_20170226.pdf | 443.92 MiB                             | engineering      |
|        18162 | BoschRexroth_Manual.rar        | 406.22 MiB                             | user2            |
|        14327 | ADU indication issue.mp4       | 389.63 MiB                             | engineering      |
|        13816 | Engine no 2 Flame out.mp4      | 382.81 MiB                             | engineering      |
|        13816 | Engine 1 Flame out.mp4         | 379.76 MiB                             | engineering      |
|        24115 | 20200611_004044.mp4            | 374.91 MiB                             | user2            |
|        18287 | Run System Check.MOV           | 373.93 MiB                             | user2            |
|        20956 | VID_20190625_140218.mp4        | 371.31 MiB                             | user1            |
+--------------+--------------------------------+----------------------------------------+------------------+

After which I could send out an email asking various users if those attachments are still needed.

Perhaps this might be useful to someone.


journals

--------------------------------------------------------------------------------

--------------------------------------------------------------------------------

他の形式にエクスポート: Atom PDF

いいね!0
いいね!0