librephotos
librephotos copied to clipboard
Cannot use librephotos on an external usb drive on Raspberry pi.
What Operating system and version is LibrePhotos running on:
Freshly installed Ubuntu server 22.04
What architecture is LibrePhotos running on:
ARM
How is LibrePhotos installed:
Docker
How is you picture library mounted on the host (or in the virtual machine):
This is a usb drive connected directly to the machine.
Description of issue:
- On a freshly installed raspberry pi 4 machine, with librephotos installed via docker. The default configuration works perfectly (not chaning anything in the
.env
file. - The externald drive is mounted in
/media/BIG
using this line in my/etc/fstab
file
UUID=ad5d7eba-2deb-4142-84b0-d5d658838e77 /media/BIG ext4 defaults 0 0
- After updating the env file I stopped the librephotos using
suso docker-compose down
andsudo docker-compose up -d
- Now, when I try to log in I get an error:
No connection to backend server, try again in a few minutes.
-
The lines in my
.env
file read# Location of your photos. myPhotos=/media/BIG/librephotos/pictures # Internal data of LibrePhotos data=/media/BIG/librephotos/data
-
and my foder structre is:
ubuntu@ubuntu:/media/BIG/librephotos$ ls -la total 20 drwxr-xr-x 5 root root 4096 May 5 14:51 . drwxr-xr-x 5 root root 4096 May 4 18:00 .. drwxr-xr-x 8 998 999 4096 May 4 19:11 data drwxr-xr-x 2 998 999 4096 Apr 30 18:27 photos drwxr-xr-x 2 root root 4096 May 5 14:51 pictures
I've tried this several times. With trying to configure the .env
file before or after the initial setup and with/without including usernamd and password configuration in the .env
file
Em qual sistema operacional e versão o LibrePhotos está sendo executado:
Servidor Ubuntu recém-instalado 22.04
Em qual arquitetura o LibrePhotos está sendo executado:
BRAÇO
Como o LibrePhotos é instalado:
Janela de encaixe
Como sua biblioteca de imagens está montada no host (ou na máquina virtual):
Esta é uma unidade usb conectada diretamente à máquina.
Descrição do problema:
- Em uma máquina raspberry pi 4 recém-instalada, com librephotos instalado via docker. A configuração padrão funciona perfeitamente (não alterando nada no
.env
arquivo.- A unidade externa é montada
/media/BIG
usando esta linha no meu/etc/fstab
arquivoUUID=ad5d7eba-2deb-4142-84b0-d5d658838e77 /media/BIG ext4 defaults 0 0
- Depois de atualizar o arquivo env, parei o librephotos usando
suso docker-compose down
esudo docker-compose up -d
- Agora, quando tento fazer login, recebo um erro:
Sem conexão com o servidor back-end, tente novamente em alguns minutos.
- As linhas no meu
.env
arquivo lêem# Location of your photos. myPhotos=/media/BIG/librephotos/pictures # Internal data of LibrePhotos data=/media/BIG/librephotos/data
- e minha estrutura foder é:
ubuntu@ubuntu:/media/BIG/librephotos$ ls -la total 20 drwxr-xr-x 5 root root 4096 May 5 14:51 . drwxr-xr-x 5 root root 4096 May 4 18:00 .. drwxr-xr-x 8 998 999 4096 May 4 19:11 data drwxr-xr-x 2 998 999 4096 Apr 30 18:27 photos drwxr-xr-x 2 root root 4096 May 5 14:51 pictures
Eu tentei isso várias vezes. Ao tentar configurar o
.env
arquivo antes ou depois da configuração inicial e com/sem incluir a configuração de nome de usuário e senha no.env
arquivo
The same problem happened to me. The solution was to change the data folder to another place like /home or change the permissions of your hd to the owner and root group and
Hi, your message was cut in the middle, can you please add what I should do in addition?
I tried to make the owner of the /media/BIG/librephotos
folder either ubuntu:ubuntu
or root:root
(using chown -R
) and change the running permission to 750
(using chmod -R 750
). If I transfer the data
folder to the sd card (32GB) will I have enough room for the DB? I intend to also host a nextcloud server on that machine if that matter.
Thanks for your help
Olá, sua mensagem foi cortada no meio, você pode adicionar o que devo fazer além disso?
Tentei tornar o proprietário da
/media/BIG/librephotos
pastaubuntu:ubuntu
ouroot:root
(usandochown -R
) e alterei a permissão de execução para750
(usandochmod -R 750
). Se eu transferir adata
pasta para o cartão SD (32GB) terei espaço suficiente para o DB? Pretendo também hospedar um servidor nextcloud nessa máquina, se for o caso.Obrigado pela ajuda
I will give you 2 options
-
If possible, instead of a 32Gb SD card, add a 64GB or larger one, which would allow Nextcloud and the data folder on the SD and the files on the external HD
-
format your external hd in ext4 and mount it normally and then you pass the folders and see if it works
SOME TIPS
Install Nextcloud first first put your photos inside nextcloud and then install Librephotos and point the images folder to the path /path/to/Nextcloud/data/files
Hi, my external drive is formated in ext4. What do you mean by "mount it normally"?
I'll look into sd cards prices. It might be that the simplest solution will be to buy a large capacity one and use this drive for backup.
Oi, meu disco externo está formatado em ext4. O que você quer dizer com "montar normalmente"?
Vou olhar para os preços dos cartões SD. Pode ser que a solução mais simples seja comprar um de grande capacidade e usar esse drive para backup.
Here's my fstab example
/dev/disk/by-id/wwn-0x5000c500b67a3636-part1 /mnt/Backup auto nosuid,nodev,nofail,noauto,x-gvfs-show 0 0
Example of My Folder Permissions
edson@edson-OptiPlex-3070:/mnt/Backup/librephotos$ ls -la
total 20
drwxrwxrwx 5 edson edson 4096 mai 6 09:02 .
drwxrwxrwx 9 edson edson 4096 mai 5 10:54 ..
drwxr-xr-x 6 root root 4096 mai 6 09:03 data
drwxrwxrwx 6 edson edson 4096 mai 4 00:29 data1
drwxrwxrwx 4 edson edson 4096 mai 5 12:53 pictures
In the above case the folder I'm using as a /data
folder and /data1.
As mentioned above you can put the data folder inside the ssd that is the system my database after scanning 40,000 images got a total of 8GB.
Oi, meu disco externo está formatado em ext4. O que você quer dizer com "montar normalmente"?
Vou olhar para os preços dos cartões SD. Pode ser que a solução mais simples seja comprar um de grande capacidade e usar esse drive para backup.
hi did you manage to solve the problem
Hi, sorry. I was on vacation in the past two weeks. I'm back home now, and I'm giving this another go.
It's worked from,PI 4B,Docker, 2 usb hdds plugin. boot from usb hdd.
use default lang(en), when i click 'photos' all pic display,but use chinese, it display : 加载中... (loading...) when add or delete pic.
Oi, meu disco externo está formatado em ext4. O que você quer dizer com "montar normalmente"? Vou olhar para os preços dos cartões SD. Pode ser que a solução mais simples seja comprar um de grande capacidade e usar esse drive para backup.
hi did you manage to solve the problem
Hi, I've tried this now. Librephotos was installed via docker and nextcloud was installed via snap. Both live on the same r-pi machine and seem to work in more or less default settings (only exception is the use of external drive for both apps). However, the librephotos app cannot see the nextcloud folders. I'm not sure why.
When I go in the librephotos page to the library section, I see a nextcloud login box and I put the relevatn info - 127.0.0.1 for the ip address, and my username and password. Sometimes I can click the "not set" button and sometimes not after I clicked it, I selected the photos folder, but no photo was imported.
Oi, meu disco externo está formatado em ext4. O que você quer dizer com "montar normalmente"? Vou olhar para os preços dos cartões SD. Pode ser que a solução mais simples seja comprar uma grande capacidade e usar esse drive para backup.
ola voce conseguiu resolver o problema
Olá, tentei isso agora. Librephotos foi instalado via docker e nextcloud foi instalado via snap. Ambos vivem na mesma máquina r-pi e parecem funcionar em configurações mais ou menos padrão (única exceção é o uso de unidade externa para ambos os aplicativos). No entanto, o aplicativo librephotos não pode ver as pastas nextcloud. Não tenho certeza por quê.
Quando vou na página librephotos para a seção da biblioteca, vejo uma caixa de login nextcloud e coloco as informações relevantes - 127.0.0.1 para o endereço IP e meu nome de usuário e senha. Às vezes eu posso clicar no botão "não definido" e às vezes não depois de clicar nele, selecionei a pasta de fotos, mas nenhuma foto foi importada.
A similar error occurred where unable to point nextcloud via webdav through librephotos settings,
First alternative
In your .env file, point the photos folder to the nextcloud directory. Usually /var/snap/nextcloud/data, unless you put the files on an external hard drive.
Second alternative
Put the photos in a certain folder where librephotos can access them and add them to external storage in nextcloud settings.
Hmm... I'm not sure that any of this will work for me. I want the server to be used also by my family, and not only me. So I need to set a separate photo folder for each user. This means that I cannot use the .env file configuration. About the second option, again, if I understand you correctly, you suggest that the librephotos/photos directory will be shared with nextcloud. But, again, I'm in a situation where one folder is used for several users.
Or maybe I missunderstood your idea.
BTW, my .env file shows this:
# Location of your photos.
myPhotos=/media/BIG/librephotos/pictures
# Internal data of LibrePhotos
data=./librephotos/data
But in librephotos, when I look at the folder to scan, I see only the /data folder. How do I add additional folders to it (if possible)?
Hmm... Eu não tenho certeza se isso vai funcionar para mim. Quero que o servidor seja usado também pela minha família, e não só por mim. Então eu preciso definir uma pasta de fotos separada para cada usuário. Isso significa que não posso usar a configuração do arquivo .env. Sobre a segunda opção, novamente, se entendi corretamente, você sugere que o diretório librephotos/photos seja compartilhado com nextcloud. Mas, novamente, estou em uma situação em que uma pasta é usada para vários usuários.
Ou talvez eu tenha entendido mal a sua ideia.
BTW, meu arquivo .env mostra isso:
# Location of your photos. myPhotos=/media/BIG/librephotos/pictures # Internal data of LibrePhotos data=./librephotos/data
Mas em librephotos, quando olho para a pasta para digitalizar, vejo apenas a pasta /data. Como adiciono pastas adicionais a ele (se possível)?
Also find this limitation of Librephotos where it only recognizes the data
folder if you prefer you can go to Admin Area
and then to the Skip patterns
option and there put the folders that are not for librephotos to scan
An example provides:
/Documents/,/Downloads/
Or if you prefer you can add this in your .env file
# Comma delimited list of patterns to ignore (e.g. "@eaDir,#recycle" for synology devices)
skipPatterns=/Documents/,/Downloads/
On my server, Nextcloud installed via snap has 4 users and they access librephotos.
What did I do:
-
I created a folder outside the Nextcloud directory ./Nextcloud/data, it can be on the same HD.
-
I created four folders inside the Librephotos folder for each user
-
I went to my nextcloud instance in settings then in the left corner where there is a menu after the Administration option and at the bottom in External Storage and created the stores with the local option and pointing to the path /Librephotos/User1 /Librephotos/User2 /Librephotos/User3 /Librephotos/User4.
-
There is and when configuring External Storage don't forget to mention each user in the Available to column. Example:
Folder Name >> Photos
External Storage >> Local
Authentication >> None
Configuration >> /Librephotos/User1
Available for >> User1
In the example above, neither user will have access to the other's images.
- After configuring the Nextcloud Application on the snartphones, in the auto-send option, I directed the upload to be done in the Librephotos folder.
Hi,
I've followed your suggestions and things seem to work now. I'm left with two points though:
- How do I run automatic scanning? The instructions here don't work. I get a django warning:
django.core.exceptions.ImproperlyConfigured: The SECRET_KEY setting must not be empty.
- How do I delete users? Is it only via the SQL commands? I guess that if there is a django interfact I can use its admin?
Thanks a lot for all your help
Oi,
Eu segui suas sugestões e as coisas parecem funcionar agora. Mas fico com dois pontos:
- Como executo a verificação automática? As instruções aqui não funcionam. Eu recebo um aviso do django:
django.core.exceptions.ImproperlyConfigured: A configuração SECRET_KEY não deve estar vazia.
- Como faço para excluir usuários? É apenas através dos comandos SQL? Eu acho que se houver um interfact django eu posso usar seu admin?
Muito obrigado por toda sua ajuda
Hi, glad it's working.
When running the scan by the command informed I also got the same problem. My solution was to go to settings and then to the scan photos option and then it finds the new images for my user, in your case you have to do this procedure individually for each user.
As for user deletion I'm also interested I haven't found anything yet.