Coda File System

Replication server problems

From: Achim Stumpf <>
Date: Tue, 12 Dec 2006 15:25:52 +0100
Hi List,

I am trying to setup two coda servers. One is SCM , the other should 
replicate the volumes. The SCM is running fine and clients can connect 
to that one and write to it.

I try to setup the replication server like described in

I configured the replication server:

# vice-setup
Welcome to the Coda Server Setup script!

Setting up config files for a coda server.
Do you want the file /etc/coda/server.conf created? [yes]
What is the root directory for your coda server(s)? [/vice]
Setting up /vice.
Directories under /vice are set up.

Is this the master server, aka the SCM machine? (y/n) n
Enter the hostname of the SCM machine :
Enter the update token that matches SCM test2006
Fetching needed files from SCM

Date: Tue 12/12/2006

14:54:35 Fetch failed with Permission denied

/etc/services already has new services registered! Good.
/etc/services ready for Coda
Now installing things specific to non-SCM machines...

A server needs a small log file or disk partition, preferrably on a
disk by itself. It also needs a metadata file or partition of approx
4% of your filespace.

Raw partitions have advantages because we can write to the disk
faster, but we have to load a copy of the complete RVM data
partition into memory. With files we can use a private mmap, which
reduces memory pressure and speeds up server startup by several
orders of magnitude.

Servers with a smaller dataset but heavy write activity will
probably benefit from partitions. Mostly read-only servers with a
large dataset will definitely benefit from an RVM data file. Nobody
has really measured where the breakeven point is, so I cannot
really give any hard numbers.

WARNING: you are going to play with your partitions now.
verify all answers you give.

WARNING: these choices are not easy to change once you are up and running.

Are you ready to set up RVM? [yes/no] yes

What will be your log file (or partition)? /home/coda/log_disk_file.log

The log size must be smaller than the available space in the log
partition. A smaller log will be quicker to commit, but the log
needs to be large enough to handle the largest transaction. A
larger log also allows for better optimizations. We recommend
to keep the log under 30M log size, many people have successfully
used as little as 2M, and 20M has worked well with our servers.
What is your log size? (enter as e.g. '20M') 20M

Where is your data file (or partition)? /home/coda/data_disk_file.log

The amount of RVM we need to store the metadata for a given
amount file space can vary enormously. If your typical data set
consists of many small files, you definitely need more RVM, but
if you tend to store large files (mp3s, videos or image data)
we don't need all that much RVM.

Here are some random samples,
  mp3 files     ~0.08MB RVM per GB.
  jpeg images   ~0.50MB RVM per GB.
  email folders ~37.8MB RVM per GB (maildir, 1 file per message)
  netbsd-pkgsrc  ~180MB RVM per GB (large tree but not much data)

To get a more precize number for your dataset there is a small
tool (rvmsizer) which can reasonably predict the amount of RVM
data we need for a file tree.

Remember that RVM data will have to be mmapped or loaded
into memory, so if anything fails with an error like
RVM_EINTERNAL you might have to add more swap space.

What is the size of you data file (or partition)
[32M, 64M, 128M, 256M, 512M, 768M, 1G]: 256M

WARNING: DATA and LOG partitions are about to be wiped.

  --- log area: /home/coda/log_disk_file.log, size 20M.
  --- data area: /home/coda/data_disk_file.log, size 256 MB.

Proceed, and wipe out old data? [y/n] y

LOG file has been initialized!

Rdsinit will initialize data and log.
This takes a while.
rvm_initialize succeeded.
Going to initialize data file to zero, could take awhile.
rds_zap_heap completed successfully.
rvm_terminate succeeded.

RVM setup is done!

Directories on the server will be used to store container files
that hold the actual data of files stored in Coda. Directory
contents as well as metadata will be stored in the RVM segment
that we already configured earlier.

You should only have one container file hierarchy for each disk
partition, otherwise the server will generate incorrect
estimates about the actual amount of exportable disk space.

Where shall we store your file data [/vicepa]?
Shall I set up a vicetab entry for /vicepa (y/n) y
Select the maximum number of files for the server.
[256K, 1M, 2M, 16M]:

Server directory /vicepa is set up!

You have set up
Your SCM is
Other config files will be fetched from the SCM by updateclnt.

To finish your server setup you should

 start updateclnt as:  updateclnt -h
 start the auth2 server as: auth2 -chk

After that, there is still some configuration needed on the SCM before
this server can be started.

An entry for this host is needed in /vice/db/servers
Then all servers need to be shut down and restarted, as they need to
know about the new server.
After all that it _should_ be ok to start the new server and create
your first replicated volume.

# updateclnt -h
Creating /vice/spool
# auth2 -chk

So the services are running.

After that I have changed on the SCM:
# vim /vice/db/servers
# cat /vice/db/servers               1               2

Then I restarted the codaserver on the SCM. After that I have started the codaserver on the replication server. 
It runs without errors in /vice/srv/Srv*.

Then I kept on going on the SCM:

# cat /vice/db/VRList
/ 7f000000 1 01000001 0 0 0 0 0 0 0
# volutil setlogparms 7f000000 reson 4
V_BindToServer: binding to host clusty1
Set Log parameters
# volutil -h create_rep /vicepa /.1 7f000000
V_BindToServer: binding to host
RPC2_NewBinding to server failed with RPC2_NOBINDING (F)

And at this point I have no more ideas... It does not work!


Received on 2006-12-12 09:29:11