Sponsored Content
Special Forums Windows & DOS: Issues & Discussions Problems With User Creation Script Post 302762215 by Hammadi dali on Monday 28th of January 2013 08:53:17 AM
Old 01-28-2013
it is a problem of parenthesis positionning :
Code:
@echo off
 SET /P deleteorkeep="This username %%i already exists, press d to delete the account and files, press k to delete the account but rename the files folder with a suffix of _old:" 
IF /i "%deleteorkeep:~,1%" EQU "d" (      ECHO delete    )
   IF /i "%deleteorkeep:~,1%" EQU "k" (   ECHO keep     
   ) ELSE (     
   NET USER %%i %%i /add     )

 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

user creation using shell script for JSP

hello friends, I have problem. We want to create user from jsp(browser based) on our linux server. How we can do that ? or How do we create a user with shell programming by taking arguments and checking with the existing users and if the user exist it should display the message the user exists... (1 Reply)
Discussion started by: jarkvarma
1 Replies

2. Solaris

User creation

Hi all, I want to create one user with full permissions to one directory called /opt/tivoli/tsm/client/ba/bin. Name for the user Tivoli Thanks & Regards Babu (7 Replies)
Discussion started by: lbreddy
7 Replies

3. Shell Programming and Scripting

Help in Shell scripting to modify the User Creation script in oracle database.

Hi, I have several users to create on my test Oracle database taking the scripts from the Production Oracle database. I have a separate text file where I have user-id and passwords maintained. I need help in writing a shell script to go thru the user creation scripts and replace VALUES... (1 Reply)
Discussion started by: rparavastu
1 Replies

4. Solaris

Need help with user creation

Hello guys, i have a problem where i cant create a user and here some problem that i encounter. 1. /etc/passwd seems locked. 2. getting this error UX: useradd: ERROR: Cannot update system files - login cannot be created. # useradd -u 47367 -g 1084 -c "user123" -d /local/home/user123 -s... (2 Replies)
Discussion started by: brew
2 Replies

5. Shell Programming and Scripting

User creation script

Hi Gems.. I am working out on project of creating a mass user on 100 server. Please help me with script where i can create an user id of new 80 user using shell script Thanks in advance. Indrajit Bhagat (1 Reply)
Discussion started by: indrajit_renu
1 Replies

6. UNIX for Advanced & Expert Users

Can we Automate the User creation and setting password through a script in solaris 10

Hi, I am using Solaris 10 OS and Bash shell.Is there any way can we automate User creation and setting passwords through a script or any freeware tool. Advance thanks for your response. (1 Reply)
Discussion started by: muraliinfy04
1 Replies

7. Solaris

Package creation problems with Source files

Hi, I am creating "LSOF" solaris package from solaris "source" files. I have compiled the source file and with that i created prototype file also. Then using pkgmk command i can make the package . In the package i am having (pkginfo pkgmap reloc) two file and one directory respectively But... (3 Replies)
Discussion started by: Kathirvel G
3 Replies

8. Shell Programming and Scripting

Bash shell script for user creation in solaris

Hi All, I am new to shell scripting and have a task which need to be completed ASAP. I have searched all the forum and couln't find excat script which could run on solaris.can someone give me the fully working script for below. Bash shell script to create user account with paraments as... (1 Reply)
Discussion started by: sintilash
1 Replies

9. AIX

PowerVM/lpar creation problems

Hi, I'm a newbie to PowerVM and LPARs ( I work with VmWare and Oracle VM Server for Sparc) .recently we purchased an 8202-e4b server, with two enclosures for add'l disk capacity. it is licensed for PowerVM standard,came preloaded as such, AIX 7.1. I've set up HMC v8.2, and run it through a VM on... (30 Replies)
Discussion started by: computron
30 Replies

10. Shell Programming and Scripting

Shell script for user account Creation

Hi Folks, I had a request to create the user request. Between, I just write a script a create, Update Geos, and update the password. My script as below: The error message, what I am getting is all the users are updated with the same Goes value.. #!/bin/bash for i in `cat users.txt`;do... (2 Replies)
Discussion started by: gsiva
2 Replies
eurephiadm usercerts(7) 												   eurephiadm usercerts(7)

NAME
eurephiadm-usercerts - Managing user accounts and certificate relations DESCRIPTION
For a user to connect to a eurephia enabled OpenVPN server, a user account must have been created and activated and an SSL certificate available to the user must have been registered. The user account and certificate the user may use must then be linked together, and this linking the eurephiadm usercert command takes care of. It is also this relation which gives you the option to control which network resources the VPN clients may access, by assigning a firewall profile to such user-certificate links. Available modes for the usercerts command are: -A | --add Register a new certificate and user-cert link -D | --delete Delete a certificate and user-cert link -S | --set-fwprofile Sets the firewall access profile for a user-cert link -l | --list List all registered user-cert links -h | --help <mode> Help about a specific mode The list mode will list all registered links between user accounts and certificates. LIST MODE
The list mode will show all registered user-certificate links -S | --sort <sort keys> Define the sorting of the list Valid sort keys are: uid Nummeric User ID certid Nummeric Certificate ID accessprofile Nummeric firewall profile ID registered According to when the user-cert was registered uicid Nummeric user-cert link ID SET FW PROFILE MODE
The set-fwprofile mode will update the firewall access profile for a given user-cert link Options: (both required) -n | --uicid Unique record id of certificate and user account link -a | --accessprofile Firewall profile ID ADD MODE
The add mode will register a new link between a user account and a certificate. -c | --certid Required - Certificate ID -i | --uid Required - User account ID -a | --accessprofile Firewall profile ID to use for this access DELETE MODE
The delete mode will delete a link between a user account and a certificate. -c | --certid Certificate ID -i | --uid User account ID -n | --uicid Unique record id of certificate and user account link -a | --accessprofile Firewall profile ID SEE ALSO
eurephiadm-users(7), eurephiadm-certs(7), eurephiadm-fwprofiles(7) AUTHOR
Copyright (C) 2008-2010 David Sommerseth <dazo@users.sourceforge.net> David Sommerseth July 2010 eurephiadm usercerts(7)
All times are GMT -4. The time now is 02:53 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy