Peter Memishian wrote:
> > I would like a rename operation to not involving delete_conf() explicitly
> > and only need to update the specific link configuration entry to be the
> new
> > link name.
>
> Is there a specific reason?
>
Well, the reason would be to simplify the API consumers. I'd like the
do_rename() function only calls a single function dladm_rename_conf()
instead of:
dladm_read_conf(conf);
dladm_delete_conf(linkid);
dladm_set_conf_field("name", newname);
dladm_write_conf();
> > Specific to Dan's question, we could add a function rename_conf() to
> > differentiate it from the normal commit_conf() operation.
>
> I think it's more complicated than that, since commit_conf() (write_conf()
> as we've now been calling it) probably needs to write out the entire
> configuration in one pass to preserve atomicity (as per my email).
>
I understand that. But that's in the API implementation.
Thanks
- Cathy