[p4] Scripting Login

Weintraub, David david.weintraub at bofasecurities.com
Thu Jul 6 07:27:07 PDT 2006

The way to get around this is to setup a group for this user using "p4
group" command -- you can't do this through P4V or P4win. Set the
Timeout value to "99999999". This will keep any user in this group
logged in for the next 3 1/2 years. Add this user to the group, and do a
"p4 login -a" to log the user in.

Remember to only use eight 9s and not 9 nines. In theory, nine 9s
(999999999) as a timeout will last 30 years, but due to a bug in
Perforce, it doesn't work. Also, don't use a timeout of zero which is
suppose to allow a user to be logged in forever. The problem is if the
user is a member of more than a single group, the user's login time will
be the highest timeout value of all the groups that user is in. And,
zero is much lower than the standard 43200 (12 hours) value.

-----Original Message-----
From: perforce-user-bounces at perforce.com
[mailto:perforce-user-bounces at perforce.com] On Behalf Of Vander Werf,
Sent: Thursday, July 06, 2006 7:54 AM
To: perforce-user at perforce.com
Subject: [p4] Scripting Login

I have several scripts (MSDOS batch files) I use to manage tasks on two
different Perforce servers. Where I get hung up is on the login. If I
haven't logged in to a server for 12 hours, a login is required and my
scripts fails. I haven't been able to figure out how to automate the
login process, at least not with batch files.  Anyone have any ideas on




perforce-user mailing list  -  perforce-user at perforce.com

More information about the perforce-user mailing list