Monday, January 30, 2017

seaweedfs

CMD,

cd C:\jh1\seaweedfs\



--------------------
start server, default port 9333#

weed master

----------------------------
start 2 volume as port 9331, 9332#

weed volume -dir="C:\jh1\seaweedfs\data1" -max=5  -mserver="localhost:9333" -port=9331 &
weed volume -dir="C:\jh1\seaweedfs\data2" -max=10 -mserver="localhost:9333" -port=9332 &

----------------------
upload a file#


C:\Users\HU_J>curl -X POST http://localhost:9333/dir/assign

{"fid":"6,01d1e2347c","url":"127.0.0.1:9331","publicUrl":"127.0.0.1:9331","count
":1}


> curl -X PUT -F file=@C:\jh1\share_map_online\desktop_map_export\pdf\CDBG_2015_1.pdf http://127.0.0.1:9331/6,01d1e2347c


> curl -X PUT -F file=@"C:\jh1\share_map_online\desktop_map_export\pdf\City of Costa Mesa Zoning Map 2017.pdf" http://127.0.0.1:9331/7,022fde80fd




C:\Users\HU_J>curl -X POST http://localhost:9333/dir/assign
{"fid":"6,01d1e2347c","url":"127.0.0.1:9331","publicUrl":"127.0.0.1:9331","count
":1}
C:\Users\HU_J>curl -X PUT -F file=@C:\jh1\share_map_online\desktop_map_export\pd
f\CDBG_2015_1.pdf http://127.0.0.1:9331/6,01d1e2347c
{"name":"CDBG_2015_1.pdf","size":2652865}

------------------------

read file

http://localhost:9331/6,01d1e2347c
http://localhost:9331/7,022fde80fd

No comments: