Cacti (home)ForumsDocumentation

Differences

This shows you the differences between two versions of the page.

manual:100:6_reference.4_cli_script.5_copy_user [2019/10/29 15:16] (current)
Line 1: Line 1:
 +==== Copy Local Cacti User ====
  
 +For use and understanding the limitation of this script, it is of importance to read [[2_basics.4_user_management.1_edit_existing_user|User Management]]. In case you're using local cacti user definitions, you may copy a template user to a new user. Don't use this script for //LDAP// or Web Basic users.
 +
 +Calling the script with the parameter //--help// yields
 +
 +<code>shell>php -q copy_user.php --help
 +
 +It is highly recommended that you use the web interface to copy users as this script will only copy Local Cacti users.
 +
 +Syntax:
 + php copy_cacti_user.php <template user> <new user></code>
 +
 +Now let's create a new user //Harry Potter// as follows
 +
 +<code>shell>php -q copy_user.php guest "Harry Potter"
 +
 +It is highly recommended that you use the web interface to copy users as this script will only copy Local Cacti users.
 +
 +Cacti User Copy Utility
 +Template User: guest
 +New User: Harry Potter
 +
 +Copying User...
 +User copied...</code>
 +
 +Find the results of this program call at //User Management//
 +
 +<code>User Name** Full Name Enabled Realm Default Graph Policy Last Login
 +admin          Administrator  Yes  Local  ALLOW  Sunday, October 07, 2007 14:59:32
 +guest         Guest Account Yes Local ALLOW N/A
 +Harry Potter Guest Account Yes Local ALLOW N/A</code>





Personal Tools