Récupérer BDD Kanboard sans SSH ni Webadmin / Recover bdd Kanboard without SSH acces and Webadmin

:uk:/:us:

My YunoHost server

Hardware: VPS bought online / Old laptop or computer / Raspberry Pi (specify version, 0 to 4) at home / Internet Cube with VPN / Other ARM board / …
YunoHost version: 4.3.6.3
I have access to my server : Secure Console
Are you in a special context or did you perform some particular tweaking on your YunoHost instance ? : yes
If yes, please explain: Any SSH Acces and any operation possible from Webadmin

Description of my issue

I posted yesterday a problem on my test server. Of course this one is not saved, because I just test the applications before installing them on a production instance.

Only I have on my test instance a kanboard that I would like to get back.

I tried several things like re-importing a pre update backup that I got from the test instance. But of course it is empty, no project.

I have access to the disk partitions, so to the /var/www/kanboard folder and the mysql /var/lib/mysql folder.

Do you know a way to recover the Kanboard database and to be able to remount the services on another server?

Translated with DeepL Translate: The world's most accurate translator (free version)


:fr:

Mon serveur YunoHost

Matériel: VPS acheté en ligne
Version de YunoHost: 4.3.6.3
J’ai accès à mon serveur : Par console de secours
Êtes-vous dans un contexte particulier ou avez-vous effectué des modificiations particulières sur votre instance ? : oui
Si oui, expliquer: Plus d’acces SSH, aucune operation possible depuis la WebAdmin

Description du problème

J’ai posté, hier un problème sur mon serveur de test. Forcement celui-ci n’est pas sauvegardé, car je teste juste les applications avant de les installer sur une instance de prod.

Seulement j’ai sur mon instance de test un kanboard que j’imerais recuperer.

J’ai essayé plusieurs choses comme réimporter une sauvegarde de pre update que j’ai récupéré de l’instance de test. Mais forcement elle est vide, aucun projet.

J’ai acces aux partitions du disque, donc au dossier /var/www/kanboard et au dossier mysql /var/lib/mysql.

Connaissez-vous un moyen de recupêrer la base Kanboard et de pouvoir remonter le services sur un autre serveur ?

Here is what I believe to be the relevant part in Kanboard doc : MySQL/MariaDB — Kanboard documentation

I would try to install a fresh copy of Kanboard, change the config.php file to have the good database password, drop the relevant mysql database created by your fresh install, rebuild it using your saved sql file, restart the kanboard service… To maximize chances for it to work, I would install using an old commit from GitHub - YunoHost-Apps/kanboard_ynh: Kanboard package for YunoHost to make sure that both Kanboard versions match (if not you may have some database migration issues… )

:fr:
Bonjour et merci pour l’aide,
Pour répondre la première demande, je ne peux pas saisir de commande mysql car je passe par une console de secours et j’ai donc seulement accès au fichier brut sur les disques dur (je n’ai plus accès au SSH voir ici, bien sûr il y a un moyen de reprendre l’accès SSH je suis preneur)

Pour votre deuxième proposition, voici ce que j’ai déjà essayé :

  • Restaurer un backup pre update de Kanboard,
    Remplacer le dossier www/kanborad par celui de l’ancien serveur,
  • Remplacement du dossier var/lib/mysql/kanboard par l’ancien,
  • essayé avec les deux mots de passe de la BDD

Sur le nouveau serveur, la connexion a la bdd mysql Kanboard et vide même après avoir remplacé le dossier par celui de l’ancien serveur.
Je trouve cela bizarre.

Dans le dossier var/lib/mysql est-ce qu’il y a des fichiers qui sont liés et que je dois absolument déplacer ? (autre que le dossier kanboard)

Encore merci

:uk: :us:

Hello and thanks for the help,
To answer the first request, I can’t enter mysql command because I use a backup console and I only have access to the raw file on the hard drives (I don’t have access to SSH anymore here, of course there is a way to resume SSH access I’m interested)

For your second proposal, here is what I already tried:

  • Restore a pre update backup of Kanboard,
    Replace the www/kanborad folder with the one from the old server,
  • Replaced the var/lib/mysql/kanboard folder with the old one,
  • tried with both DB passwords

On the new server, the connection to the mysql kanboard db is empty even after replacing the folder with the one from the old server.
I find this strange.

In the var/lib/mysql folder, are there any files that are linked that I absolutely have to move (other than the kanboard folder)

Thanks again

Translated with DeepL Translate: The world's most accurate translator (free version)

:fr:

Bonjour à tous,

Ben j’ai réussi à retrouver mes données de mon kanban.

Je mets les étapes ici au cas où.

J’utilise ServerOld et ServerNew, je pense que vous comprenez la signification hihihi.

Sur le ServerOld :

  • Récupérer le dossier /var/www/kanboard/data et le fichier /var/www/kanboard/config.php.
    Le dossier data contient tous les fichiers que vous avez ajoutés à votre ou vos projets et le fichier config.php est important, surtout pour le mot de passe de la base du ServerOld (en cas de besoin, car pas eu besoin pour ma part).
  • Récupérer le dossier /var/lib/mysql/kanboard et le fichier /var/lib/mysql/ibdata1

Maintenant passons sur votre nouveau serveur ServerNew.

  • Installer l’application Kanboard,
  • Transférer le dossier data (du ServerOld) dans le dossier /var/www/kanboard/ du ServerNew.
  • Si vous avez fait des modifs sur config.php, il faut les appliquer sur le nouveau MAIS sans changer le mot de passe d’accès à la base de donnée.
  • Rendez-vous dans /var/lib/mysql puis faites une copie du dossier kanboard,
  • Transférer le dossier /var/lib/mysql/kanboard sur le ServeurNew
  • Supprimer les fichiers ib*,
  • Transférer l’ancien fichier ibdata1 dans /var/lib/mysql/` du ServerNew.

Redémarrer votre instance et vous devriez avoir récupéré votre ou vos projets.

Un simple redémarrage de mysql n’a pas suffit pour moi.

Merci à vous.

:uk: :us:

Hello everyone,

Well I managed to find my data from my kanban.

I put the steps here just in case.

I use ServerOld and ServerNew, I think you understand the meaning hihihi.

On ServerOld:

  • Retrieve the /var/www/kanboard/data folder and the /var/www/kanboard/config.php file.
    The data folder contains all the files you have added to your project(s) and the config.php file is important, especially for the password of the ServerOld database (in case of need, as I didn’t need it).
  • Get the /var/lib/mysql/kanboard folder and the /var/lib/mysql/ibdata1 file

Now let’s move to your new ServerNew server.

  • Install the Kanboard application,
  • Transfer the data folder (from the ServerOld) to the /var/www/kanboard/ folder on the ServerNew.
  • If you have made changes to config.php, you must apply them to the new one BUT without changing the database access password.
  • Go to /var/lib/mysql and make a copy of the kanboard folder,
  • Transfer the /var/lib/mysql/kanboard folder to the NewServer
  • Delete the ib* files,
  • Transfer the old ibdata1 file to /var/lib/mysql/` on ServerNew.

Restart your instance and you should have your project(s) back.

A simple restart of mysql was not enough for me.

Thanks

Sources :

Well done and thanks for the tutorial, useful indeed.

1 Like

This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.