... sorry Zeile 25 :0)

-----Ursprüngliche Nachricht-----
Von: linuxmuster-user [mailto:[email protected]] 
Im Auftrag von Maurice Cazautet
Gesendet: Freitag, 26. August 2016 14:09
An: Discussions about using linuxmuster.net 
<[email protected]>
Betreff: Re: [lmn] XEN automat.Backup auf Festplatte

Hi Stefan,

ersetze mal bitte bei dir in der backup.sh die Zeile 12:

Von:
if [[ -z "$1" ]]

Druch:
if [[ -z "$ExportPath" ]]

VG,

Maurice

-----Ursprüngliche Nachricht-----
Von: linuxmuster-user [mailto:[email protected]] 
Im Auftrag von Stefan Senft
Gesendet: Freitag, 26. August 2016 13:57
An: Discussions about using linuxmuster.net 
<[email protected]>
Betreff: Re: [lmn] XEN automat.Backup auf Festplatte

Hallo Maurice,

hier die 2 Outputs:

[root@xen ~]#  /usr/share/netzint/tools/test.sh
ExportPath: /mnt/xenbkp/

[root@xen ~]# file -i /usr/share/netzint/etc/main.cfg
/usr/share/netzint/etc/main.cfg: text/plain; charset=us-ascii

Danke fürs Helfen
Stefan

