<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.open-xchange.com/wiki/index.php?action=history&amp;feed=atom&amp;title=Template%3AOXLoadBalancingClustering_Filestore</id>
	<title>Template:OXLoadBalancingClustering Filestore - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.open-xchange.com/wiki/index.php?action=history&amp;feed=atom&amp;title=Template%3AOXLoadBalancingClustering_Filestore"/>
	<link rel="alternate" type="text/html" href="https://wiki.open-xchange.com/wiki/index.php?title=Template:OXLoadBalancingClustering_Filestore&amp;action=history"/>
	<updated>2026-08-17T10:49:16Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.39.7</generator>
	<entry>
		<id>https://wiki.open-xchange.com/wiki/index.php?title=Template:OXLoadBalancingClustering_Filestore&amp;diff=6945&amp;oldid=prev</id>
		<title>Bartl3by: Created page with &quot;== Distributed file storage == The distributed file storage will be set up on the MySQL database master server. Of course it is possible to use a dedicated file server or an alre...&quot;</title>
		<link rel="alternate" type="text/html" href="https://wiki.open-xchange.com/wiki/index.php?title=Template:OXLoadBalancingClustering_Filestore&amp;diff=6945&amp;oldid=prev"/>
		<updated>2011-01-25T12:58:14Z</updated>

		<summary type="html">&lt;p&gt;Created page with &amp;quot;== Distributed file storage == The distributed file storage will be set up on the MySQL database master server. Of course it is possible to use a dedicated file server or an alre...&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;== Distributed file storage ==&lt;br /&gt;
The distributed file storage will be set up on the MySQL database master server. Of course it is possible to use a dedicated file server or an already existing storage system, however this guide does not cover that. This has several reasons:&lt;br /&gt;
* Open-Xchange Server does not require much I/O on typical operation&lt;br /&gt;
* Data for groupware objects like the Infostore is stored at the file storage and file metadata is stored at the database. Consistency between the database and the file storage is critical.&lt;br /&gt;
&lt;br /&gt;
=== Installation of the NFS server ===&lt;br /&gt;
Open-Xchange Server is able to access various storage backends, NFS (Network File System) is a mature and proven backend.&lt;br /&gt;
Install the following packages at the MySQL master server to enable NFS storage&lt;br /&gt;
 $ apt-get install nfs-kernel-server nfs-common portmap&lt;br /&gt;
&lt;br /&gt;
Create a directory for the Open-Xchange Server file storage.&lt;br /&gt;
 $ mkdir /var/opt/filestore&lt;br /&gt;
&lt;br /&gt;
Open-Xchange Server runs as user &amp;#039;&amp;#039;open-xchange&amp;#039;&amp;#039;, create a user account at the NFS server, this is required for accessing the NFS export later. NFS will map the user id (uid) and group id (gid), therefore they need to be equal at the Open-Xchange Server nodes and the NFS server.&lt;br /&gt;
 $ useradd open-xchange&lt;br /&gt;
&lt;br /&gt;
Check the uid and gid, typically it&amp;#039;s 1001:1001 since it&amp;#039;s the first user on the system.&lt;br /&gt;
 $ grep open-xchange /etc/passwd&lt;br /&gt;
 open-xchange:x:1001:1001::/home/open-xchange:/bin/sh&lt;br /&gt;
&lt;br /&gt;
Make the newly created user own the filestore at the NFS server&lt;br /&gt;
 $ chown open-xchange:open-xchange /var/opt/filestore&lt;br /&gt;
&lt;br /&gt;
Configure the NFS server to provide this directory to both Open-Xchange Server nodes in read and write mode. Enter the uid and gid of the &amp;#039;&amp;#039;open-xchange&amp;#039;&amp;#039; user to the NFS export.&lt;br /&gt;
 $ vim /etc/exports&lt;br /&gt;
 /var/opt/filestore 10.20.30.213(rw,no_subtree_check,all_squash,anonuid=1001,anongid=1001) 10.20.30.215(rw,no_subtree_check,all_squash,anonuid=1001,anongid=1001)&lt;br /&gt;
&lt;br /&gt;
Make the changes effective to the running NFS server&lt;br /&gt;
 $ exportfs -a&lt;br /&gt;
&lt;br /&gt;
=== Installation of NFS clients ===&lt;br /&gt;
Both Open-Xchange Server machines are NFS clients since they mount the distributed file storage. It&amp;#039;s critical that both Open-Xchange Server nodes can access the same filestorage since due to session load balancing it is possible that a user logs in to either one Open-Xchange Server.&lt;br /&gt;
&lt;br /&gt;
Install required NFS client packages on both Open-Xchange Server nodes&lt;br /&gt;
 $ apt-get install nfs-common portmap&lt;br /&gt;
&lt;br /&gt;
Create mountpoints for the filestore at both Open-Xchange Server nodes&lt;br /&gt;
 $ mkdir /var/opt/filestore/&lt;br /&gt;
&lt;br /&gt;
Open-Xchange Server runs as user &amp;#039;&amp;#039;open-xchange&amp;#039;&amp;#039;, to let this user access the filestore, create a user account at all Open-Xchange Server nodes. NFS will map the user id (uid) and group id (gid) to the ones at the NFS server, therefore they need to be equal at the Open-Xchange Server nodes and the NFS Server.&lt;br /&gt;
 $ useradd open-xchange&lt;br /&gt;
 $ grep open-xchange /etc/passwd&lt;br /&gt;
 open-xchange:x:1001:1001::/home/open-xchange:/bin/sh&lt;br /&gt;
&lt;br /&gt;
Add the NFS storage to the fstab configuration file to mount the storage automatically on boot at both Open-Xchange Server nodes&lt;br /&gt;
 $ vim /etc/fstab&lt;br /&gt;
 10.20.30.217:/var/opt/filestore  /var/opt/filestore  nfs  defaults  0  0&lt;br /&gt;
&lt;br /&gt;
=== Testing the distributed file storage ===&lt;br /&gt;
Mount the filestore manually on both Open-Xchange Server nodes to check if the connection works properly&lt;br /&gt;
 $ mount /var/opt/filestore&lt;br /&gt;
&lt;br /&gt;
To test the distributed storage, create a file on one Open-Xchange Server node as user &amp;#039;&amp;#039;open-xchange&amp;#039;&amp;#039;&lt;br /&gt;
 $ su open-xchange&lt;br /&gt;
 $ touch /var/opt/filestore/foo&lt;br /&gt;
 &lt;br /&gt;
Then check if the file is available and writeable at the other node also as user &amp;#039;&amp;#039;open-xchange&amp;#039;&amp;#039;&lt;br /&gt;
 $ su open-xchange&lt;br /&gt;
 $ ls -la /var/opt/filestore&lt;br /&gt;
 $ rm /var/opt/filestore/foo&lt;/div&gt;</summary>
		<author><name>Bartl3by</name></author>
	</entry>
</feed>