ericaltendorf / plotman

Chia plotting manager
Apache License 2.0
911 stars 280 forks source link

Plotman not supporting freebsd based systems #242

Open mist0706 opened 3 years ago

mist0706 commented 3 years ago

Due to plotman using certain flags in TrueNAS/FreeNAS it crashes when attempting to archive. Seeing as the flag only changes the blocksize before printing perhaps we could just calculate it straight from bytes to avoid the incompability?

(venv) root@Ubuntu-2004-focal-64-minimal /mnt/Vol04 # plotman archive ...starting archive loop df: invalid option -- B usage: df [-b | -g | -H | -h | -k | -m | -P] [-acilnT] [-t type] [-,] [file | filesystem ...] Sleeping 60s until next iteration... ^CTraceback (most recent call last): File "/root/chia-blockchain/venv/bin/plotman", line 8, in sys.exit(main()) File "/root/chia-blockchain/venv/lib/python3.8/site-packages/plotman/plotman.py", line 180, in main time.sleep(60) KeyboardInterrupt

https://github.com/ericaltendorf/plotman/blob/5788e7fa2df2186ccb94db2d388766f9d52116a4/src/plotman/archive.py#L52

mist0706 commented 3 years ago

I would also like to submit a branch, how do i get access?

ericaltendorf commented 3 years ago

Hmm, maybe. If we don't specify block size, then aren't we introducing a different incompatibility by not knowing the default block size of the remote host?

See also issue #6 . What I'm thinking is to just let people configure their own command line to obtain free space however they want...

Regarding submitting PRs, please see my new handy page here :) https://github.com/ericaltendorf/plotman/wiki/Contributing

pusewicz commented 3 years ago

Here's a link to the man page: https://www.freebsd.org/cgi/man.cgi?df(1)

pusewicz commented 3 years ago

It looks to me that the -ak params are equal?

altendky commented 3 years ago

https://github.com/ericaltendorf/plotman/pull/88#discussion_r628812872 Hopefully we can just make it configurable per your preference or need with our own expected format (easily generated from df). Maybe just weigh in over there if you have a need I haven't covered? I do think there are more details for us to work through there.

We could also just require that Python exists at the other end and run some nice portable Python code...