How can I disable to share for my old username on Samba?

Hi,
I’m running nextcloudpi version 14.0.4 on raspberry pi 3 model B.
I changed username using nc-init on ncp-config two times.
First, from “ncp” to “naoki”.
Second, from “naoki” to “naokitakatani”.
After that, I activated Samba on ncp-config.
According to the log, nextcloudpi added Samba share for my old username “ncp” and “naoki”.

[ samba ]
adding SAMBA share for user naoki
adding SAMBA share for user naokitakatani
adding SAMBA share for user ncp
SMB enabled

Also I can see thees old username folder from My Mac like below.


How can I disable to share for my old username ?
Please help me.
I installed nextcloudpi by curl command on raspbian.
Not Docker.

Thank you.

Not entirely sure, but suppose you could edit smb.conf manually.
I always make a copy of it, before I start tinkering with it :wink:

I would be very interested in understanding how to do this, too. I’m testing NCP with the WUI on a Rock64.

You’'ll need the terminal for this. Its not available in NCP’s WUI
You can start understanding by just reading the configuration file cat /etc/samba/smb.conf
and samba’s manual pages

  • Lines starting with a # are comments and explain the options by section, and will not be executed.

  • Those starting with a ; are disabled options, just remove the ; to enable them.

  • Just comment out [shares] you wish to disable.

After making changes, you need to reload smb.service before changes take effect.

1 Like