Giter VIP home page Giter VIP logo

docs's Introduction

Dokumentationen diverser Konfigurationen

This is my own documentation site

1. Wordpress

1.1. Wordpress Datenbank

Datenbank liegt in /config ab, dieses Verezeichnig ist nach db_data gemounted. Der Ordner db_restore für das zurücksichern eines SQL Dumps gedacht:

Um die Datenbank zu restaurieren genügt folgender Befehl:
mysql -u <user> -p <dbname> < /config/initdb.d/wordpress.sql

1.2. Wordpress Debugging

in wp-config.php folgendes hinterlegen

define('WP_DEBUG', true);
define('WP_DEBUG_LOG', true);
define('WP_DEBUG_DISPLAY', false);
@ini_set('display_errors',0);

2. Ecodms

2.1. Ecodms Backup

Im Backup Verzeichnis reicht es eine create Datei anzulegen. Dies wird von ecodms erkannt und anschließend ein Backup erstellt. siehe script "/opt/docker/duplicati/bin/ecodmsbackup"

Duplicati startet vor dem Backup das script und wartet auf einen exitcode 0

ecodms Backup script
#!/bin/bash

# This file will trigger ecodms to create a new backup
#touch /opt/docker/ecodms/ecoDMS/backup/create
BACKUP_PATH=/source/ecodms

touch ${BACKUP_PATH}/create

MAX_RUNTIME=$((SECONDS+3600))

while [ -f ${BACKUP_PATH}/create ]
do
      sleep 31
      if [ $SECONDS -gt $MAX_RUNTIME ]; then
              exit 1
      fi
done

echo "Backup seems to be started. create file is deleted"

while : ; do
  FILENAME=`ls -rt ${BACKUP_PATH}/*.zip | tail -n1`
  SIZE1=`stat -c%s "$FILENAME"`
  sleep 11
  SIZE2=`stat -c%s "$FILENAME"`

  if [ "$SIZE1" -eq "$SIZE2" ]; then
    echo "no file size change detected anymore, starting copy job"
    break
  fi

  if [ $SECONDS -gt $MAX_RUNTIME ]; then
    exit 1
  fi
done

#cp "$FILENAME" /mnt/fritznas/ASMedia-asm1153e-01/backup/ecodms/backup.zip
#mv -T "$FILENAME" /mnt/fritznas/ASMedia-asm1153e-01/backup/ecodms/backup.zip

# keep three youngest files and delete rest of them
ls -1tr ${BACKUP_PATH} | head -n -3 | xargs -d '\n'  rm -f --

exit 0

3. Linux LVM

3.1. Informationen zu den Volumes abrufen

sudo lvdisplay

3.2. Logisches Volume vergrößern

3.2.1. Backup Volume vergrößern

sudo lvextend --resizefs -L +10G /dev/data-vg/backup-lv # Größe um 10G erweitern
Führt zu folgender Ausgabe
Size of logical volume data-vg/backup-lv changed from 600.00 GiB (153600 extents) to 610.00 GiB (156160 extents).
Logical volume data-vg/backup-lv successfully resized.
resize2fs 1.45.5 (07-Jan-2020)
Filesystem at /dev/mapper/data--vg-backup--lv is mounted on /srv/backup; on-line resizing required
old_desc_blocks = 75, new_desc_blocks = 77
The filesystem on /dev/mapper/data--vg-backup--lv is now 159907840 (4k) blocks long.

docs's People

Contributors

sidey79 avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.