Maurice Cazautet <[email protected]> schrieb am Thu, 25 Aug 2016 
21:02:49 +0000:
> .. und bitte noch ein "file -i main.cfg" ausführen und posten.
> 
> -----Ursprüngliche Nachricht-----
> Von: linuxmuster-user
>[mailto:[email protected]] Im Auftrag von 
>Maurice Cazautet
> Gesendet: Donnerstag, 25. August 2016 22:59
> An: Discussions about using linuxmuster.net 
><[email protected]>
> Betreff: Re: [lmn] XEN automat.Backup auf Festplatte
> 
> ..komisch das ganze.
> 
> Kopier mal bitte die test.sh im Anhang nach /usr/share/netzint/tools/ 
>und mach sie mit chmd +x test.sh ausführbar.
> 
> Bitte den output Posten. 
> 
> VG
> 
> 
> -----Ursprüngliche Nachricht-----
> Von: linuxmuster-user
>[mailto:[email protected]] Im Auftrag von 
>Senft, Stefan
> Gesendet: Donnerstag, 25. August 2016 22:46
> An: Discussions about using linuxmuster.net 
><[email protected]>
> Betreff: Re: [lmn] XEN automat.Backup auf Festplatte
> 
> Hier meine main.cfg: /usr/share/netzint/etc/main.cfg
> 
> ################################################################
> #          Backup Parameter#
> ################################################################
> 
> ExportPath="/mnt/xenbkp"
> Email="[email protected]"
> Subject="XEN-Backup"
> Tag="ni-backup"
> Compress="true" # true|false
> 
> 
> Gruß
> Stefan
> 
> Am 25.08.2016 22:10, schrieb Maurice Cazautet:
>> Hi Stefan,
>>
>> bei dir findet das Skript die Variable "ExportPath" nicht bzw. denkt 
>>diese ist leer.
>>
>> Kannst du mir noch die main.cfg zukommen lassen? Diese sollte in
>>v6.1 unter /usr/share/netzint/etc/main.cfg liegen.
>>
>> VG,
>>
>> Maurice
>>
>> -----Ursprüngliche Nachricht-----
>> Von: linuxmuster-user
>> [mailto:[email protected]] Im Auftrag 
>>von  Stefan Senft
>> Gesendet: Donnerstag, 25. August 2016 18:28
>> An: Discussions about using
>> linuxmuster.net<[email protected]>
>> Betreff: Re: [lmn] XEN automat.Backup auf Festplatte
>>
>> Hallo Maurice,
>>
>> es hat etwas gedauert: Leider hatte ich ein anderes, dringenderes 
>>Problem, welches wieder behoben ist:
>>
>> Ich habe das Backup-Skript laufen lassen um den LMN-Server zu sichern 
>>und recht viele Fehler bekommen, die ich nicht einschätzen konnte.
>> Daher habe ich den LMN-Server heruntergefahren und dann das 
>>Backup-Skript laufen lassen:
>>
>> [root@xen ~]# /usr/share/netzint/tools/backup.sh
>> Starting to backup...
>> VM list: 00e74f9e-e469-642d-ee56-c19af2703f34
>> 812c2df6-acc8-eb1c-72c3-4b9b4713e58f
>> a0bbb0be-5789-f2d0-009c-dd9ea9b0fff5
>> ExportPath: /var/run/sr-mount//
>> Error code: VM_IS_SNAPSHOT
>> Error parameters: 812c2df6-acc8-eb1c-72c3-4b9b4713e58f
>> (lmn61.ipfire_backup_2016-08-23_15-34-41), snapshot failed to 
>>snapshot  VM uuid = 812c2df6-acc8-eb1c-72c3-4b9b4713e58f
>> Error code: VM_IS_SNAPSHOT
>> Error parameters: a0bbb0be-5789-f2d0-009c-dd9ea9b0fff5
>> (lmn61.ipfire_backup_2016-08-23_15-35-33), snapshot failed to 
>>snapshot  VM uuid = a0bbb0be-5789-f2d0-009c-dd9ea9b0fff5
>> Start backup lmn61.server_backup_2016-08-25_16-45-26 ...
>> The server failed to handle your request, due to an internal error. 
>>The given message may give details useful for debugging the problem.
>> message: Failure("Compression via zcat failed: exit code 1") 
>>Successfully backup lmn61.server_backup_2016-08-25_16-45-26 to 
>>/var/run/sr-mount// Done!
>>
>> Danach lies sich der LMN-Server nicht mehr starten von der 
>>XenCenter-Konsole. Über die XenServer-Oberfläche bekam ich 
>>Grub-Fehlermeldungen beim Versuch den LMN-Server zu starten.
>>
>> Ein Zurücksetzen auf einen früheren Snapshot (den nach dem ersten 
>>erfolglosen Versuch das lvhome zu vergrößern, brachte den LMN-Server 
>>wieder zum Laufen!
>>
>> Zwei Meldungen sind mir danach beim Herunterfahren des LMN-Servers 
>>aufgefallen, aber die sind ja vielleicht auch normal?
>> rm: cannot remove /var/run - read only filesystem:
>> ln: cannot remove /var/run - read only filesystem:
>>
>> Das verzeichnis der Backups unter /var/run/st-mounts ist allerdings 
>>auf dem LMN-Server nicht vorhanden, so dass ich nicht davon ausgehe, 
>>dass es etwas mit XEN-Backups zu tun hat.
>>
>> Hier nun das Gewünschte:
>>
>> [root@xen ~]# xe sr-list
>> uuid ( RO)                : 91272d73-03d3-b6d6-1b6a-999abdf8c3da
>>            name-label ( RW): XenServer Tools
>>      name-description ( RW): XenServer Tools ISOs
>>                  host ( RO): xen
>>                  type ( RO): iso
>>          content-type ( RO): iso
>>
>> uuid ( RO)                : b7055725-a9d5-ef88-935e-7fe1b363a4b3
>>            name-label ( RW): DVD drives
>>      name-description ( RW): Physical DVD drives
>>                  host ( RO): xen
>>                  type ( RO): udev
>>          content-type ( RO): iso
>>
>> uuid ( RO)                : e5ba05ed-ced1-13a4-d33b-b7fd006fb99e
>>            name-label ( RW): Removable storage
>>      name-description ( RW):
>>                  host ( RO): xen
>>                  type ( RO): udev
>>          content-type ( RO): disk
>>
>> uuid ( RO)                : 6954080a-7619-6bb7-d8d2-45248400ad99
>>            name-label ( RW): Local storage
>>      name-description ( RW):
>>                  host ( RO): xen
>>                  type ( RO): ext
>>          content-type ( RO): user
>>
>> Gruß
>> Stefan
>>
>> Maurice Cazautet<[email protected]>  schrieb am Thu, 25 Aug
>>2016 15:15:29 +0000:
>>> Hi Stefan,
>>>
>>> da sollte noch alles gehen, der Fehler hat sich bei mir in 6.2 
>>> eingeschlichen.
>>>
>>> Sende mir mal (am besten in einer Datei) den Inhalt von "xe sr-list"
>>> auf dem XenServer.
>>>
>>> VG,
>>>
>>> Maurice Cazautet
>>> Netzint OHG | IT Consultant
>>>
>>> Office: +49 7723 8739750-2
>>> Web: www.netzint.de
>>> Mail: [email protected]
>>> Address: Netzint OHG, Kreuzstr. 4-6, 78148 Gütenbach, Germany
>>>
>>> Geschäftsführer/Managing Directors: Maurice Cazautet, Kai Wursthorn
>>> | Firmensitz/Head Office: Gütenbach | Amtsgericht/Local Court:
>>> Freiburg i. Br. | Handelsregister/Commercial Register: HRA 703557 
>>>Diese E-Mail könnte vertrauliche und/oder rechtlich geschützte 
>>>Informationen enthalten. Wenn Sie nicht der richtige Adressat sind 
>>>oder die E-Mail irrtümlich erhalten haben, informieren Sie bitte 
>>>sofort den Absender und vernichten Sie diese E-Mail. Das unerlaubte 
>>>Kopieren sowie die unbefugte Weitergabe dieser E-Mail ist nicht 
>>>gestattet.
>>> This e-mail may contain confidential and/or privileged information.
>>> If you are not the intended recipient (or have received this e-mail 
>>>in
>>> error) please notify the sender immediately and destroy this e-mail.
>>> Any unauthorised copying, disclosure or distribution of the material 
>>>in this e-mail is strictly forbidden.
>>>
>>>
>>>
>>>
>>> -----Ursprüngliche Nachricht-----
>>> Von: linuxmuster-user
>>> [mailto:[email protected]] Im Auftrag 
>>> von Stefan Senft
>>> Gesendet: Donnerstag, 25. August 2016 16:36
>>> An: Discussions about using linuxmuster.net
>>> Betreff: Re: [lmn] XEN automat.Backup auf Festplatte
>>>
>>> Hallo Maurice,
>>>
>>>> Es geht um das "/etc/main.cfg " am Ende.
>>> ich verwende noch LMN6.1 und das "/etc/main.cfg" ist im Skript 
>>> vorhanden. Habe daher erst mal nix verändert.
>>>
>>> Hier das Skript (Anfang):
>>> /usr/share/netzint/tools/backup.sh
>>>
>>> #!/bin/bash
>>> PATH=/bin:/usr/bin:/sbin:/usr/sbin:/usr/local/bin
>>> # NetzInt XenServer-Backup for linuxmuster.net 6.1x # # 
>>> [email protected] # 04.01.2015 # GPL V3 # v0.2.2 # read 
>>> configfiles . /usr/share/netzint/etc/main.cfg || exit 1 #
>>>
>>> ################################################################
>>> VMs=$(xe vm-list tags:contains=$Tag | grep uuid| awk '{print $5}') 
>>>date=$(date +%Y-%m-%d_%H-%M-%S) vm_array=(${VMs//,/ })
>>> ret_code=0
>>> snapshot_uuid_array=
>>> snapshot_name_array=
>>> backup_ext=".xva"
>>> echo "Starting to backup..." | tee -a /tmp/$date.log echo "VM list:
>>> ${vm_array[@]}" | tee -a /tmp/$date.log if [[ -z "$1" ]] then 
>>>ExportPath="/var/run/sr-mount/$(xe sr-list name-label=BackupSto$ else 
>>>ExportPath="$ExportPath/"
>>> fi
>>> ...
>>>
>>> Hier meine main.cfg: /usr/share/netzint/etc/main.cfg
>>>
>>> ################################################################
>>> #          Backup Parameter#
>>> ################################################################
>>>
>>> ExportPath="/mnt/xenbkp"
>>> Email="[email protected]"
>>> Subject="XEN-Backup"
>>> Tag="ni-backup"
>>> Compress="true" # true|false
>>>
>>> Gruß
>>> Stefan
>>>
>>> Maurice Cazautet<[email protected]>  schrieb am Wed, 24 
>>>Aug
>>> 2016 06:12:44 +0000:
>>>> Hi Stefan,
>>>>
>>>> es gibt aber da glaube ich noch ein Copy&Paste Fehler von mir in 
>>>> der backup.sh. So müssen die ersten Zeilen aussehen:
>>>>
>>>> #!/bin/bash
>>>> PATH=/bin:/usr/bin:/sbin:/usr/sbin:/usr/local/bin
>>>> # XenServer-Backup for linuxmuster.net 6.2x # # 
>>>> [email protected] # 27.04.2016 # GPL V3 # v0.3.0 # read 
>>>> configfiles locationOfScript=$(dirname "$(readlink -e "$0")") cd 
>>>> $locationOfScript . ../etc/main.cfg || exit 1
>>>>
>>>>
>>>> Es geht um das "/etc/main.cfg " am Ende.
>>>>
>>>> VG,
>>>>
>>>> Maurice
>>>>
>>>> -----Ursprüngliche Nachricht-----
>>>> Von: linuxmuster-user
>>>> [mailto:[email protected]] Im Auftrag 
>>>> von Stefan Senft
>>>> Gesendet: Dienstag, 23. August 2016 15:44
>>>> An: Discussions about using linuxmuster.net
>>>> Betreff: Re: [lmn] XEN automat.Backup auf Festplatte
>>>>
>>>> Hallo Maurice,
>>>>
>>>> habe nun auf Xen in der main.cfg:
>>>> ExportPath="/mnt/xenbkp"
>>>>
>>>> und die Festplatte ist auch auf /mnt/xenbkp gemountet.
>>>>
>>>> Wenn ich ein Backup starte wird es aber gespeichert nach 
>>>> /var/run/sr-mount und nicht auf die USB-Festplatte.
>>>>
>>>> Was habe ich übersehen?
>>>>
>>>> Gruß
>>>> Stefan
>>>>
>>>> Maurice Cazautet<[email protected]>  schrieb am Mon, 22 
>>>> Aug
>>>> 2016 13:15:20 +0000:
>>>>> Hi Stefan,
>>>>>
>>>>> ja genau.
>>>>>
>>>>> VG
>>>>>
>>>>> -----Ursprüngliche Nachricht-----
>>>>> Von: linuxmuster-user
>>>>> [mailto:[email protected]] Im Auftrag 
>>>>> von Senft, Stefan
>>>>> Gesendet: Montag, 22. August 2016 10:44
>>>>> An: Discussions about using linuxmuster.net
>>>>> Betreff: Re: [lmn] XEN automat.Backup auf Festplatte
>>>>>
>>>>> Hallo Maurice,
>>>>>
>>>>> wenn ich also die Festplatte gemountet habe und den Eintrag in der 
>>>>> main.cfg gemacht und die Tags bei den VMs gesetzt habe, brauche 
>>>>> ich nichts weiter zu tun (also kein NewSR, wie bei dem Beispiel 
>>>>> mit der NAS)?
>>>>>
>>>>> Gruß
>>>>> Stefan
>>>>>
>>>>> Am 22.08.2016 09:54, schrieb Maurice Cazautet:
>>>>>> Hi,
>>>>>>
>>>>>> du kannst in der main.cfg den Mount-Pfad zu deiner USB-HDD 
>>>>>> einfach
>>>>>> eingeben:
>>>>>>
>>>>>> ################################################################
>>>>>> #          Backup Parameter                                    # 
>>>>>> ################################################################
>>>>>> ExportPath="/mnt/xenbkp " # Example /mnt/UsbHdd
>>>>>>
>>>>>> In der 6.1 bzw. XenServer 6.5 Appliance habe ich noch kein 
>>>>>> Feature eingebaut welches die Kapazität prüft oder alte Backups löscht.
>>>>>> Das muss also selbst vorgenommen werden.
>>>>>>
>>>>>> Vg,
>>>>>>
>>>>>> Maurice Cazautet
>>>>>>
>>>>>>
>>>>>> -----Ursprüngliche Nachricht-----
>>>>>> Von: linuxmuster-user
>>>>>> [mailto:[email protected]] Im 
>>>>>> Auftrag von  Senft, Stefan
>>>>>> Gesendet: Freitag, 19. August 2016 15:27
>>>>>> An: Discussions about using linuxmuster.net
>>>>>> Betreff: [lmn] XEN automat.Backup auf Festplatte
>>>>>>
>>>>>> Hallo,
>>>>>>
>>>>>> ich arbeite mit LMN6.1 unter XEN6.5 nach Anleitung 
>>>>>> "Installationsanleitung XenAppliance V0.2.2".
>>>>>>
>>>>>> Konfiguration automatisches Backup
>>>>>> S.55 "Tragen Sie den Pfad zur Freigabe ein, welchen Sie verwenden 
>>>>>> wollen..."
>>>>>> Wie lautet der dann, wenn ich eine Festplatte unter unter 
>>>>>> /mnt/xenbkp am XEN habe - 10.16.1.10:/mnt/xenbkp ?
>>>>>>
>>>>>> Automatische Backups
>>>>>> S.58
>>>>>> Wie automatisch ist denn das Backup?
>>>>>> Wird geprüft, ob genügend Speicherplatz vorhanden ist für den 
>>>>>> Snapshot und alte Snapshots dann bei Speicherbedarf gelöscht - 
>>>>>> oder müsste ich dafür noch ein weiteres Skript her?
>>>>>>
>>>>>> MfG
>>>>>> Stefan
>>>>>>
>>>>>> _______________________________________________
>>>>>> linuxmuster-user mailing list
>>>>>> [email protected]
>>>>>> https://mail.lehrerpost.de/mailman/listinfo/linuxmuster-user
>>>>>> _______________________________________________
>>>>>> linuxmuster-user mailing list
>>>>>> [email protected]
>>>>>> https://mail.lehrerpost.de/mailman/listinfo/linuxmuster-user
>>>>> _______________________________________________
>>>>> linuxmuster-user mailing list
>>>>> [email protected]
>>>>> https://mail.lehrerpost.de/mailman/listinfo/linuxmuster-user
>>>>> _______________________________________________
>>>>> linuxmuster-user mailing list
>>>>> [email protected]
>>>>> https://mail.lehrerpost.de/mailman/listinfo/linuxmuster-user
>>>> _______________________________________________
>>>> linuxmuster-user mailing list
>>>> [email protected]
>>>> https://mail.lehrerpost.de/mailman/listinfo/linuxmuster-user
>>>> _______________________________________________
>>>> linuxmuster-user mailing list
>>>> [email protected]
>>>> https://mail.lehrerpost.de/mailman/listinfo/linuxmuster-user
>>> _______________________________________________
>>> linuxmuster-user mailing list
>>> [email protected]
>>> https://mail.lehrerpost.de/mailman/listinfo/linuxmuster-user
>>> _______________________________________________
>>> linuxmuster-user mailing list
>>> [email protected]
>>> https://mail.lehrerpost.de/mailman/listinfo/linuxmuster-user
>> _______________________________________________
>> linuxmuster-user mailing list
>> [email protected]
>> https://mail.lehrerpost.de/mailman/listinfo/linuxmuster-user
>> _______________________________________________
>> linuxmuster-user mailing list
>> [email protected]
>> https://mail.lehrerpost.de/mailman/listinfo/linuxmuster-user
> 
> _______________________________________________
> linuxmuster-user mailing list
> [email protected]
> https://mail.lehrerpost.de/mailman/listinfo/linuxmuster-user
> _______________________________________________
> linuxmuster-user mailing list
> [email protected]
> https://mail.lehrerpost.de/mailman/listinfo/linuxmuster-user

_______________________________________________
linuxmuster-user mailing list
[email protected]
https://mail.lehrerpost.de/mailman/listinfo/linuxmuster-user
_______________________________________________
linuxmuster-user mailing list
[email protected]
https://mail.lehrerpost.de/mailman/listinfo/linuxmuster-user
_______________________________________________
linuxmuster-user mailing list
[email protected]
https://mail.lehrerpost.de/mailman/listinfo/linuxmuster-user

Antwort per Email an