Nextcloud version (eg, 20.0.5): 28.0.1.1
Operating system and version (eg, Ubuntu 20.04): Debian 12.4.0 (VM on Proxmox)
nginx version (eg, Apache 2.4.25): 1.22.1-9
PHP version (eg, 7.4): 8.2+93+0~20231125.47
The issue you are facing:
When importing high resolution photos taken by Nikon Camera and edited with Photoshop I’m not able to get the EXIF Metadata.
I uploaded all the photos via scp to an folder in username/files/Photos/
I chown the folder as well as the files to www-data.
Then i ran
sudo -u www-data /usr/bin/php /opt/nextcloud/occ files:scan --path="username/files/Photos/myfolder"
and
sudo -u www-data /usr/bin/php /opt/nextcloud/occ files:scan --path="username/files/Photos/myfolder" --generate-metadata
This command throws an error for each file:
Error during scan: exif_read_data(): Incorrect APP1 Exif Identifier Code
and ends with:
+---------+-------+-----+---------+---------+--------+--------------+
| Folders | Files | New | Updated | Removed | Errors | Elapsed time |
+---------+-------+-----+---------+---------+--------+--------------+
| 1 | 409 | 0 | 0 | 0 | 409 | 00:00:16 |
+---------+-------+-----+---------+---------+--------+--------------+
I was easily able to use exiftool to verify, that the metadata is actually fine. But occ wont recognize and always throws this error.
Without the metadata properly set in Nextcloud, the pictures are not shown on the map nor are they sorted properly in the timeline. Any help would be appreciated.
Is this the first time you’ve seen this error? (Y/N): Y
Steps to replicate it:
- see above
The output of your config.php file in /path/to/nextcloud
(make sure you remove any identifiable information!):
<?php
$CONFIG = array (
'passwordsalt' => 'frischesmeersalz',
'secret' => 'asecret',
'trusted_domains' =>
array (
0 => 'my.private.domain'
),
'datadirectory' => '/var/ncdata',
'dbtype' => 'mysql',
'version' => '28.0.1.1',
'overwrite.cli.url' => 'https://my.private.domain',
'dbname' => 'nextcloud',
'dbhost' => '127.0.0.1',
'dbport' => '',
'dbtableprefix' => 'oc_',
'mysql.utf8mb4' => true,
'dbuser' => 'auser',
'dbpassword' => 'safepassword',
'installed' => true,
'instanceid' => 'anID',
'default_phone_region' => 'DE',
'memcache.local' => '\\OC\\Memcache\\APCu',
'open_basedir' => '/dev/urandom',
'updater.release.channel' => 'production',
'redis' =>
array (
'host' => '/var/run/redis/redis.sock',
'port' => '0',
),
'memcache.locking' => '\\OC\\Memcache\\Redis',
'app_install_overwrite' =>
array (
0 => 'memories',
1 => 'bookmarks_fulltextsearch',
2 => 'files_fulltextsearch_tesseract',
),
'memories.exiftool' => '/opt/nextcloud/apps/memories/bin-ext/exiftool-amd64-glibc',
'memories.vod.path' => '/opt/nextcloud/apps/memories/bin-ext/go-vod-amd64',
'enabledPreviewProviders' =>
array (
0 => 'OC\\Preview\\Image',
1 => 'OC\\Preview\\HEIC',
2 => 'OC\\Preview\\TIFF',
3 => 'OC\\Preview\\Movie',
),
'preview_max_x' => 2048,
'preview_max_y' => 2048,
'memories.gis_type' => 1,
)