docker icon indicating copy to clipboard operation
docker copied to clipboard

recovering (articles) from a previous version

Open daviddoji opened this issue 5 years ago • 4 comments

As many, I had problems when upgrading from 2.3.8 to 2.4.1. After doing the migration manually with the following command: $ docker exec -t NAME_OR_ID_OF_YOUR_WALLABAG_CONTAINER /var/www/wallabag/bin/console doctrine:migrations:migrate --env=prod --no-interaction

I still could not get my docker instance of wallabag up and running. So I made a backup of the wallabag directory, and started from scratch. Doing so, I have now the last version running on a container, but obviously, no content.

As I still have the backup of the old instance, would it be possible to move the content to the new instance? If so, how could I do it?

Thanks in advance

daviddoji avatar Jan 10 '21 10:01 daviddoji

How did you perform the backup? What did you backup?

j0k3r avatar Jan 11 '21 08:01 j0k3r

Thanks for replying back @j0k3r .

I just, naively, moved the directory created by wallabag. When I instantiate newly the image, docker created a directory for the new instance of wallabag.

The structure of the old directory is this one:

  user@server:~/docker$ sudo tree wallabag_bck
  [sudo] password for user: 
  wallabag_bck
  └── data
      ├── aria_log.00000001
      ├── aria_log_control
      ├── bookstack
      │   └── db.opt
      ├── ib_buffer_pool
      ├── ib_logfile0
      ├── ib_logfile1
      ├── ibdata1
      ├── images
      ├── multi-master.info
      ├── mysql
      │   ├── column_stats.MYD
      │   ├── column_stats.MYI
      │   ├── column_stats.frm
      │   ├── columns_priv.MYD
      │   ├── columns_priv.MYI
      │   ├── columns_priv.frm
      │   ├── db.MYD
      │   ├── db.MYI
      │   ├── db.frm
      │   ├── event.MYD
      │   ├── event.MYI
      │   ├── event.frm
      │   ├── func.MYD
      │   ├── func.MYI
      │   ├── func.frm
      │   ├── general_log.CSM
      │   ├── general_log.CSV
      │   ├── general_log.frm
      │   ├── gtid_slave_pos.frm
      │   ├── gtid_slave_pos.ibd
      │   ├── help_category.MYD
      │   ├── help_category.MYI
      │   ├── help_category.frm
      │   ├── help_keyword.MYD
      │   ├── help_keyword.MYI
      │   ├── help_keyword.frm
      │   ├── help_relation.MYD
      │   ├── help_relation.MYI
      │   ├── help_relation.frm
      │   ├── help_topic.MYD
      │   ├── help_topic.MYI
      │   ├── help_topic.frm
      │   ├── host.MYD
      │   ├── host.MYI
      │   ├── host.frm
      │   ├── index_stats.MYD
      │   ├── index_stats.MYI
      │   ├── index_stats.frm
      │   ├── innodb_index_stats.frm
      │   ├── innodb_index_stats.ibd
      │   ├── innodb_table_stats.frm
      │   ├── innodb_table_stats.ibd
      │   ├── plugin.MYD
      │   ├── plugin.MYI
      │   ├── plugin.frm
      │   ├── proc.MYD
      │   ├── proc.MYI
      │   ├── proc.frm
      │   ├── procs_priv.MYD
      │   ├── procs_priv.MYI
      │   ├── procs_priv.frm
      │   ├── proxies_priv.MYD
      │   ├── proxies_priv.MYI
      │   ├── proxies_priv.frm
      │   ├── roles_mapping.MYD
      │   ├── roles_mapping.MYI
      │   ├── roles_mapping.frm
      │   ├── servers.MYD
      │   ├── servers.MYI
      │   ├── servers.frm
      │   ├── slow_log.CSM
      │   ├── slow_log.CSV
      │   ├── slow_log.frm
      │   ├── table_stats.MYD
      │   ├── table_stats.MYI
      │   ├── table_stats.frm
      │   ├── tables_priv.MYD
      │   ├── tables_priv.MYI
      │   ├── tables_priv.frm
      │   ├── time_zone.MYD
      │   ├── time_zone.MYI
      │   ├── time_zone.frm
      │   ├── time_zone_leap_second.MYD
      │   ├── time_zone_leap_second.MYI
      │   ├── time_zone_leap_second.frm
      │   ├── time_zone_name.MYD
      │   ├── time_zone_name.MYI
      │   ├── time_zone_name.frm
      │   ├── time_zone_transition.MYD
      │   ├── time_zone_transition.MYI
      │   ├── time_zone_transition.frm
      │   ├── time_zone_transition_type.MYD
      │   ├── time_zone_transition_type.MYI
      │   ├── time_zone_transition_type.frm
      │   ├── transaction_registry.frm
      │   ├── transaction_registry.ibd
      │   ├── user.MYD
      │   ├── user.MYI
      │   └── user.frm
      ├── performance_schema
      │   └── db.opt
      └── wallabag
          ├── db.opt
          ├── migration_versions.frm
          ├── migration_versions.ibd
          ├── wallabag_annotation.frm
          ├── wallabag_annotation.ibd
          ├── wallabag_config.frm
          ├── wallabag_config.ibd
          ├── wallabag_craue_config_setting.frm
          ├── wallabag_craue_config_setting.ibd
          ├── wallabag_entry.frm
          ├── wallabag_entry.ibd
          ├── wallabag_entry_tag.frm
          ├── wallabag_entry_tag.ibd
          ├── wallabag_oauth2_access_tokens.frm
          ├── wallabag_oauth2_access_tokens.ibd
          ├── wallabag_oauth2_auth_codes.frm
          ├── wallabag_oauth2_auth_codes.ibd
          ├── wallabag_oauth2_clients.frm
          ├── wallabag_oauth2_clients.ibd
          ├── wallabag_oauth2_refresh_tokens.frm
          ├── wallabag_oauth2_refresh_tokens.ibd
          ├── wallabag_site_credential.frm
          ├── wallabag_site_credential.ibd
          ├── wallabag_tag.frm
          ├── wallabag_tag.ibd
          ├── wallabag_tagging_rule.frm
          ├── wallabag_tagging_rule.ibd
          ├── wallabag_user.frm
          └── wallabag_user.ibd

daviddoji avatar Jan 11 '21 11:01 daviddoji

Oh I see. It'll be a bit complex to export your article from the previous database because the best way is to export them from wallabag or create a sql dump. Maybe just replace wallabag entry related tables (wallabag_entry, wallabag_entry_tag & wallabag_tag) to the new docker?

j0k3r avatar Jan 11 '21 11:01 j0k3r

Did the replacement but it didn't work :( Anyway, thanks for the suggestion

daviddoji avatar Jan 11 '21 19:01 daviddoji