SETLCID(3) BSD Library Functions Manual SETLCID(3)NAME
setlcid -- set login context
setlcid(pid_t pid, pid_t lcid);
The setlcid() system call sets the login context of the specified process pid to the specified lcid. If the pid is zero, then the call
applies to the current process. If the lcid is zero a new login context will be created. If the lcid is -1 the process will be removed from
the login context it is currently a member of, if any.
Creation of a new login context is only valid for the current process. A process may not create a new login context if it is currently a
member of one.
Superuser privilege is required to add or remove a process from a login context.
The setlcid() function returns the value 0 if successful; otherwise the value -1 is returned and the global variable errno is set to indicate
The setlcid() function will fail if:
[EPERM] Operation not permitted.
[ESRCH] No such process.
[ENOMEM] Cannot allocate memory.
[ENOATTR] Attribute not found.
SEE ALSO getlcid(2)HISTORY
The setlcid manual page first appeared in FreeBSD 6.0.
This manual page was written by Matthew N. Dodd <mdodd@FreeBSD.org>.
BSD May 5, 2005 BSD
Check Out this Related Man Page
GETSID(2) BSD System Calls Manual GETSID(2)NAME
getsid -- get process session
Standard C Library (libc, -lc)
The session ID of the process identified by pid is returned by getsid(). If pid is zero, getsid() returns the session ID of the current
Upon successful completion, the function getsid() returns the session ID of the specified process; otherwise, it returns a value of -1 and
sets errno to indicate an error.
The getsid() system call will fail if:
[ESRCH] There is no process with a process ID equal to pid.
Note that an implementation may restrict this function call to processes within the same session ID as the calling process.
SEE ALSO getpgid(2), getpgrp(2), setpgid(2), setsid(2), termios(4)HISTORY
The getsid() function call appeared in FreeBSD 3.0. The getsid() function call is derived from its usage in AT&T System V UNIX.
BSD August 19, 1997 BSD
I have created user in AIX 4.3.3 which the member of staff group.
but during login ( with su command) it gives the error
"can not set process environment "
but when it is member of another group -dba -which is the group for oracle database- it works properly.
Pls let me know the solution.
... (5 Replies)
When i telnet the ES 4 server, i always get the question to accept the default context
Red Hat Enterprise Linux ES release 4 (Nahant Update 2)
Kernel 2.6.9-5.ELsmp on an i686
Your default context is user_u:system_r:unconfined_t.
Do you want to choose a different... (0 Replies)
If you are a former member of the abandoned forums over at bsdforums.org, please feel free to suggest subforums for BSD here and we will add them, if you would like to be active here.
We have plenty of room for the BSD community here.
Welcome! (1 Reply)
Can someone please advise how to get a login's process ID?
From the command line, echo $$ will show what I assume is my login's process ID. Is is possible to get this process ID from within a script?
To give a clear picture of what am wanting to achieve, I have a script that has to be... (6 Replies)