Unable to login to new Friendica instance

What type of hardware are you using: Virtual machine
What YunoHost version are you running: 12.0.14
What app is this about: Friendica

Describe your issue

I installed a new instance of Friendica on a subdomain.
All is good and the application loads.

In the app details it says I can login using my domain email address and my Yunohost password.

However, this doesn’t work and I am told “Login failed. Please check your credentials”

I tried forgotten password, but then I’m told the account doesn’t exist.

Please could someone advise potential next steps.

Share relevant logs or error messages

No log required

Actually installation log would be helpful here. Can you share it from WebAdmin->Tools->Logs?

Link to log: https://paste.yunohost.org/raw/ciqotonoyu

Please let me know if you need anything more. Thank you.

The install logs look mostly OK, nothing of note there.

Indeed this did not work for me as well (just tried fresh install), something went wrong again :frowning:

Will need more investigation…

@Doony @orhtej2

This is a well-known bug that the installation script has been carrying around for well over a year. I don’t know why it hasn’t been fixed yet.

The problem: The installation script has apparently not initialised the database and has not created the files. This is why the daemon crashes (the return value 255 originates from the crashing script under bin/daemon.php

My workaround:

  1. Access the server via SSH

  2. Switch to the Friendica environment with sudo yunohost app shell friendica

  3. bin/console dbstructure update creates the database structure

Unfortunately, the user specified in the YunoHost installation is not available in the DB, which is why this user is also created on the console:

  1. bin/console user add <username> <nickname> <mail-address> <language-code> where the mail address must be the one selected for the admin at YunoHost

  2. Set password with bin/console user password <password>

You can then log in to the web as this user and have admin rights.

1 Like

Because no one proposed a solution like you just did.
All the steps you detailed above can be easily added to the install script.

Thank you. I will give that a try and report back

As I said, this is an old bug. There are already two (still open) issues in the YH Friendica repository:

Install fails to initialize the database

New install won’t allow log in

And there are also threads (both closed) here in the forum:

[Friendica] Logging in as admin after new installation

Friendica - Login failed. Please check your credentials

So I poked around some more and it’s POST_INSTALL.md that’s wrong.
You can log in with your normal YNH user (not user@domain.tld as docs claim), the first attempt will fail for some reason, but the second attempt will just bring you to the timeline.