לא ניתן לשחזור בשל עדכון של gem ה-AWS SDK והגנות חדשות של שלמות נתוני AWS

שלום, מישהו יכול לעזור לי?

אני, [2025-02-24T17:35:41.516926 #1]  INFO -- : סיום תהליכים אסינכרוניים
אני, [2025-02-24T17:35:41.516987 #1]  INFO -- : שליחת INT ל-HOME=/var/lib/postgresql USER=postgres הרץ chpst -u postgres:postgres:ssl-cert -U postgres:postgres:ssl-cert /usr/lib/postgresql/15/bin/postmaster -D /etc/postgresql/15/main pid: 38
105:handler-אות (1740418541) קיבל SIGTERM לתזמון סיום...
אני, [2025-02-24T17:35:41.517067 #1]  INFO -- : שליחת TERM להרצה chpst -u redis -U redis /usr/bin/redis-server /etc/redis/redis.conf pid: 105
2025-02-24 17:35:41.517 UTC [38] רישום:  קבלת בקשת סגירה מהירה
2025-02-24 17:35:41.518 UTC [38] רישום:  מבטל כל טרנזקציות פעילות
2025-02-24 17:35:41.521 UTC [38] רישום:  העובד הרקע "גילוי שיכפול לוגי" (PID 52) יצא עם קוד יציאה 1
105: M 24 בפברואר 2025 17:35:41.523 # המשתמש ביקש סגירה...
105: M 24 בפברואר 2025 17:35:41.523 * שמירת הצילום RDB הסופי לפני יציאה.
2025-02-24 17:35:41.525 UTC [47] רישום:  כיבוי
2025-02-24 17:35:41.538 UTC [47] רישום:  התחלת נקודת ביקורת: סגירה מיידית
2025-02-24 17:35:41.550 UTC [47] רישום:  נקודת ביקורת הושלמה: כתב 0 זבובים (0.0%); 0 קבצי WAL נוסף, 0 הוסר, 0 מחזר; זמן כתיבה=0.005 ש', סנכרון=0.001 ש', סך הכל=0.025 ש'; קבצי סנכרון=0, הארוך=0.000 ש', ממוצע=0.000 ש'; מרחק=0 ק״ב, הערכה=1122 ק״ב
2025-02-24 17:35:41.581 UTC [38] רישום:  מערכת הנתונים כבויה
105: M 24 בפברואר 2025 17:35:41.657 * נפח הנתונים נשמר בדיסק
105: M 24 בפברואר 2025 17:35:41.657 # Redis מוכן לצאת, להתראות...


נכשל
--------------------
Pups::ExecError: cd /var/www/discourse && sudo -E -u discourse bundle exec rake s3:upload_assets נכשל עם סטטוס יציאה #Process::Status: pid 2845 exit 1
מיקום הכישלון: /usr/local/lib/ruby/gems/3.3.0/gems/pups-1.2.1/lib/pups/exec_command.rb:132:in `spawn'
ההפעלה נכשלה עם הפרמטרים {"cd"=>"$home", "cmd"=>["sudo -E -u discourse bundle exec rake s3:upload_assets", "sudo -E -u discourse bundle exec rake s3:expire_missing_assets"]}
האתחול נכשלה עם קוד יציאה 1
** הכנסות לא הצליח להפעיל את תהליך ההתחלה ** בבקשה גלול למעלה וחפש הודעות שגיאה מוקדמות, ייתכן שיש יותר מאחד.
./discourse-doctor עשוי לסייע באבחון הבעיה.
 c08b2ad74e9f1171f7677979af4e41a46be92877a0783350b2f020359895a431

The actual error happened much earlier. You should find it.

לייק 1
אני, [2025-02-24T18:17:21.167441 #1]  INFOL -- : e
00 3172 4415 0/144 144 144 4144044 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144 1144
```{"type":"object","properties":{"translation":"/r/www/discourse/lib/tasks/s3.rake:197:ב `each'\n/var/www/discourse/lib/tasks/s3.rake:197:ב `בלוק ב'
/var/www/discourse/vendor/bundle/ruby/3.3.0/gems/rake-13.2.1/exe/rake:27:ב `<top (required)>'\n/usr/local/bin/bundle:25:ב `טעינה'\n/usr/local/bin/bundle:25:ב `<המשך לקריאה>'\nמשימות: TOP => s3:upload_assets\n(ראה את הטעינה המלאה על ידי הרצת המשימה עם --trace)\nI, [2025-02-24T18:17:32.242989 #1]  INFO -- : התקנת חוקים של CORS...\nמדלג\nמדולג: assets/break_string-cc617154cd957804f2f6a1f3bc68258c9cdca3d4b9a322bf777d145fed04790e.js\nמדולג: assets/break_string-cc617154cd957804f2f6a1f3bc68258c9cdca3d4b9a322bf777d145fed04790e.br.js\nמדולג: assets/break_string-cc617154cd957804f2f6a1f3bc68258c9cdca3d4b9a322bf777d145fed04790e.gz.js\nמדולג: assets/break_string-cc617154cd957804f2f6a1f3bc68258c9cdca3d4b9a322bf777d145fed04790e.js.map\nמדולג: assets/service-worker-9312562dd27728d5fd952130f6bb72f4fd253fec8ef551a6e7c3c8ecd9b256da.js\nמדולג: assets/service-worker-9312562dd27728d5fd952130f6bb72f4fd253fec8ef551a6e7c3c8ecd9b256da.br.js\nמדולג: assets/service-worker-9312562dd27728d5fd952130f6bb72f4fd253fec8ef551a6e7c3c8ecd9b256da.gz.js\nמדולג: assets/service-worker-9312562dd27728d5fd952130f6bb72f4fd253fec8ef551a6e7c3c8ecd9b256da.js.map\nמדולג: assets/locales/i18n-3b40e842fd72b9bcc74ea83e094c823cd9ca535e4ecc5e78722e6f99d3656137.js\nמדולג: assets/locales/i18n-3b40e842fd72b9bcc74ea83e094c823cd9ca535e4ecc5e78722e6f99d3656137.br.js\nמדולג: assets/locales/i18n-3b40e842fd72b9bcc74ea83e094c823cd9ca535e4ecc5e78722e6f99d3656137.gz.js\nמדולג: assets/scripts/discourse-test-listen-boot-c65930f97c9935680e942f8e32df616cc91ab7c9371b86db6e5ddf9ad868ae22.js\nמדולג: assets/scripts/discourse-test-listen-boot-c65930f97c9935680e942f8e32df616cc91ab7c9371b86db6e5ddf9ad868ae22.br.js\nמדולג: assets/scripts/disco..."}}}

אני לא בטוח, אבל ההגדרות שלך ב-AWS נראה כי הן מקולקלות איכשהו. לפחות.

@Falco I guess the newest version of discourse do not support BackBlaze any more

I found this tweet, not sure if directly related: https://x.com/jkostolansky/status/1880623631145030054

3 לייקים

yes, I guess that’s the issue
Aws::S3::Errors::InvalidArgument: Unsupported header 'x-amz-checksum-crc32' received for this API call. (Aws::S3::Errors::InvalidArgument)

are there any way to downgrade aws-sdk-s3 gem manually?

[ציטוט=“Yt.w, פרסום:1, נושא:354217”]

הפעלול נכשל עם הפרמטרים {"cd"=>"$home", "cmd"=>["sudo -E -u discourse bundle exec rake s3:upload_assets", "sudo -E -u discourse bundle exec rake s3:expire_missing_assets"]}

[/ציטוט]

כנראה משהו בהגדרות ה-S3 שלך? מפתחות לא תקינות? כרטיס אשראי פג תוקפו?

האם אתה מגדיר את ה-S3 כבר זמן מה?

before upgrade to the newest version there are no any issue.

I checked B2 that I did not meet any cap

x-amz-checksum-crc32 is not supported by b2. I guess this the reason

נסה להוסיף ל-ENV שלך

AWS_REQUEST_CHECKSUM_CALCULATION: WHEN_REQUIRED
AWS_RESPONSE_CHECKSUM_VALIDATION: WHEN_REQUIRED
2 לייקים

שלום, זה עדיין נותן לי שגיאה

env:
  DISCOURSE_ENABLE_CORS: true
  AWS_REQUEST_CHECKSUM_CALCULATION: WHEN_REQUIRED
  AWS_RESPONSE_CHECKSUM_VALIDATION: WHEN_REQUIRED
  
  DISCOURSE_USE_S3: true
rake נעצר!
Aws::S3::Errors::InvalidArgument: הוחלט על כותרת לא נתמכת 'x-amz-checksum-crc32' שהתקבלה לפעולת API זו. (Aws::S3::Errors::InvalidArgument)
נכשל
--------------------
Pups::ExecError: cd /var/www/discourse && sudo -E -u discourse bundle exec rake s3:expire_missing_assets נכשל עם סטטוס יציאה #Process::Status: pid 2900 exit 1
מיקום הכישלון: /usr/local/lib/ruby/gems/3.3.0/gems/pups-1.2.1/lib/pups/exec_command.rb:132:in `spawn'
ההרצה נכשלה עם הפרמטרים {"cd"=>"$home", "cmd"=>["sudo -E -u discourse bundle exec rake s3:upload_assets", "sudo -E -u discourse bundle exec rake s3:expire_missing_assets"]}
האימות נכשל עם קוד יציאה 1
**כישלון באתחול** אנא גלול למעלה וחפש את הודעות השגיאה הקודמות, אולי יש יותר מאחת.
ה-discord-doctor יכול לעזור באבחון הבעיה.
לייק 1

[ציטוט=“Yt.w, שליחה: 12, נושא: 354217”]
Pups::ExecError: cd /var/www/discourse && sudo -E -u discourse bundle exec rake s3:expire_missing_assets נכשלה עם תוצאת ריצה #lexit 1
[/ציטוט]

מדווח שה- AWS SDK לא מכבד את ההגדרות הסביבתיות ל-DELETE, לכן עליך להסיר את השורה

- sudo -E -u discourse bundle exec rake s3:expire_missing_assets

לעת עתה.

3 לייקים

So should someone update the b2 section of Configure an S3 compatible object storage provider for uploads?

לייק 1

After confirming it works? Definitely.

Also, it will affect most providers, so most clones will need adjustments.

2 לייקים

Thank you, I will try in the maintenance time,
does delete
- sudo -E -u discourse bundle exec rake s3:expire_missing_assets
give any side effect?

Yes, assets won’t be removed from the bucket anymore.

לייק 1

So if I don’t remove assets manually, in theory, it will expand infinitely?

Yes, that is exactly what is going to happen.

לייק 1

It doesn’t sound like a super critical issue, but is there any way to fix it?
There wasn’t any issue in the previous version, right?