Greg Rundlett
https://eQuality-Tech.com
https://freephile.org
On Tue, Aug 2, 2016 at 10:49 PM, Jingyi C. Shi <jshizhang(a)gmail.com> wrote:
Hi all,
Thanks to some help about my previous thumbnails question: "I uploaded a
png image but no thumbnails created in the File page."
I have tried several methods but the thumbnails are still not working. I
still face the problems that I have neither thumbnails or preview images in
'File:' pages.
I have already installed ImageMagick in my Ubuntu.
What I have tried was to:
1. check wiki/images/thumb/ folder, but only old thumbnails are there.
(Yes, I used to have thumbnails several month ago.) No new ones that I
uploaded recently are there.
2. chowe -R root:root wiki/images/ and chmod -R 777 /wiki/images/
Actually, the images directory (and subdirectories) should be owned by the
web server user (that's *www-data* for Ubuntu)
If you enter the command
ps aux | egrep '(apache|httpd)'
and look at the first column, you'll be able to confirm that your webserver
is running as www-data
Then you can change ownership on the directory and subdirectories like so:
sudo chown -R www-data:www-data ./wiki/images
In general, you should setup a debug log file[1] to find out what's going
wrong with MediaWiki.
[1]
https://www.mediawiki.org/wiki/Manual:How_to_debug#Setting_up_a_debug_log_f…
2. change memory consumption by increasing
$wgMaxShellMemory to 409600 in
LocalSetting.php, but still no thumbnails appears.
So here are my new questions:
1. Small images (like 500kb) can sometimes have previews (but no
thumbnails). But large images always no previews. How to fix?
2. I have a strange finding. Some jpg images can show the previews in my
home computer but cannot show previews in my office computer. What may
cause that?
3. My current MW version is 1.26. And my PHP version is a little bit out of
date: 5.3.10. May this cause a problem related to previews and thumbnails?
I'm not sure what you mean by 'previews'. When you upload a file into
MediaWiki via Special:Upload, it simply stores the file on the webserver
and generates thumbnails as configured. Those thumbnails get stored in the
"thumbs" directory on the server. When you go to *Special:ListFiles* (e.g.
https://freephile.org/wiki/Special:ListFiles), it will show a list of
uploaded files, with a thumbnail representation of each file.
Since you are having problems with your file uploads and thumbnail
generation, you should probably run the 'rebuildImages' script in the
maintenance folder.
cd wiki/maintenance
php ./rebuildImages --dry-run
php ./rebuildImages --missing