Developpez.com - 4D
X

Choisissez d'abord la catégorieensuite la rubrique :


Create a backup of your 4D database on a network device without opening a session

Date de publication : 18/05/2006 , Date de mise à jour : 07/11/2007

Par Stéphanie Tirtiat (translation FR -> EN) (Intl Tech Support)
 Cédric Gareau (Technicien Support Technique)
 Tony Ebollo (Technicien Support Technique)
 

This tech tip will help you to mount automatically a network device with no need to log in on the server machine, to backup your 4D database.

I. REQUIREMENTS
II. INSTALLATION
Step 1 : download the tools
Step 2 : create the backup folder
Step 3 : create a user
Step 4 : access and security rights on the folder.
Step 5 : modify the file "map.aut" in the unzipped folder.
Step 6 : mount the device manually
Step 7 : register the 4D database as a service
Step 8 : configure the backup
Step 9 : modify the file "Autoexnt.bat" in the unzipped folder.
Step 10 : execute the file "INSTALLER.BAT".
III. DESINSTALLATION
Step 1 : download the tools
Step 2 : execute the file "SUPPRIMER.BAT" ("supprimer" in French is "delete" in English)
Step 3 : Unregister the 4D database as service
IV. DOWNLOAD


I. REQUIREMENTS

This Tech Tip can be done only on Windows machines.

All the steps must be done on the machine hosting the 4D Server, except the following steps:

   - create a user (to be done on the domain server) ;

   - create the shared folder (can be anywhere on the network).


The example has been done on a Windows XP SP2 machine owned by a domain.

You need to have some knowledges about the network stuff to be able to:

   - create a user account for the domain

   - share a folder and modify the access and security rights.

info The article is organized by steps. The order of these steps must be conscientiously respected.
warning It is recommanded to flllow the steps with the help of your system administrator.
If you can't follow a step, don't go further!


II. INSTALLATION


Step 1 : download the tools

Download the zip file named "Backup4D":

Backup4D

1 - unzip the Backup4D.zip file in the "C:\" folder.


Step 2 : create the backup folder

2 - Create and share a folder on a machine permanently reachable on the network. We'll name this folder as "Backup" (for our example).



Step 3 : create a user

3 - create a user on the domain by checking the 2 following options :

   - the user can not change the password.

   - the password never expires.


The other options must be unchecked.


In this example :

   - the user is "CGareau".

   - his password is "backup".

   - the user domain is "4DFR".

   - the server machine name is "Serveur4D".


For security reasons, it is recommanded to give no rights to this user and to not use this user for other actions.


Step 4 : access and security rights on the folder.

4 - allow only this user to access the network folder.


5 - give permissions for the user on the folder.


6 - restart the server


Step 5 : modify the file "map.aut" in the unzipped folder.

7 - edit the file "map.aut" in the folder c:\Backup4D\ with a simple text editor like Notepad and replace the following fields :

This step is very important. Replace ONLY the following fields and keep the spaces before and after if they exist.

   - serveur : machine name hosting the 4D Server

   - nom_du_partage : shared network folder on the machine where the backup files will be stored

   - nom_utilisateur : user name of the user created in the previous step

   - nom_du_domaine : user domain name

   - mot_de_passe : user password



In our example the command line would be:

run, \C:\\WINDOWS\\system32\\cmd.exe /C "NET USE Z: \\\\Serveur4D\\Backup /USER:CGareau@4DFR backup /PERSISTENT:NO"


8 - save the file "map.aut" and quit the text editor


Step 6 : mount the device manually

9 - To verify that the network device is correctly connected on the next boot, mount the network device manually.

To do it:

   - open the file explorer

   - click on "connect a network device" (presumed translation from a french system interface)

   - fill in the field "Device" and "Folder" like in the screenshots



   - click on "connect with an other user name".

   - fill in the fields "user name" and "password"



   - click on "OK" then "Finish"

10 - Vérifier que vous avez accès au lecteur monté Z: et que vous possédez bien les droits de création et de modification sur ce lecteur.


Step 7 : register the 4D database as a service

11 - open the database with 4D Server

12 - go to the File menu then click on "register as Service".




Step 8 : configure the backup

13 - Go into the menu "Edition" and click on the "Préférences". Then on "Configuration" for the "Backup" panel.

(Preferences\Backup\Configuration)


14 - click on in the "Backup file destination folder".

15 - select the network device/folder you have mounted previously (Z:\).

16 - In "Scheduler", set up the frequency of the backup.

17 - Quit 4D Server.


Step 9 : modify the file "Autoexnt.bat" in the unzipped folder.

18 - edit the file "Autoexnt.bat" with a text editor and modify the field "nom_de_votre_base" (in english: name_of_your_database) with the name of your 4D database.

19 - Save the file "Autoexnt.bat" and quit the text editor.


Step 10 : execute the file "INSTALLER.BAT".

20 - double-click on "INSTALLER.BAT".

21 - delete the folder "c:\Backup4D".

22 - restart the server machine. All is in place.


III. DESINSTALLATION

If you would like to uninstall what has been installed with this tech tip, please follow the procedure:


Step 1 : download the tools

Download the zip file "Backup4D":

Backup4D

1 - Unzip the file "Backup4D.zip" on local "C:\".


Step 2 : execute the file "SUPPRIMER.BAT" ("supprimer" in French is "delete" in English)

2 - Double-click on "SUPPRIMER.BAT".

3 - Delete the folder "c:\Backup4D".


Step 3 : Unregister the 4D database as service

4 - Open the database with 4D Server

5 - Go to the File menu and click on "Unregister all the server as services".




IV. DOWNLOAD

Download the Tech Tips in PDF format:

Tech Tips



Valid XHTML 1.1!Valid CSS!

Copyright © 2006 4D s.a.. Aucune reproduction, même partielle, ne peut être faite de ce site et de l'ensemble de son contenu : textes, documents, images, etc. sans l'autorisation expresse de l'auteur. Sinon vous encourez selon la loi jusqu'à trois ans de prison et jusqu'à 300 000 € de dommages et intérêts.

Contacter le responsable de la rubrique 4D