how can I lock my keyboard while I'm away from the computer without using lock command. What other commands gives me the option to lock keyboard device?
thanks (7 Replies)
Hi,
We have a lock file being created called lck8c0001 created in Unixware 2.1.2. This is locking a printer.
According to some websites, 8c0001 relates to the device name.
How does one link 8c0001 to those devices listed in the /dev folder?
I have done a ps -lp for all printers and have... (4 Replies)
Hi,
My requirement is to service a process and below is the script which i wrote for that and works fine, I have kept it in a crontab and running this everyminute, how do I lock this if its already running and i dont want to open if its running and not completed yet.
The crontab need to run... (4 Replies)
Hi,
I am working with Sun-Solaris 9 and in our application I need to connect the UPS with Serial port,after that I need to monitor it..but before stating communication,It should lock that port,To check it,first i am trying to make sure the lock directory exists and I am able to find it(/var/lock)... (0 Replies)
Hello all,
If anyone has time, I have a few questions:
How do I do the following in Linux. We are using Red Hat and Oracle Enterprise Linux, which is based on Red Hat too.
1. How to lock the account after a few (like 3) invalid password attempts?
2. How do you lock a screen after 30... (1 Reply)
Hi all,
I have to test some user priviliges. The goal is to be sure that an unauthorized user can't restart some modules (ssh, mysql etc...).
I'm trying to automate it with a shell script but in same cases I got the syslog broadcast message.
Is there any way to simply get a return code... (3 Replies)
Hi,
I want to write a code where in the file once taken genrates a lock number and other developer/user cannot take the file to make any changes in it. He gets the file only as read only. (2 Replies)
Hi All!
I am not able to lock my Ubuntu 12.04 LXDE.
Can anybody tell me the shortcut to lock the system.
I have tried all conventional keyboard shortcuts as well as buttons. (2 Replies)
Requirement:First i need to unlock the directory which i had a script for it.If i select app1 it should unlock the directory and after chnages in the script once need to lock the directory with lock command
The below highlighed variables in lock and unlock has to be changed according... (2 Replies)
Discussion started by: bhas85
2 Replies
LEARN ABOUT MINIX
plock
plock(3C) Standard C Library Functions plock(3C)NAME
plock - lock or unlock into memory process, text, or data
SYNOPSIS
#include <sys/lock.h>
int plock(int op);
DESCRIPTION
The plock() function allows the calling process to lock or unlock into memory its text segment (text lock), its data segment (data lock),
or both its text and data segments (process lock). Locked segments are immune to all routine swapping. The effective user ID of the calling
process must be super-user to use this call.
The plock() function performs the function specified by op:
PROCLOCK Lock text and data segments into memory (process lock).
TXTLOCK Lock text segment into memory (text lock).
DATLOCK Lock data segment into memory (data lock).
UNLOCK Remove locks.
RETURN VALUES
Upon successful completion, 0 is returned. Otherwise, -1 is returned and errno is set to indicate the error.
ERRORS
The plock() function fails and does not perform the requested operation if:
EAGAIN Not enough memory.
EINVAL The op argument is equal to PROCLOCK and a process lock, a text lock, or a data lock already exists on the calling process; the op
argument is equal to TXTLOCK and a text lock or a process lock already exists on the calling process; the op argument is equal to
DATLOCK and a data lock or a process lock already exists on the calling process; or the op argument is equal to UNLOCK and no lock
exists on the calling process.
EPERM The {PRIV_PROC_LOCK_MEMORY} privilege is not asserted in the effective set of the calling process.
USAGE
The mlock(3C) and mlockall(3C) functions are the preferred interfaces for process locking.
ATTRIBUTES
See attributes(5) for descriptions of the following attributes:
+-----------------------------+-----------------------------+
| ATTRIBUTE TYPE | ATTRIBUTE VALUE |
+-----------------------------+-----------------------------+
|MT-Level |MT-Safe |
+-----------------------------+-----------------------------+
SEE ALSO exec(2), exit(2), fork(2), memcntl(2), mlock(3C), mlockall(3C), attributes(5)SunOS 5.10 22 Mar 2004 plock(3C)