docs: update deprecated -mserver flag to -master

Updated all documentation to use the current -master flag instead of
the deprecated -mserver flag for specifying master server addresses.
chrislusf committed 2025-12-08 22:51:58 -08:00
1 parent fbe3b51ac5
commit 5c3f4054cf
11 files changed
+31 -31

No files matched your search

+1 -1
@@ -108,7 +108,7 @@ spec:
containers:
- name: weedvol
image: 192.168.42.23:80/weed:latest
args: ["-log_dir", "/var/containerdata/logs", "volume", "-port", "8080", "-mserver", "haystackservice:9333", "-dir", "/var/containerdata/haystack/volume", "-ip", "haystackservice"]
args: ["-log_dir", "/var/containerdata/logs", "volume", "-port", "8080", "-master", "haystackservice:9333", "-dir", "/var/containerdata/haystack/volume", "-ip", "haystackservice"]
ports:
- containerPort: 8080
- containerPort: 18080
+2 -2
@@ -116,7 +116,7 @@ services:
image: chrislusf/seaweedfs:latest
ports:
- 8080:8080
command: volume -mserver=master:9333
command: volume -master=master:9333
depends_on:
- master
@@ -186,7 +186,7 @@ services:
image: chrislusf/seaweedfs:latest
ports:
- 8080:8080
command: volume -mserver=master:9333
command: volume -master=master:9333
depends_on:
- master
+1 -1
@@ -193,7 +193,7 @@ If you **must** have custom gRPC ports, you can specify a custom gRPC port when
For example:
```
weed master -port=9333 -port.grpc=9444
weed volume -port=8080 -port.grpc=8444 -mserver=localhost:9333.9444
weed volume -port=8080 -port.grpc=8444 -master=localhost:9333.9444
weed filer -port=8888 -port.grpc=9999 -master=localhost:9333.9444
weed shell -filer=localhst:8888.9999 -master=localhost:9333.9444
weed mount -dir=mm -filer=localhst:8888.9999
+5 -5
@@ -42,14 +42,14 @@ weed master -ip=localhost -port=9333 -mdir=./1 -peers=localhost:9333,localhost:9
weed master -ip=localhost -port=9334 -mdir=./2 -peers=localhost:9333,localhost:9334,localhost:9335
weed master -ip=localhost -port=9335 -mdir=./3 -peers=localhost:9333,localhost:9334,localhost:9335
# now start the volume servers, specifying any one of the master server
weed volume -dir=./1 -port=8080 -mserver=localhost:9333,localhost:9334,localhost:9335
weed volume -dir=./2 -port=8081 -mserver=localhost:9333,localhost:9334,localhost:9335
weed volume -dir=./3 -port=8082 -mserver=localhost:9333,localhost:9334,localhost:9335
weed volume -dir=./1 -port=8080 -master=localhost:9333,localhost:9334,localhost:9335
weed volume -dir=./2 -port=8081 -master=localhost:9333,localhost:9334,localhost:9335
weed volume -dir=./3 -port=8082 -master=localhost:9333,localhost:9334,localhost:9335
# The full list of masters is recommended, but not required.
# You can only specify any master servers.
weed volume -dir=./3 -port=8082 -mserver=localhost:9333
weed volume -dir=./3 -port=8082 -mserver=localhost:9333,localhost:9334
weed volume -dir=./3 -port=8082 -master=localhost:9333
weed volume -dir=./3 -port=8082 -master=localhost:9333,localhost:9334
```
These 6 commands will actually functioning the same as the previous 3 commands from the cheatsheet.
+3 -3
@@ -36,9 +36,9 @@ Usually volume servers are spread on different computers. They can have differen
Usually you would need to specify the available disk space, the Weed Master location, and the storage folder.
```bash
./weed volume -max=100 -mserver="localhost:9333" -dir="./data"
./weed volume -max=100 -master="localhost:9333" -dir="./data"
```
If you are using a custom gRPC port for master, the address format for `mserver` is `<host>:<port>.<grpcPort>`. By default the gRPC port is `port + 10000`.
If you are using a custom gRPC port for master, the address format for `-master` is `<host>:<port>.<grpcPort>`. By default the gRPC port is `port + 10000`.
### Cheat Sheet: Setup One Master Server and One Volume Server
@@ -79,7 +79,7 @@ Use with docker is easy as run locally, you can pass all args like above. But yo
docker run -p 9333:9333 --name master chrislusf/seaweedfs master -ip=master
```
```
docker run -p 8080:8080 -p 18080:18080 --name volume --link master chrislusf/seaweedfs volume -max=5 -mserver="master:9333" -port=8080
docker run -p 8080:8080 -p 18080:18080 --name volume --link master chrislusf/seaweedfs volume -max=5 -master="master:9333" -port=8080
```
#### With Compose ####
But with Compose it's easiest.
+1 -1
@@ -41,7 +41,7 @@ Creating a hobbyist-scale storage network with heterogeneous commodity hardware
1. On each storage node, start a volume server that connects to the master:
```
weed volume -mserver=master_node_IP:9333 -port=8080 -dir=/data1/seaweedfs/volume
weed volume -master=master_node_IP:9333 -port=8080 -dir=/data1/seaweedfs/volume
```
Adjust the directory as needed for your setup. I typically have data drives mounted with a consistent naming strategy and separate from the operating system storage.
+5 -5
@@ -85,14 +85,14 @@ specify a non-zero value, if you wish to explicitly manage your disk space.
Run this to setup:
```
weed volume -mserver=ip1:9333,ip2:9333,ip3:9333 -dataCenter=dc1 -rack=rack1 -dir=/data/seaweedfs/volume -ip=xxx.xxx.xxx.xxx -max=0
weed volume -master=ip1:9333,ip2:9333,ip3:9333 -dataCenter=dc1 -rack=rack1 -dir=/data/seaweedfs/volume -ip=xxx.xxx.xxx.xxx -max=0
```
* **For machine with multiple disks**
Configure the `-dir` to be comma separated directory list, and set `-max` for corresponding directories, assuming the `/data/seaweedfs/volume[x]` are on different disks.
```
weed volume -mserver=ip1:9333,ip2:9333,ip3:9333 -dataCenter=dc1 -rack=rack1 -ip=xxx.xxx.xxx.xxx -dir=/data/seaweedfs/volume1,/data/seaweedfs/volume2,/data/seaweedfs/volume3 -max=0,0,0
weed volume -master=ip1:9333,ip2:9333,ip3:9333 -dataCenter=dc1 -rack=rack1 -ip=xxx.xxx.xxx.xxx -dir=/data/seaweedfs/volume1,/data/seaweedfs/volume2,/data/seaweedfs/volume3 -max=0,0,0
```
Do not use multiple directories on the same disk. The automatic volume count limit will double count the capacity.
@@ -100,9 +100,9 @@ Do not use multiple directories on the same disk. The automatic volume count lim
You can also create multiple volume servers on different ports. It could be easier for changing disks.
```
weed volume -mserver=ip1:9333,ip2:9333,ip3:9333 -dataCenter=dc1 -rack=rack1 -dir=/data/seaweedfs/volume1 -ip=xxx.xxx.xxx.xxx -max=0 -port=8081
weed volume -mserver=ip1:9333,ip2:9333,ip3:9333 -dataCenter=dc1 -rack=rack1 -dir=/data/seaweedfs/volume2 -ip=xxx.xxx.xxx.xxx -max=0 -port=8082
weed volume -mserver=ip1:9333,ip2:9333,ip3:9333 -dataCenter=dc1 -rack=rack1 -dir=/data/seaweedfs/volume3 -ip=xxx.xxx.xxx.xxx -max=0 -port=8083
weed volume -master=ip1:9333,ip2:9333,ip3:9333 -dataCenter=dc1 -rack=rack1 -dir=/data/seaweedfs/volume1 -ip=xxx.xxx.xxx.xxx -max=0 -port=8081
weed volume -master=ip1:9333,ip2:9333,ip3:9333 -dataCenter=dc1 -rack=rack1 -dir=/data/seaweedfs/volume2 -ip=xxx.xxx.xxx.xxx -max=0 -port=8082
weed volume -master=ip1:9333,ip2:9333,ip3:9333 -dataCenter=dc1 -rack=rack1 -dir=/data/seaweedfs/volume3 -ip=xxx.xxx.xxx.xxx -max=0 -port=8083
```
+4 -4
@@ -68,13 +68,13 @@ Basically, the way it works is:
2. start volume servers as this:
```bash
./weed volume -port=8081 -dir=/tmp/1 -max=100 -mserver="master_address:9333" -dataCenter=dc1 -rack=rack1
./weed volume -port=8082 -dir=/tmp/2 -max=100 -mserver="master_address:9333" -dataCenter=dc1 -rack=rack1
./weed volume -port=8081 -dir=/tmp/1 -max=100 -master="master_address:9333" -dataCenter=dc1 -rack=rack1
./weed volume -port=8082 -dir=/tmp/2 -max=100 -master="master_address:9333" -dataCenter=dc1 -rack=rack1
```
On another rack,
```bash
./weed volume -port=8081 -dir=/tmp/1 -max=100 -mserver="master_address:9333" -dataCenter=dc1 -rack=rack2
./weed volume -port=8082 -dir=/tmp/2 -max=100 -mserver="master_address:9333" -dataCenter=dc1 -rack=rack2
./weed volume -port=8081 -dir=/tmp/1 -max=100 -master="master_address:9333" -dataCenter=dc1 -rack=rack2
./weed volume -port=8082 -dir=/tmp/2 -max=100 -master="master_address:9333" -dataCenter=dc1 -rack=rack2
```
No change to Submitting, Reading, and Deleting files.
+3 -3
@@ -48,7 +48,7 @@ services:
ports:
- 8080:8080
- 18080:18080
command: weed volume -mserver=<public IP of server 1>:9333 -dir=/data/seaweedfs/volume -ip=<public ip of this server (server2)>
command: weed volume -master=<public IP of server 1>:9333 -dir=/data/seaweedfs/volume -ip=<public ip of this server (server2)>
```
5. `docker-compose up` on both servers and check that the master sees the volume
@@ -124,7 +124,7 @@ services:
ports:
- 8080:8080
- 18080:18080
command: weed volume -mserver=<master server ip>:9333 -dir=/data/seaweedfs/volume -ip=<publicIp>
command: weed volume -master=<master server ip>:9333 -dir=/data/seaweedfs/volume -ip=<publicIp>
volume-sdb:
build: .
@@ -136,7 +136,7 @@ services:
ports:
- 8081:8081
- 18081:18081
command: weed volume -mserver=<master server ip>:9333 -dir=/data/seaweedfs/volume -ip=<publicIp> -port=8081
command: weed volume -master=<master server ip>:9333 -dir=/data/seaweedfs/volume -ip=<publicIp> -port=8081
```
## High availability
+1 -1
@@ -207,7 +207,7 @@ weed filer \
#!/bin/sh
weed volume \
-mserver=seaweedfs_master:9333 \
-master=seaweedfs_master:9333 \
-max=0 \
-dir=/data \
-dataCenter="$HOST"
+5 -5
@@ -54,9 +54,9 @@ weed volume -whiteList="::1,127.0.0.1"
```bash
weed master -mdir="/tmp/mdata" -defaultReplication="001" -ip="localhost" -port=9334
weed volume -dir=/tmp/vol1/ -mserver="localhost:9334" -ip="localhost" -port=8081
weed volume -dir=/tmp/vol2/ -mserver="localhost:9334" -ip="localhost" -port=8082
weed volume -dir=/tmp/vol3/ -mserver="localhost:9334" -ip="localhost" -port=8083
weed volume -dir=/tmp/vol1/ -master="localhost:9334" -ip="localhost" -port=8081
weed volume -dir=/tmp/vol2/ -master="localhost:9334" -ip="localhost" -port=8082
weed volume -dir=/tmp/vol3/ -master="localhost:9334" -ip="localhost" -port=8083
```
```bash
@@ -99,8 +99,8 @@ start
```bash
weed master -mdir="/tmp/mdata" -defaultReplication="001" -ip="localhost" -port=9334
weed volume -dir=/tmp/vol1/ -mserver="localhost:9334" -ip="localhost" -port=8081
weed volume -dir=/tmp/vol2/ -mserver="localhost:9334" -ip="localhost" -port=8082
weed volume -dir=/tmp/vol1/ -master="localhost:9334" -ip="localhost" -port=8081
weed volume -dir=/tmp/vol2/ -master="localhost:9334" -ip="localhost" -port=8082
```
so we finished moving data of localhost:8083 to localhost:8081/localhost:8082