@joseph said in Cloudron backups with Hetzner storage box:
file name length limitations
Yes but that also happens with no encryption at all if you have deep structures in Nextcloud / Mail
@joseph said in Cloudron backups with Hetzner storage box:
file name length limitations
Yes but that also happens with no encryption at all if you have deep structures in Nextcloud / Mail
Problem with rsync / ext4 is the max 255 bytes name limitation that can conflict in Nextcloud with a deep folder depth also encryption not to mention which increases the char count of each file and folder.
The same goes for mails or anything where you can build deep structures with long strings.
@vadim thank you very much
@vadim Did you restart and check if the chats are there?
Please start from Zero with a new mattermost instance for migration.
The output of pgloader
indicated that while trying to migrate MySQL to the Postgres db and schema get renamed back and forth and now the tool can't work out what is correct.
What is your message supposed to say?
"No way" what? I am confused.
If you wait an hour, I am currently updating the doc.
I am creating a PR for the Mattermost App with this changed to be reflected in the /app/pkg/migration.load
The migration.load
should look like this:
LOAD DATABASE
FROM mysql://{{ mysql_user }}:{{ mysql_password }}@{{ mysql_address }}/{{ source_schema }}
INTO pgsql://{{ pg_user }}:{{ pg_password }}@{{ postgres_address }}/{{ target_schema }}
WITH data only,
workers = 8, concurrency = 1,
multiple readers per thread, rows per range = 10000,
prefetch rows = 10000, batch rows = 2500,
create no tables, create no indexes,
preserve index names
SET PostgreSQL PARAMETERS
maintenance_work_mem to '128MB',
work_mem to '12MB'
SET MySQL PARAMETERS
net_read_timeout = '120',
net_write_timeout = '120'
CAST column Channels.Type to "channel_type" drop typemod,
column Teams.Type to "team_type" drop typemod,
column UploadSessions.Type to "upload_session_type" drop typemod,
column ChannelBookmarks.Type to "channel_bookmark_type" drop typemod,
column Drafts.Priority to text,
type int when (= precision 11) to integer drop typemod,
type bigint when (= precision 20) to bigint drop typemod,
type text to varchar drop typemod,
type tinyint when (<= precision 4) to boolean using tinyint-to-boolean,
type json to jsonb drop typemod
EXCLUDING TABLE NAMES MATCHING ~<IR_>, ~<focalboard>, 'schema_migrations', 'db_migrations', 'db_lock',
'Configurations', 'ConfigurationFiles', 'db_config_migrations'
BEFORE LOAD DO
$$ ALTER SCHEMA public RENAME TO "{{ source_schema }}"; $$,
$$ TRUNCATE TABLE "{{ source_schema }}".systems; $$,
$$ DROP INDEX IF EXISTS "{{ source_schema }}".idx_posts_message_txt; $$,
$$ DROP INDEX IF EXISTS "{{ source_schema }}".idx_fileinfo_content_txt; $$
AFTER LOAD DO
$$ UPDATE "{{ source_schema }}".db_migrations set name='add_createat_to_teamembers' where version=92; $$,
$$ ALTER SCHEMA "{{ source_schema }}" RENAME TO public; $$,
$$ SELECT pg_catalog.set_config('search_path', '"$user", public', false); $$,
$$ ALTER USER {{ pg_user }} SET SEARCH_PATH TO 'public'; $$;
If you want to see the diff with the added "
more clearly https://www.diffchecker.com/Aac35QV0/
Upload this to /app/data/migration.load
and use this instead of the /app/pkg/migration.load
The context.ini
should have no quotes.
That is wrong. Give me a minute.
Put the "other errors" here as well so we can analyze them.
I had this exact issue yesterday!
@nebulon is right, if the mysql DB name is starting with a numeric char it needs to be in "
.
See:
BEFORE LOAD DO
$$ ALTER SCHEMA public RENAME TO "3761bb0f1936a4ee"; $$,
$$ TRUNCATE TABLE "3761bb0f1936a4ee".systems; $$,
$$ DROP INDEX IF EXISTS "3761bb0f1936a4ee".idx_posts_message_txt; $$,
$$ DROP INDEX IF EXISTS "3761bb0f1936a4ee".idx_fileinfo_content_txt; $$
AFTER LOAD DO
$$ UPDATE "3761bb0f1936a4ee".db_migrations set name='add_createat_to_teamembers' where version=92; $$,
$$ ALTER SCHEMA "3761bb0f1936a4ee" RENAME TO public; $$,
$$ SELECT pg_catalog.set_config('search_path', '"$user", "$user", public', false); $$,
$$ ALTER USER user0ed5bf57bd214c7b9319e5b6293a0d24 SET SEARCH_PATH TO '"$user", public'; $$;
I still did not finish the migration yesterday since there were more error, but the double quote is this error in particular.
Use the web terminal, and use unzip
?
Happens a LOT I don't mind at all.
There was a lingering "baserow" docker container which blocked the removal of the docker network.
Stopped that one, restarted box.service
now containers and services are reconfiguring.
Currently helping debugging.
Box log shows:
docker with args network rm -f cloudron errored Error: Command failed: docker network rm -f cloudron
Error response from daemon: error while removing network: network cloudron id e04d64250996ee86bf73ec329e512fbd34bd58bfe87bfadcfe3298c96967ff80 has active endpoints
at genericNodeError (node:internal/errors:984:15)
at wrappedFn (node:internal/errors:538:14)
at ChildProcess.exithandler (node:child_process:422:12)
at ChildProcess.emit (node:events:518:28)
at maybeClose (node:internal/child_process:1105:16)
at ChildProcess._handle.onexit (node:internal/child_process:305:5) {
code: 1,
killed: false,
signal: null,
cmd: 'docker network rm -f cloudron'
}
2024-09-17T18:09:16.371Z box:platform startInfra: Failed to start services. retry=false (attempt 0): createDockerNetwork errored with code 1 message Command failed: docker network rm -f cloudron
Error response from daemon: error while removing network: network cloudron id e04d64250996ee86bf73ec329e512fbd34bd58bfe87bfadcfe3298c96967ff80 has active endpoints
2024-09-17T18:09:16.371Z box:platform BoxError: createDockerNetwork errored with code 1 message Command failed: docker network rm -f cloudron
Error response from daemon: error while removing network: network cloudron id e04d64250996ee86bf73ec329e512fbd34bd58bfe87bfadcfe3298c96967ff80 has active endpoints
at /home/yellowtent/box/src/shell.js:38:23
at ChildProcess.exithandler (node:child_process:430:5)
at ChildProcess.emit (node:events:518:28)
at maybeClose (node:internal/child_process:1105:16)
at ChildProcess._handle.onexit (node:internal/child_process:305:5)
I like it
Backup, save backup config, restore from backup.
Done
Read the doc carefully: https://docs.cloudron.io/backups/#restore-cloudron
Did you use the Cloudron base image for your app (Maybe post your repository URL or the Dockerfile)? It reads like you did not, and that is why the Cloudron default tools are missing.