Sponsored Content
Full Discussion: Permission to kill a process
Top Forums UNIX for Advanced & Expert Users Permission to kill a process Post 302955549 by Corona688 on Friday 18th of September 2015 12:05:18 PM
Old 09-18-2015
This may open other holes if not done carefully however (who is allowed to create files there?)
This User Gave Thanks to Corona688 For This Post:
 

10 More Discussions You Might Find Interesting

1. UNIX for Advanced & Expert Users

When kill doesnt work, how to kill a process ?

Hi All, I am unable to kill a process using kill command. I am using HP-UX system. I have tried with kill -9 and i have root privilages. How can i terminate this daemon ? ? ? Regards, Vijay Hegde (3 Replies)
Discussion started by: VijayHegde
3 Replies

2. Shell Programming and Scripting

how to start a process and make it sleep for 5 mins and then kill that process

how to start a process and make it sleep for 5 mins and then kill that process (6 Replies)
Discussion started by: shrao
6 Replies

3. Programming

kill(0,-9) don't kill the process

Hi all i have simple c program , when i wish to kill the app im using kill(0,-9) , but it seams this command don't do any thing and the program. just ignore it . what im doing wrong here ? im using HP-UX ia64 Thanks (9 Replies)
Discussion started by: umen
9 Replies

4. Shell Programming and Scripting

Kill a process without using kill command

Sorry, posted the question in other forum. (0 Replies)
Discussion started by: sudhamacs
0 Replies

5. Linux

Kill a process without using kill command

I want to Kill a process without using kill command as i don't have privileges to kill the process. I know the pid and i am using Linux 2.6.9 OS. (6 Replies)
Discussion started by: sudhamacs
6 Replies

6. Shell Programming and Scripting

Shell Script to Kill Process(number of process) Unix/Solaris

Hi Experts, we do have a shell script for Unix Solaris, which will kill all the process manullay, it used to work in my previous env, but now it is throwing this error.. could some one please help me to resolve it This is how we execute the script (and this is the requirement) ... (2 Replies)
Discussion started by: jonnyvic
2 Replies

7. Solaris

sudo for permission kill -HUP

Hi, I'm trying to provide "/usr/bin/kill -HUP" command to one of the user using sudo file. I have configured sudo as following: $cat /etc/sudoers User_Alias AA=conadmin Cmnd_Alias KILL1=/usr/bin/kill -HUPAA ALL=NOPASSWD:KILL1 When I login as the user and execute 'sudo -l' command, it... (2 Replies)
Discussion started by: mohzub
2 Replies

8. UNIX for Dummies Questions & Answers

Script to start background process and then kill process

What I need to learn is how to use a script that launches background processes, and then kills those processes as needed. The script successfully launches the script. But how do I check to see if the job exists before I kill it? I know my problem is mostly failure to understand parameter... (4 Replies)
Discussion started by: holocene
4 Replies

9. Shell Programming and Scripting

Kill an specific process ID using the KILL and GREP commands

Good afternoon I need to KILL a process in a single command sentence, for example: kill -9 `ps -aef | grep 'CAL255.4ge' | grep -v grep | awk '{print $2}'` That sentence Kills the process ID corresponding to the program CAL255.4ge. However it is possible that the same program... (6 Replies)
Discussion started by: enriquegm82
6 Replies

10. UNIX for Beginners Questions & Answers

How do I give permission for the kill command?

<?php $comando = "kill -9 3104"; $output = shell_exec($comando); ?> I am running this web page, but it does not execute the command, in the log file it looks like this: sh: 1: kill: Operation not permitted How do I give permission to execute the command? (1 Reply)
Discussion started by: Rodrigo_Bueno
1 Replies
NDBM(3) 						     Library Functions Manual							   NDBM(3)

NAME
dbm_open, dbm_close, dbm_fetch, dbm_store, dbm_delete, dbm_firstkey, dbm_nextkey, dbm_error, dbm_clearerr - data base subroutines SYNOPSIS
#include <ndbm.h> typedef struct { char *dptr; int dsize; } datum; DBM *dbm_open(file, flags, mode) char *file; int flags, mode; void dbm_close(db) DBM *db; datum dbm_fetch(db, key) DBM *db; datum key; int dbm_store(db, key, content, flags) DBM *db; datum key, content; int flags; int dbm_delete(db, key) DBM *db; datum key; datum dbm_firstkey(db) DBM *db; datum dbm_nextkey(db) DBM *db; int dbm_error(db) DBM *db; int dbm_clearerr(db) DBM *db; DESCRIPTION
These functions maintain key/content pairs in a data base. The functions will handle very large (a billion blocks) databases and will access a keyed item in one or two file system accesses. This package replaces the earlier dbm(3x) library, which managed only a single database. Keys and contents are described by the datum typedef. A datum specifies a string of dsize bytes pointed to by dptr. Arbitrary binary data, as well as normal ASCII strings, are allowed. The data base is stored in two files. One file is a directory containing a bit map and has `.dir' as its suffix. The second file contains all data and has `.pag' as its suffix. Before a database can be accessed, it must be opened by dbm_open. This will open and/or create the files file.dir and file.pag depending on the flags parameter (see open(2)). Once open, the data stored under a key is accessed by dbm_fetch and data is placed under a key by dbm_store. The flags field can be either DBM_INSERT or DBM_REPLACE. DBM_INSERT will only insert new entries into the database and will not change an existing entry with the same key. DBM_REPLACE will replace an existing entry if it has the same key. A key (and its associated contents) is deleted by dbm_delete. A linear pass through all keys in a database may be made, in an (apparently) random order, by use of dbm_firstkey and dbm_nextkey. Dbm_firstkey will return the first key in the database. Dbm_nextkey will return the next key in the database. This code will traverse the data base: for (key = dbm_firstkey(db); key.dptr != NULL; key = dbm_nextkey(db)) Dbm_error returns non-zero when an error has occurred reading or writing the database. Dbm_clearerr resets the error condition on the named database. DIAGNOSTICS
All functions that return an int indicate errors with negative values. A zero return indicates ok. Routines that return a datum indicate errors with a null(0) dptr. If dbm_store called with a flags value of DBM_INSERT finds an existing entry with the same key it returns 1. BUGS
The `.pag' file will contain holes so that its apparent size is about four times its actual content. Older UNIX systems may create real file blocks for these holes when touched. These files cannot be copied by normal means (cp, cat, tp, tar, ar) without filling in the holes. Dptr pointers returned by these subroutines point into static storage that is changed by subsequent calls. The sum of the sizes of a key/content pair must not exceed the internal block size (currently 4096 bytes). Moreover all key/content pairs that hash together must fit on a single block. Dbm_store will return an error in the event that a disk block fills with inseparable data. Dbm_delete does not physically reclaim file space, although it does make it available for reuse. The order of keys presented by dbm_firstkey and dbm_nextkey depends on a hashing function, not on anything interesting. SEE ALSO
dbm(3X) 4.3 Berkeley Distribution May 20, 1986 NDBM(3)
All times are GMT -4. The time now is 10:05 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy