Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ipfs add --chunker options documentation #4276

Closed
thisconnect opened this issue Oct 4, 2017 · 4 comments
Closed

ipfs add --chunker options documentation #4276

thisconnect opened this issue Oct 4, 2017 · 4 comments
Assignees
Labels
help wanted Seeking public contribution on this issue topic/docs-ipfs Topic docs-ipfs

Comments

@thisconnect
Copy link
Contributor

Version information:

go-ipfs version: 0.4.11-
Repo version: 6
System version: amd64/darwin
Golang version: go1.9

Type:

Documentation, cli help

Severity:

Low

Description:

ipfs add --help mentions the chunker option, but has no explanation for what values it accepts.

ipfs add --help
...
 -s,          --chunker             string - Chunking algorithm to use.

According to @JustinDrake

The default is to use a block size of DefaultBlockSize int64 = 1024 * 256. Another block size can be specified using size-. There's also the rabin- chunker which uses rabin-[min]-[avg]-[max].

ipfs-inactive/faq#214 (comment)

is also missing in https://ipfs.io/docs/api/#api-v0-add

Is this correct and should it be added to ipfs add --help?


other findings

@thisconnect thisconnect changed the title document ipfs add --chunker options ipfs add --chunker options documentation Oct 4, 2017
@Stebalien
Copy link
Member

Is this correct and should it be added to

Yes. Are you volunteering 😸 ?

FYI, the variables in size-[size] and rabin-[min]-[avg]-[max] is in bytes, not KiB (as I just learned...).

@Stebalien Stebalien added topic/docs-ipfs Topic docs-ipfs help wanted Seeking public contribution on this issue labels Oct 13, 2017
@thisconnect
Copy link
Contributor Author

Are you volunteering 😸 ?

Let me try, but I am slow bear with me. 2 questions

  1. What exactly is the default? Guessing something like size-256
  2. I change the text from Chunking algorithm to use. to Chunking algorithm to use. Another block size can be specified using size-. There's also the rabin- chunker which uses rabin-[min]-[avg]-[max] + default

@Stebalien
Copy link
Member

  1. It's size-262144 (1024*256).
  2. Sounds good.

thisconnect added a commit to thisconnect/go-ipfs that referenced this issue Oct 14, 2017
see ipfs#4276

License: MIT
Signed-off-by: Enrique Erne <[email protected]>
@olizilla
Copy link
Member

There were 2 PRs to improve this #4306 and #4347 from @thisconnect back in 2017 so I'm gonna go ahead and close this. Thanks @thisconnect !

Also of note, @alanshaw and I made a tool to visualise how these options alter the dag that is created

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Seeking public contribution on this issue topic/docs-ipfs Topic docs-ipfs
Projects
None yet
Development

No branches or pull requests

3 participants