diff options
author | Frederic Robra | 2019-06-25 17:03:28 +0200 |
---|---|---|
committer | Frederic Robra | 2019-06-25 17:03:28 +0200 |
commit | 43e57ce5e11e9052f5a7db66f2e8613f1784f919 (patch) | |
tree | c5e1372a160b2601f61b18d617b71799b06b02ae /conf | |
download | dnbd3-ng-43e57ce5e11e9052f5a7db66f2e8613f1784f919.tar.gz dnbd3-ng-43e57ce5e11e9052f5a7db66f2e8613f1784f919.tar.xz dnbd3-ng-43e57ce5e11e9052f5a7db66f2e8613f1784f919.zip |
first version of dnbd3-ng
Diffstat (limited to 'conf')
-rw-r--r-- | conf/README.server | 30 | ||||
-rw-r--r-- | conf/alt-servers | 4 | ||||
-rw-r--r-- | conf/rpc.acl | 5 | ||||
-rw-r--r-- | conf/server.conf | 57 |
4 files changed, 96 insertions, 0 deletions
diff --git a/conf/README.server b/conf/README.server new file mode 100644 index 0000000..285758b --- /dev/null +++ b/conf/README.server @@ -0,0 +1,30 @@ +Configuration for dnbd3-server + +The server requires a config directory. +Start it like so: ./dnbd3-server -c ./my-config/ + +There are two files in that dir + +== alt-servers == +List of known alt-servers for this server. +Format: +[PREFIX]<IP:PORT> [Comment] + +Prefix can be: ++ - Only report server to clients as alt-server, but don't use for replication +- - Only use server for replication, but don't advertise to clients +No prefix means server will be advertised to clients and is used for replication + +If you're not running in proxy mode, this file won't do much for you + +== server.conf == + +Main configuration file. Ini format. + +[dnbd3] +basePath=/srv/openslx/dnbd3 # virtual root of image files +serverPenalty=1234 # artificial acceptance delay for incoming server connections (µs) +clientPenalty=2345 # artificial acceptance delay for incoming client connection (µs) +isProxy=true # enable proxy mode - will try to replicate from alt-servers if a client requests unknown image +uplinkTimeout=1250 # r/w timeout for connections to uplink servers + diff --git a/conf/alt-servers b/conf/alt-servers new file mode 100644 index 0000000..fd2f2ec --- /dev/null +++ b/conf/alt-servers @@ -0,0 +1,4 @@ +192.168.100.10 Some alt server ++192.168.100.100 My first alt server that will not be used for replication +-192.168.100.50 Super sectret alt server that will be used for replication, but clients don't know about it + diff --git a/conf/rpc.acl b/conf/rpc.acl new file mode 100644 index 0000000..5167ae3 --- /dev/null +++ b/conf/rpc.acl @@ -0,0 +1,5 @@ +# Everything from localhost +127.0.0.0/8 ALL +# Some info reading for another machine +132.230.8.113 STATS CLIENT_LIST IMAGE_LIST + diff --git a/conf/server.conf b/conf/server.conf new file mode 100644 index 0000000..2f43247 --- /dev/null +++ b/conf/server.conf @@ -0,0 +1,57 @@ +[dnbd3] +; port to listen on (default: 5003) +listenPort=5003 +; relative root directory for images, ending in .r[1-9][0-9]* +basePath=/mnt/storage/dnbd3 +; artificial connection delay for connecting servers +serverPenalty=100000 +; artificial connection delay for connecting clients +clientPenalty=0 +; is this server a proxy? if true, requests for non-existing images will be relayed to known alt-servers +isProxy=true +; if proxy is true and an image is incomplete, should idle bandwidth be used to replicate missing blocks? +backgroundReplication=true +; minimum amount of connected clients for background replication to kick in +bgrMinClients=0 +; if isProxy==true and another proxy requests and image that we don't have, should we ask our alt-servers for it? +lookupMissingForProxy=true +; create sparse files instead of preallocating; ignored if backgroundReplication=true -- only recommended if cache space is small +sparseFiles=false +; if true (which is the default), images will automatically be removed from the list if they can't be accessed +removeMissingImages=true +; timeout in ms for send/recv on connections to uplink servers (used for replication) +uplinkTimeout=1250 +; timeout in ms for send/recv on connections to clients (using an image on this server) +clientTimeout=15000 +; set this to true to close handles of unused images after some timeout +closeUnusedFd=false +; set this to true to load files without the .r[0-9]+ extension too, assuming RID=1 +vmdkLegacyMode=false + +[limits] +maxClients=2000 +maxImages=1000 +maxPayload=9M +maxReplicationSize=150G + +; Log related config +[logging] +; log file path and name +; comment out to disable logging to file +; protip: use SIGUSR2 to reopen log file +file=./dnbd3.log +; which type of messages to log to file +fileMask=ERROR WARNING MINOR INFO DEBUG1 +; which to log to console (stdout) +consoleMask=ERROR WARNING MINOR INFO +; Valid types (warning: specifying invalid types will not yield an error!) +; ERROR Fatal error, server will terminate +; WARNING Major issue, something is broken but keep running +; MINOR Minor issue, more of a hickup than serious problem +; INFO Informational message +; DEBUG1 Debug information, used for medium verbosity +; DEBUG2 Used for debug messages that would show up a lot +; +; Whether timestamps should be output to console too (or just to file if false) +consoleTimestamps=false + |