#124 From /public/avatar to /file/avatar: something keeps it from working

Kapalı
aab tarafından 4 yıl önce kere açıldı · 3 yorum
aab 4 yıl önce olarak yorumlandı

Since the last update in nightly, which changed /public/avatar to /file/avatar, i was getting a lot of these in the logs:

[error] 779#779: *482939 FastCGI sent in stderr: "PHP message: PHP Warning: rename(/tmp/listener_avatarhMZ0XD,/var/www/gnusocial/file/avatar/126463-original-20200407151424.jpeg): No existe el fichero o el directorio in /var/www/gnusocial/plugins/ActivityPub/lib/explorer.php on line 332PHP message: PHP Warning: chmod(): No existe el fichero o el directorio in /var/www/gnusocial/plugins/ActivityPub/lib/explorer.php on line 345" while reading response header from upstream, client: ip_address, server: gnusocial.net, request: "POST /user/2235/inbox.json HTTP/1.1", upstream: "fastcgi://unix:/run/php/php7.3-fpm.sock:", host: "gnusocial.net"

I followed several suggestions from diogo and someonewithpc:

  • The obvious, moving manually the directory: avatars were missing.
  • Checkin in admin's UI: settings are correct.
  • Checking with setconfig, which seems to be fine:

avatar server '' avatar dir '/var/www/gnusocial/file/avatar/' avatar url_base '/avatar/' avatar ssl NULL avatar maxsize 300 avatar path '/file/avatar/'

  • Checking db, which again, seems to be fine:
MariaDB [gnusocial]> select * from config where section = 'avatar';
+---------+---------+---------------------------------+
| section | setting | value                           |
+---------+---------+---------------------------------+
| avatar  | dir     | /var/www/gnusocial/file/avatar/ |
| avatar  | path    | /file/avatar/                   |
| avatar  | server  |                                 |
+---------+---------+---------------------------------+

I've managed to silence the logs soft-linking the locations (file/avatar -> /var/www/gnusocial/public/avatar/), but obviously, i'd like to fix this properly.

Do you know any other place where locations could be stored (with the wrong settings)?

Since the last update in nightly, which changed /public/avatar to /file/avatar, i was getting a lot of these in the logs: <code>[error] 779#779: *482939 FastCGI sent in stderr: "PHP message: PHP Warning: rename(/tmp/listener_avatarhMZ0XD,/var/www/gnusocial/file/avatar/126463-original-20200407151424.jpeg): No existe el fichero o el directorio in /var/www/gnusocial/plugins/ActivityPub/lib/explorer.php on line 332PHP message: PHP Warning: chmod(): No existe el fichero o el directorio in /var/www/gnusocial/plugins/ActivityPub/lib/explorer.php on line 345" while reading response header from upstream, client: ip_address, server: gnusocial.net, request: "POST /user/2235/inbox.json HTTP/1.1", upstream: "fastcgi://unix:/run/php/php7.3-fpm.sock:", host: "gnusocial.net"</code> I followed several suggestions from diogo and someonewithpc: - The obvious, moving manually the directory: avatars were missing. - Checkin in admin's UI: settings are correct. - Checking with setconfig, which seems to be fine: <code>avatar server '' avatar dir '/var/www/gnusocial/file/avatar/' avatar url_base '/avatar/' avatar ssl NULL avatar maxsize 300 avatar path '/file/avatar/'</code> - Checking db, which again, seems to be fine: ````sh MariaDB [gnusocial]> select * from config where section = 'avatar'; +---------+---------+---------------------------------+ | section | setting | value | +---------+---------+---------------------------------+ | avatar | dir | /var/www/gnusocial/file/avatar/ | | avatar | path | /file/avatar/ | | avatar | server | | +---------+---------+---------------------------------+ ```` I've managed to silence the logs soft-linking the locations (file/avatar -> /var/www/gnusocial/public/avatar/), but obviously, i'd like to fix this properly. Do you know any other place where locations could be stored (with the wrong settings)?
someonewithpc 4 yıl önce olarak yorumlandı
Katkıcı

Are the files actually missing? It seems you have avatar path set again, which last time fixed it. Try delete * from config where section = 'avatar'. I'll look more into this bug, clearly something is wrong

Are the files actually missing? It seems you have avatar path set again, which last time fixed it. Try `delete * from config where section = 'avatar'`. I'll look more into this bug, clearly something _is_ wrong
aab 4 yıl önce olarak yorumlandı
Poster

No, that error was showing every time an avatar was requested; they exist, just in the wrong place :) Now:

  • I've deleted the simlink and moved avatar inside file: all avatars missing in UI, as expected.
  • "delete * from config where section = 'avatar';" didn't work; "delete from config where section = 'avatar';" did. No avatar coincidences after this, as expected. Missing avatars in UI.
  • Moving avatar back to public brings avatars in UI again, and the error in logs as well.
  • Recreating the simlink makes the error in log dissapear.
  • Just in case, checked db and no avatar section exists.
No, that error was showing every time an avatar was requested; they exist, just in the wrong place :) Now: - I've deleted the simlink and moved avatar inside file: all avatars missing in UI, as expected. - "delete * from config where section = 'avatar';" didn't work; "delete from config where section = 'avatar';" did. No avatar coincidences after this, as expected. Missing avatars in UI. - Moving avatar back to public brings avatars in UI again, and the error in logs as well. - Recreating the simlink makes the error in log dissapear. - Just in case, checked db and no avatar section exists.
aab 4 yıl önce olarak yorumlandı
Poster

Ok, i was able to fix this eventually. Avatar is now inside of File, no simlink to Public needed. I just had to redo the steps some more times for it to work :) There are a lot of avatars missing anyway, i'm trying to recover them with "ActivityPub/scripts/update_activitypub_profiles.php -a" and "OStatus/scripts/update_ostatus_profiles.php -a". So, i think this bug is fixed, thanks!

Ok, i was able to fix this eventually. Avatar is now inside of File, no simlink to Public needed. I just had to redo the steps some more times for it to work :) There are a lot of avatars missing anyway, i'm trying to recover them with "ActivityPub/scripts/update_activitypub_profiles.php -a" and "OStatus/scripts/update_ostatus_profiles.php -a". So, i think this bug is fixed, thanks!
Giriş yap bu konuşmaya katılmak için.
Kilometre Taşı Yok
Atanan Kişi Yok
2 Katılımcı
Yükleniyor...
İptal
Kaydet
Henüz bir içerik yok.