Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

useradd command sets "inactive" field in shadow automatically

Status
Not open for further replies.

SBSaikia

IS-IT--Management
Feb 9, 2004
54
SG
One of my Solaris 8 system has a problem, when I add a new user with
useradd command it sets account inactive period to 30 automatically.
(username:password:lastchg: min:max:warn:inactive:expire:flag)

For eg:
#useradd test
#grep test /etc/shadow
test:*LK*:::::30::

Please note the system was hardened with "Titan,v3.8"
Like to know where is the setting for this? How to modify it?

Thanks in advance.

-SBSaikia
 
this is a default, have a look at /etc/default/passwd
change the values of MINWEEKS and MAXWEEKS
if you want NO limits, set them to NOTHING g.e.
MINWEEKS=
:) guggach
 
Hi guggach,

Its not MINWEEK/MAXWEEK,its "inactive" and not set in /etc/default/passwd file. Please note the position in the /etc/shadow file:
(username:password:lastchg:min:max:warn:inactive:expire:flag)

For eg:
#useradd test
#grep test /etc/shadow
test:*LK*:::::30::

Any one has the answer...???

Thanks
-SBSaikia
 
i see ... you are confusing
'inactive' and 'inactivity'
consult shadow's man pages to get
the meaning of 'inactive'
the test account is locked '*LK*'
run as root pwconv to check passwd && shadow
set for this user an initial passwd.
----
i never use useradd or admintool, to install a user
you need few steps for this:
- make a valid entry in /etc/passwd
- mybe also in /etc/group
- run pwconv
- set an initial-passwd
- mkdir -p /{export/}home/user-name
- chown -R username:groupname /{export/}home/user-name
that's all, and works on EVERY unix system.


:) guggach
 
Hi guggach,

Afraid to see your reply...
You hvn't understood the problem yet...




 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top