4D v14

Using a 64-bit 4D Server (Windows)

Home

 
4D v14
Using a 64-bit 4D Server (Windows)

Using a 64-bit 4D Server (Windows)  


 

 

Beginning with version 12, 4D Server supports Windows 64-bit operating systems. The main advantage of 64-bit technology is the fact that more RAM memory can be addressed.

This section covers the particularities concerning the implementation and use of the 64-bit version of 4D Server.

A 64-bit 4D Server requires a Windows 64-bit operating system. Please refer to the certification matrices available on the 4D Web site to know which Windows operating systems are compatible with respect to your 4D Server release.

The 4D Server.exe application intended for 64-bit architectures is a specific version, dedicated to this environment. It will not run on a 32-bit system. 

Conversely, if you launch the standard 4DServer.exe (32 bits) on a Windows 64-bit system, it will run, but in emulation mode.
On the client side, any 4D machine (Mac OS or Windows) can connect to a 64-bit version of 4D Server. The 4D applications to be used are the standard 32-bit versions (see the diagram below).

In interpreted mode, the same 4D databases can be executed with a 64-bit 4D Server or a 32-bit 4D Server. Development is identical regardless of which application is used. 

In compiled mode, the databases must have been compiled for 64-bit processors in order to be executed with a 64-bit 4D Server (see the "64-bit compilation" paragraph).
A database that has been compiled in 32-bit only and that does not contain interpreted code cannot be executed with a 64-bit 4D Server. 

During execution, the following differences should be noted:

  • Only the plug-ins compiled specifically in 64-bit mode will be loaded by the 64-bit 4D Server. A 64-bit plug-in must be built as a folder and placed in the Plugins folder of the server (the former architecture based on the .4DX and .RSR files placed in the Win4DX folder is no longer supported). 32-bit plug-ins are not loaded by a 64-bit 4D Server. They can however be stored in the Plugins folder of the server and distributed on the remote machines, without initialization. Mechanisms that call the server (for example, writing or reading templates on the server via the WR SET AREA PROPERTY command of 4D Write) will not function.
    The .4DX file for 32 bits must be placed in a subfolder named /Contents/Windows and the file for 64 bits must be placed in a subfolder named /Contents/Windows64.
  • The compiled 4D components used with a 64-bit 4D Server must have been compiled in 64 bits.
  • The amount of memory that can be used for the BLOBs loaded by the application remains limited to 2 GB.
  • QuickTime is not supported by a 64-bit 4D Server.
    Generally, we do not recommend working with pictures in PICT format: if the picture is 100% Quickdraw, it can be handled by a 64-bit version of 4D Server, but if it contains Quicktime, it cannot be loaded.

To be able to use 4D Internet Commands with a 64-bit 4D Server, you must install version 12.1 (minimum) of this plug in.

You can download the version 12.1 of 4D Internet Commands from the 4D Web site.

4D v12 applications can now be compiled for 32-bit and 64-bit processors. To do this, a new Also compile for 64-bit processors option is available on the "Compiler" page of the Database settings: 

When this option is checked, the compiler includes the 64-bit code and the 32-bit code in the .4DC and .4DB files. These files can then be run with either a 32-bit or a 64-bit 4D Server. By default, this option is not checked.

Note: In order to compile a 64-bit version of the database, it must be operating in Unicode mode. Otherwise, an error is generated during compilation.

Since 64-bit architectures allow up to 1 TB (1000 GB) of RAM memory to be addressed, the cache memory that can be allocated to the 64-bit 4D Server is virtually unlimited. 

Note: By comparison, 32-bit architectures are limited to 4 GB of RAM.

If the quantity of cache specified on the "Database/Memory" page of the database Settings cannot be obtained, 4D Server allocates the largest size possible and informs the user on startup of the application. It is then possible to quit or continue with the size offered.

During execution, you can distinguish between the 64-bit 4D Server application and the standard 4D Server application via a logo that appears on the Monitor page of the server administration window:

Note: This logo also appears in the About 4D Server window.

The following 4D language commands have been adapted to the new capacities of the 64-bit 4D Server: Version type, SET DATABASE PARAMETER and Get database parameter. For more information, refer to the descriptions of these commands.

The process stack running on a 64-bit version of 4D Server requires more memory than on a 32-bit version (about twice as much). When you create a process on the server using the Execute on server or New process commands with a 64-bit version of 4D Server, we recommend that you pass a minimum value of 128,000 bytes in the stack parameter and increase it when handling a sizeable call chain or if you receive an "out of stack" error. Make sure that you check this parameter when your code is intended for execution on a 64-bit 4D Server.

In addition to standard commands that cannot be used on 4D Server (see Stored Procedures), the following commands cannot be executed on a 64-bit server. If they are called for example within a stored procedure, a warning dialog box appears and the error 67 is returned. This error can be intercepted by an error-handling method installed by the ON ERR CALL command. 

4D, Quick Report themeQR New offscreen area
4D Chart, CT Area themeCT New offscreen area

 
PROPERTIES 

Product: 4D
Theme: Using 4D Server

 
ARTICLE USAGE

4D Server Reference ( 4D v14)
4D Server Reference ( 4D v14 R2)
4D Server Reference ( 4D v14 R3)
4D Server Reference ( 4D Server v14 R4)