Nethserver Zabbix / Dokuwiki backup / recovery issues

Hello everyone,

Following a recent post where I tried to resize (downsize) my Nethserver disk, without success, I am not forced to create a new server and migrate my services. Fortunately for me, I do not yet have many things to migrate. Zabbix is one of those services. I have done quite a a lot of work there and would like to keep it if I can.

From a bit of research I have done, Zabbix seems to be using a database and there are files located in /etc/zabbix. While backing up a database is not the end of the world and certainly a folder is very easy, I haven’t found anything else but also not sure if that would be the best approach to backing up Zabbix.

I was wondering if any of you had to go through that task and if they would mind sharing their procedure?

I’ve read in mrmarkuz installation guide, https://wiki.nethserver.org/doku.php?id=zabbix, that a config and data backup was all we needed. Just want to confirm that is the case? Basically, not sure what is included in that backup as there isn’t much details in the backup config except the time we want to execute it and where we want to drop the backup. Maybe it takes care of dokuwiki too? Not clear.

Thanks

Just do a data backup as it includes a config backup. This procedure backups zabbix and dokuwiki.

Yes, it is. The important config files are recreated by nethserver-zabbix, database and files are included in backup.

Yes, it does. Backup for Dokuwiki is working with nethserver-data-backup:

1 Like

Thanks @mrmarkuz !

1 Like

Hi @mrmarkuz,

I ran a backup and restored that in another Nethserver VM but Zabbix and Dokuwiki wasn’t part of the backup. Is there something I missed that I needed to do?

Basically I restored the configuration and then restored backups but no zabbix or dokuwiki

Source server :

Destination server :

So it seems it doesn’t know what paths were included in the backup? Is that normal? Should I specify those? I’m guessing the restore didn’t restore Zabbix and Dokuwiki and that I’ll have to install those manually before I can do a restore.

Are the stephdl and mrmarkuz repos in /etc/yum.repos.d/ ? If not, you may install them again.

Did you do a restore of the data backup?

Ahh yes the repos probably weren’t added… That is probably why the restore configuration wasn’t able to pull them in… I did do a data restore after but since there configuration restore was missing the repos then I think that was the problem. I’ll let you know as soon as I have the chance to work on this.

Thanks @mrmarkuz

1 Like

Encountered an issue while adding this repo :

Update : Issue fixed, I installed @mrmarkuz repository and I could install @stephdl repo. But I’m surprised it didn’t down the dependencies automatically.

Update 2: It appears I was missing a repo

I managed to get Zabbix up but Dokuwiki, for some reason doesn’t load. I noticed my active directory was recreated from my configuration restore which is as expected but the users didn’t follow. Not sure if this is why Dokuwiki is not working properly.

I think I know what went wrong. First time I’m doing a move from one server to another involving Zabbix and Dokuwiki. For those who this may help if you ever need to move to another server, for example, you realized you don’t need as much space as you originally allocated and want to shrink it down, your only option with XFS is to build a new machine. So I’ll build a guide for those who this may be useful…

1 Like

Is DokuWiki now working?

So far not much luck… I installed Nethserver fresh install… Then restored these repos :

  1. https://wiki.nethserver.org/doku.php?id=stephdl_repository
  2. https://wiki.nethserver.org/doku.php?id=mrmarkuz_repository

And then trying to do a config restore I get an error :

Perhaps I need to install Dokuwiki and Zabbix before I can do a config backup restore (not a data restore)?

I did test this particular config and it works… But if I install the repos before I get this error. Strange.

OK everything is backup and running.

If you need, for what ever reason to migrate your Nethserver to another instance, here is what you need to do and what worked for me.

  1. Backup your original server by doing a Configuration Backup and a Data Backup. Make sure you download your Configuration Backup. For the Data Backup, you will need a place to store it. In my case, I’m placing everything in my NAS.

  1. If you are running it in a hypervisor (something like proxmox), backup your Nethserver VM. Otherwise, if you are running bare metal, you could use Clonezilla to backup the disk where you installed Nethserver.
  2. Shutdown your Nethserver VM
  3. Install a fresh copy of Nethserver
  4. Once Nethserver is installed, you will need to define your FQDN, you can give it the same FQDN you had before, either way with the restore it will override it.
  5. Go to your terminal, run ‘yum update’
  6. If you have applications installed from other repos such as Dokuwiki and / or Zabbix, make sure you install them.
  7. In my case I had Dokuwiki and Zabbix installed and I needed to install the repo for Zabbix and on top of that install Dokuwiki and Zabbix as per the procedures available. Dokuwiki : https://wiki.nethserver.org/doku.php?id=module:dokuwiki, Zabbix : https://wiki.nethserver.org/doku.php?id=zabbix
  8. Then you can proceed to restore your saved Configuration Backup from step 1. This will temporarily disconnect you and will restore to your previously assigned IP address. It is possible you will need to clear your cookies in order to connect again (I had to).
  9. Restore your Data Backup.
  10. You are backup and running!

The only problem I’ve noticed is the following : Even if my certs were restored, I got an invalid certificate error from the browser. I had to reinstall my let’s encrypt certificates.

2 Likes

@tessierp, thank you for your resume of your “disaster recovery” :+1:
It is useful for other community members to find this thread. :grinning:

So like to ask you if you are willing to change the subject to something which covers the final content of content of this post. (and mark your own found solution of course :clap:)

Actually what I can do is a separate post where I will include these steps and refer to this older post if that is OK with you?

1 Like

Here is the link to the guide I just created : Guide / Steps to Disaster Recovery of Nethserver with a Dokuwiki and Zabbix installation

3 Likes

You may have a look at /var/log/messages to get more error details.
If it works, I’d just ignore the error.
Thanks for your guide.

Maybe it would have been enough to set the letsencrypt cert as default again.

To be very honest with you, I didn’t check that as I was in a rush before a meeting… But it could have been that. I had to download the acme.sh anyways that didn’t survive the backup so I would have had auto-renewal issues.

For those of you who wonder what I’m talking about, check this procedure : userguide:let_s_encrypt_for_internal_servers [NethServer Wiki]

1 Like