[PATCHSET] samba-tool sites/subnets administration

Andrew Bartlett abartlet at samba.org
Fri Jul 10 21:31:45 UTC 2015


On Thu, 2015-07-09 at 15:54 +0200, Roel van Meer wrote:
> Hi everyone,
> 
> attached are four patches that extend the functionality of samba-tool with  
> some commands for administration of sites and subnets.  After these patches,  
> we have the following subcommands in the "samba-tool sites" command:
> 
> Available subcommands:
>  create        - Create a new site.
>  createsubnet  - Create a new subnet.
>  list          - List all sites.
>  listsubnets   - List all subnets.
>  moveserver    - Move a server from one site to another.
>  remove        - Delete an existing site.
>  removesubnet  - Delete an existing subnet.
> 
> I've chosen to put the subnet subcommands under the sites command.  Another  
> option would be to create a new supercommand "subnets".  I can redo the  
> patches if that is preferred.
> 
> Things that are still missing are:
> - There is not yet any input validation on the subnets.  Do we already
>   have python code for network address validation somewhere?
> - DNS entries aren't created and/or modified when changing sites.
> 
> Any feedback would be appreciated.

Thanks for taking the time to patch samba-tool!  I know some folks will
be particularly keen to see the moveserver command.

I'm confused however, I can't see the patches to extend
python/samba/sites.py, which seem to be required for these.

Also, can you please add some tests in our selftest system for this?

One example you could follow (or extend) for moveserver would be:
testprogs/blackbox/renamedc.sh but we may also need to write a test for
a runtime environment as well (to ensure that the running server still
works post-move). 

The other tests might be better using the code that can check for
expected values in:

python/samba/tests/samba_tool/user.py

Finally, make sure you sign off your patches, and if you are doing this
work for a company, make sure you send in the Developer Certificate of
Origin per https://devel.samba.org/samba/devel/copyright-policy.html

Thanks,

Andrew Bartlett

-- 
Andrew Bartlett                       http://samba.org/~abartlet/
Authentication Developer, Samba Team  http://samba.org
Samba Developer, Catalyst IT          http://catalyst.net.nz/services/samba





More information about the samba-technical mailing list