Re: [PATCH 1/2] ksmbd: update documentation

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 8/30/2022 12:33 PM, Tom Talpey wrote:
>On 8/30/2022 10:17 AM, Namjae Jeon wrote:
>> configuration.txt in ksmbd-tools moved to smb.conf(5ksmbd) manpage.
>> update it and more detailed ksmbd-tools build method.
>> 
>> Cc: Tom Talpey <tom@xxxxxxxxxx>
>> Signed-off-by: Namjae Jeon <linkinjeon@xxxxxxxxxx>
>> ---
>>   Documentation/filesystems/cifs/ksmbd.rst | 10 ++++++++--
>>   1 file changed, 8 insertions(+), 2 deletions(-)
>> 
>> diff --git a/Documentation/filesystems/cifs/ksmbd.rst b/Documentation/filesystems/cifs/ksmbd.rst
>> index 1af600db2e70..767e12d2045a 100644
>> --- a/Documentation/filesystems/cifs/ksmbd.rst
>> +++ b/Documentation/filesystems/cifs/ksmbd.rst
>> @@ -121,20 +121,26 @@ How to run
>>   1. Download ksmbd-tools and compile them.
>>   	- https://github.com/cifsd-team/ksmbd-tools
>>   
>> +        # ./autogen.sh
>> +        # ./configure --sysconfdir=/etc --with-rundir=/run
>> +        # make & sudo make install
>
>I believe you mean "make && sudo make install"? The single & will
>kick off two make's in parallel.

Also, Jeon, since `#' indicates root prompt, there shouldn't be `sudo'.
If you want to use `sudo' in the instructions, then use `$' prompt.
With that `./configure' invocation, the utilities end up in
`/usr/local/sbin'. Since `sysconfdir=/etc' is associated with the
`/usr' prefix, it might be better to put the utilities in there also.
Meaning that `--prefix=/usr' should be given to `./configure', so
`sbindir' becomes `/usr/sbin'. Alternatively, `sysconfdir=/etc'
should be removed so that `/usr/local/etc' is used. This way the
user-built ksmbd-tools doesn't conflict with ksmbd-tools installed
using the package manager.

>
>>   2. Create user/password for SMB share.
>>   
>>   	# mkdir /etc/ksmbd/

Jeon, the install target already creates `/etc/ksmbd'.

>>   	# ksmbd.adduser -a <Enter USERNAME for SMB share access>
>
>It may be worth mentioning that it's not just single-user access, and
>that additional users can be configured.
>
>>   3. Create /etc/ksmbd/smb.conf file, add SMB share in smb.conf file
>> -	- Refer smb.conf.example and
>> -          https://github.com/cifsd-team/ksmbd-tools/blob/master/Documentation/configuration.txt
>> +	- Refer smb.conf.example, See smb.conf(5ksmbd) for details.
>> +
>> +        # man smb.conf.5ksmbd
>
>I like the new manpage, but that's a strange path. Are you sure
>the various maintainers will deploy it that way?

Jeon, it should be `man 5ksmbd smb.conf'. `5' is the section number and
`ksmbd' further differentiates it from Samba's `smb.conf'. Currently,
just `5k' is enough to do so.

>
>Also, it has always bothered me that the name "smb.conf" is the
>same as the Samba server's configuration file, just in a different
>directory. If someone enters "man smb.conf", there may be confusion.
>I really wish the file was called "ksmbd.conf".

Talpey, in what way is it strange? If both Samba and ksmbd-tools are
installed, `man 5 smb.conf' is the Samba page. Then
`man 5ksmbd smb.conf' (or just `man 5k smb.conf') is the ksmbd-tools
page. If only ksmbd-tools is installed, `man 5 smb.conf' is the
ksmbd-tools page. The same applies for just `man smb.conf' since there
is only a page with that name in section 5. This makes sense since
Samba's `smb.conf' is authoritative and ksmbd-tools tries to be
compatible.

>
>Why not putting this under a simpler manpage title "man ksmbd"?
>To me, that's much more logical and it avoids both the confusion
>and having to somehow know that weird manpath.
>
>>   4. Insert ksmbd.ko module
>>   
>>   	# insmod ksmbd.ko
>
>Well, it's worth mentioning that a properly configured and built
>kernel is a prerequisite here...
>
>Also, sudo.
>
>>   5. Start ksmbd user space daemon
>> +
>>   	# ksmbd.mountd
>
>FYI, Ubuntu Jammy pre-configures ksmbd as a service, and there it's
>as simple as "sudo service ksmbd start".
>
>Do you not want to mention the other ksmbd.<foo> helpers here?
>
>>   6. Access share from Windows or Linux using CIFS
>
>Pointer to cifs.ko how-to page?
>
>Basically, I'm encouraging these pages to be (much) more user
>friendly! They're fine for developers, but way too fiddly IMO
>for naive users, or even for admins. It has taken me days to get
>this all going on my fresh machines.
>
>Either way, thanks for the cleanup so far!!
>
>Tom.
>

Atte Heikkilä



[Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux