Operating System - HP-UX
1825766 Members
2068 Online
109687 Solutions
New Discussion

Re: username and password

 
Blake A
New Member

username and password

Hello, I used to have a tecport.info username and password but somehow they were deleted, I tried the number i had but it was not in service, does anyone know how i can obtain another one? Any help would be appreciated,
Thanks in advance,

Blake
3 REPLIES 3
Raj D.
Honored Contributor

Re: username and password

Blake,

If the user home directory exists its simple , just to create the user with useradd command with the same homedirectory.
Ex:
# useradd -u -d/home/tecport -s/usr/bin/sh -c "TCP User" -m tecport ; passwd techport

hth,
Raj.
" If u think u can , If u think u cannot , - You are always Right . "
Indrajit_1
Valued Contributor

Re: username and password

Blake;

u can re-create the same user id with same UID, and GID. e.g

#useradd -u -g -c "owner-name" -d -s /usr/bin/ksh

#passwd user-id

same for other user.

please check if user home directory is present.

Cheers;
Indrajit Roy
Never Ever Give Up
Reshma Malusare
Trusted Contributor

Re: username and password

Hi Blake,
If you have deleted username & password,then you can add the user by useradd command: A user can be created using the useradd command; you have to specify the user (login) name at the command line to create a new user.
Syntax:
You can provide many options with the useradd command to customize the new user creation process.
# useradd -o -u 101
define the UID
#useradd -g users
Define primary groups
#useradd -G groupname
define secondary groups
#useradd -C â Comment"
define the comment field
#useradd -m -d /home/username
make a home directory for the user
#useradd -s /usr/bin/sh
define the default shell
#useradd -e 9/2/2007
define an account expiration date
#useradd username
define the username
A home directory will be created : /home/
It also copied the startup files from the /etc/skel directoy to the home directory.[ Now here you checked whether previous home dir exist or not]

Password : With password you can set the password for user account.
# passwd

Refer following documents :
http://docs.hp.com/en/B2355-90692/useradd.1M.html

http://docs.hp.com/en/5991-6480/ch04s02.html

Regards,
Reshma