Ah… merci pour l’explication concernant la place @ljf
En fait je ne m’étais pas trompé de sauvegarde : apparemment le pb viendrait du fait qu’une partie des données sont dans Onlyoffice.
As-tu des idées sur comment je peux restaurer correctement Onlyoffice et Nextcloud ?
(Nextcloud, c’est bon, mais Onlyoffice, ça plante. Est-ce le manque de SWAP ?)
I don’t know anything about Onlyoffice, but read this:
No idea what portal files are It is a reply to someone not wanting Onlyoffice to save data ‘locally’, but everything in a ‘cloud’. If there are no adaptions by the Yunohost-team, then I would check /var/www/onlyoffice/Data
on VPS1.
I think so; with SWAP, Linux can put a brake on memory usage when SWAP is being used; without SWAP, there seems to be no safeguard and the process is killed when more than available RAM is claimed.
On my (small) VPS (1G RAM) I made a swap file because processes randomly crashed,
$ sudo fallocate -l 512M /swapfile && chmod 600 /swapfile && mkswap /swapfile && swapon /swapfile
and add it to fstab,
# cat /etc/fstab |grep swap
/swapfile none swap sw 0 0
The crashes don’t appear anymore. A separate partition would be better, but this was easier on the installed and running server.
thks @wbk
I have 2 questions in ordre to understand how to create the swap:
• is there a place to type fallocate? directly on /home ?
• how do I add it to fstab ? Is there a config file to edit?
No problem (of course!)
Easiest is maybe
sudo cp /etc/fstab /etc/fstab.org
sudo echo '/swapfile none swap sw 0 0' >> /etc/fstab
Pay attention to the double >>
, to add it to the file (instead of overwrite the contents).
After that compare the result with the original
$ sudo cat /etc/fstab.old
...
$ sudo cat /etc/fstab
There should be a bunch of lines identical, and at the bottom of the second there should be the new line
Hum…
I got :
chmod: changing permissions of ‘/swapfile’: Operation not permitted
and:
sudo echo ‘/swapfile none swap sw 0 0’ >> /etc/fstab
-bash: /etc/fstab: Permission denied
hm, strange. What do you get when you run
$ mount
There should be a list with all mounted (virtual) filesystems. Look for a line that has .... on / type ... (rw...)
or .... on /etc/ type .... (rw ...)
The line for me looks like
/dev/vda1 on / type ext4 (rw,relatime)
In your case, is it rw
or r
(read only)?
Everything looks ok:
sda1 on / type ext4 (rw,realtime,errors=remount -ro)
I read a post by someone who was unable to change a file as root, there the solution was
I would suspect that that is not the case, because you just created /swapfile ; you could install Yunohost (and run updates), so a totally read only filesystem seems not the case for sure.
I don’t know when errors=remount -ro
comes into effect: if ‘out of memory’ is enough of an error, than the filesystem might be read only. Can you make other changes to files in / or /etc ?
Is it an option to reboot the server, and try again?
I highly doubt that this has anything to do with swap …
The restore log from onlyoffice is pretty clear :
WARNING - Nov 07 19:35:22 nginx[23982]: nginx: [emerg] open() "/etc/nginx/includes/ds-example.conf" failed (2: No such file or directory) in /etc/nginx/conf.d/ds.conf:7
This is related to the fact that onlyoffice (or rather document server .deb package) was written with the gentlesness of a catapult, and devs thought it’s a good idea to inject some nginx conf file during the .deb installation, and perform an nginx restart
For some reason, and according to @adepetigny, this works during a fresh install, but not during the restore of the app (despite the .deb being in both case the same)
Don’t know why that’s happening, but those were my conclusions so far
Thks for your feedbacks @wbk and @Aleks
after restarting the server I got the same denied to create the line in the fstab
If the the swap is not the problem, I’m wondering what are my options now in order to mount my backups…
Again with my lack of familiarity with Onlyoffice in mind, could this be an option:
- “Fresh” install of Onlyoffice on VPS-B
- Extract data from the backup, or copy directly from VPS-A
- “Handily connect the databases” on VPS-A and VPS-B, and copy ownership data from one to the other
Especially the last step seems daunting at various levels.
I do understand the process but I don’t have the knowledge to do it
Alternatively, I was wondering if there was a way to correct the .deb package in order to make it right.
After discussing with @adepetigny, we think missing data could be in /var/lib/onlyoffice/documentserver/App_Data/cache/files/ . If needed, we will try to find a solution for restoring onlyoffice by avoiding this issue:
It seems /var/lib/onlyoffice/documentserver/App_Data/cache/files/
is not included in the backup archive created by YNST, therefore, we haven’t been able to recover the lost data.
In order to avoid this pb to occure in the future I suggest to include these data in the backup.
This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.