# uptime
01:55:24 up 22 days, 2:50, 3 users, load average: 0.01, 0.02, 0.00
i have this when i do uptime. but there isnt anibody inside it. all are root ( that is me ) when i go to /dev/pts/ i can only see 0. so how do i clear this counter of 3 users to a real logical one? (4 Replies)
Hey, got a few questions here for anyone who can help......
Command line to - display users using the system, but count them only once.
Command line to - use the lastcomm command to display how many times ive used grep in october.
Command line to - list all logged on users with at least 6... (3 Replies)
Hi Group,
Could someone tell me how to find world writable files on my server? I can use find command in conjuction with -perm option and I will get an output. But what I need is an output which looks similar to ls -l output. Meaning, it should give me the full path of the file along with the... (1 Reply)
Hi,
What command is needed to find all or certain users from a terminal window in MAC OS X 10.5?
Where is a list of categorized commands that could help me find answers similar to this particular question?
Thanks.
Juan Dent (1 Reply)
I finally got how to su - in my mac from the terminal. Now I would like to be able to add new users. useradd -m -d ..... doesn't seem to work. (1 Reply)
Being a system administrator i came across a statement as " Excluding temporary directories /tmp and /var/tmp, no root owned files should be in world writable directories"
While the above statement may look straight forward but how would i check if there are any such directories in the... (7 Replies)
Hi,
On my system, I have about 75 users. Some uers have two or three sessions on the same systems. when I do w, it shows all the sessions. Is there any way to find only the users and not worry about how many sessions. For example: you can see sshe has four connection. I only want to know... (5 Replies)
Hello all,
I want to find the files for certain users. I cant make the or condition work in this instance. I've tried the code below but it didnt worked. Any input on how to get the list for all files for this users.
find . -type f -user abc134 -o -user xyz345 -o bce483 -exec ls... (6 Replies)
Discussion started by: sethmj
6 Replies
LEARN ABOUT SUNOS
grantpt
grantpt(3C) Standard C Library Functions grantpt(3C)NAME
grantpt - grant access to the slave pseudo-terminal device
SYNOPSIS
#include <stdlib.h>
int grantpt(int fildes);
DESCRIPTION
The grantpt() function changes the mode and ownership of the slave pseudo-terminal device associated with its master pseudo-terminal
counterpart. fildes is the file descriptor returned from a successful open of the master pseudo-terminal device. A setuid root program (see
setuid(2)) is invoked to change the permissions. The user ID of the slave is set to the real UID of the calling process and the group ID is
set to a reserved group. The permission mode of the slave pseudo-terminal is set to readable and writable by the owner and writable by the
group.
RETURN VALUES
Upon successful completion, grantpt() returns 0. Otherwise, it returns -1 and sets errno to indicate the error.
ERRORS
The grantpt() function may fail if:
EBADF The fildes argument is not a valid open file descriptor.
EINVAL The fildes argument is not associated with a master pseudo-terminal device.
EACCES The corresponding slave pseudo-terminal device could not be accessed.
USAGE
The grantpt() function will fail if it is unable to successfully invoke the setuid root program. It may also fail if the application has
installed a signal handler to catch SIGCHLD signals.
ATTRIBUTES
See attributes(5) for descriptions of the following attributes:
+-----------------------------+-----------------------------+
| ATTRIBUTE TYPE | ATTRIBUTE VALUE |
+-----------------------------+-----------------------------+
|Interface Stability |Standard |
+-----------------------------+-----------------------------+
|MT-Level |Safe |
+-----------------------------+-----------------------------+
SEE ALSO open(2), setuid(2), ptsname(3C), unlockpt(3C), attributes(5), standards(5)
STREAMS Programming Guide
SunOS 5.10 29 Dec 1996 grantpt(3C)