Today I tested Sheepdog v0.8.3 in Debian Jessie for production use with Swift, alas even when testing it with a simple vdi created with 1G and 1 copy I managed to crash it 🙁

Fire up sheep…

root@nigeltest:~# sheep -r swift -c local -l level=debug,dir=/tmp /var/lib/sheepdog

Format cluster…

root@nigeltest:~# dog cluster format

Create vdi…

root@nigeltest:~# dog vdi create -c 1 mandy 1G

Lets see…

root@nigeltest:~# dog vdi list
Name Id Size Used Shared Creation time VDI id Copies Tag
mandy 0 1.0 GB 0.0 MB 0.0 MB 2015-06-07 08:46 1f2efa 1

Ok … lets issue a GET as per https://github.com/sheepdog/sheepdog/wiki/HTTP-Simple-Storage

root@nigeltest:~# http GET http://localhost/v1/mandy
HTTP/1.1 502 Bad Gateway
Connection: keep-alive
Content-Length: 172
Content-Type: text/html
Date: Sun, 07 Jun 2015 14:20:39 GMT
Server: nginx/1.6.2
.
<html>
<head><title>502 Bad Gateway</title></head>
<body bgcolor="white">
<center><h1>502 Bad Gateway</h1></center>
<hr><center>nginx/1.6.2</center>
</body>
</html>

Oh no…. check the log /tmp/sheep.log…

Jun 07 09:20:38 DEBUG

[main] queue_request(454) READ_OBJ, 1
Jun 07 09:20:38 DEBUG [gway 19632] do_process_work(1428) 2, 801f2efa00000000, 1
Jun 07 09:20:38 DEBUG [http 19641] fill_vdi_info_range(561) (null) = , 0 = 1
Jun 07 09:20:38 DEBUG [main] queue_request(454) READ_OBJ, 1
Jun 07 09:20:38 DEBUG [gway 19632] do_process_work(1428) 2, 801f2efa00000000, 1
Jun 07 09:20:38 EMERG [http 19641] traverse_btree(180) PANIC: This B-tree not support depth 0
Jun 07 09:20:38 EMERG [http 19641] crash_handler(267) sheep exits unexpectedly (Aborted).
Jun 07 09:20:38 EMERG [http 19641] sd_backtrace(833) sheep.c:269: crash_handler
Jun 07 09:20:38 EMERG [http 19641] sd_backtrace(847) /lib/x86_64-linux-gnu/libpthread.so.0(+0xf8cf) [0x7f1e20bca8cf] Jun 07 09:20:38 EMERG [http 19641] sd_backtrace(847) /lib/x86_64-linux-gnu/libc.so.6(gsignal+0x36) [0x7f1e1faa7106] Jun 07 09:20:38 EMERG [http 19641] sd_backtrace(847) /lib/x86_64-linux-gnu/libc.so.6(abort+0x147) [0x7f1e1faa84e7] Jun 07 09:20:38 EMERG [http 19641] sd_backtrace(833) sd_inode.c:180: traverse_btree
Jun 07 09:20:38 EMERG [http 19641] sd_backtrace(833) kv.c:621: kv_iterate_bucket
Jun 07 09:20:38 EMERG [http 19641] sd_backtrace(833) swift.c:40: swift_get_account
Jun 07 09:20:38 EMERG [http 19641] sd_backtrace(833) swift.c:323: swift_handle_request
Jun 07 09:20:38 EMERG [http 19641] sd_backtrace(833) swift.c:349: swift_get
Jun 07 09:20:38 EMERG [http 19641] sd_backtrace(833) http.c:271: http_run_request
Jun 07 09:20:38 EMERG [http 19641] sd_backtrace(833) work.c:352: worker_routine
Jun 07 09:20:38 EMERG [http 19641] sd_backtrace(847) /lib/x86_64-linux-gnu/libpthread.so.0(+0x80a3) [0x7f1e20bc30a3] Jun 07 09:20:38 EMERG [http 19641] sd_backtrace(847) /lib/x86_64-linux-gnu/libc.so.6(clone+0x6c) [0x7f1e1fb5804c]

Many thanks goes to to the developers for adding SWIFT and S3 support, it still however needs a little attention until it can be adopted in production environments.