Sponsored Content
Top Forums UNIX for Dummies Questions & Answers [SOLVED] How can i control the same app in two servers? Post 302697335 by Newer on Thursday 6th of September 2012 04:44:42 PM
Old 09-06-2012
Hi Rudic just more thing, you ask if the file lockfile exist in the first line, but what's inside the lockfile?

---------- Post updated at 05:44 PM ---------- Previous update was at 03:58 PM ----------

Thanks one more time!! Pamu, between you and RudiC i've learn a lot, the problem it's fix it cause of you.
This User Gave Thanks to Newer For This Post:
 

8 More Discussions You Might Find Interesting

1. Programming

Deadlocked App

Hello All - We have a legacy C program running non stop on one of our servers, with several instances often running at once. Fairly regularly, one of the instances while stop outputting to the log file and will just deadlock/hang. They must be then 'kill'ed by myself. When I gdb into one of... (3 Replies)
Discussion started by: markanderson
3 Replies

2. Solaris

luminis app

The guys at SunGard want to charge a lot of $$$$ for installing Luminis and we are trying to see if this can be done without them. Their installation guide provided page #53 ( http://www.luminis.nocccd.edu/documents/Luminis%20IV/lp40000in.pdf ) doesn't really tell you much. All they say is that... (4 Replies)
Discussion started by: ceci1
4 Replies

3. Red Hat

userid with nothing to do on the os/app

Hi All, I got this userid apache with the same userid and groupid and /sbin/nologin and the /www/a home folder is empty. Can I just delete this userid? How can I investigate if userid have something to do with the application? Thanks for any comment you may add. (1 Reply)
Discussion started by: itik
1 Replies

4. Shell Programming and Scripting

[solved] merging two files and writing to another file- solved

i have two files as file1: 1 2 3 file2: a b c and the output should be: file3: 1~a 2~b 3~c (1 Reply)
Discussion started by: mlpathir
1 Replies

5. Emergency UNIX and Linux Support

[Solved] DCMU (disk control and monitor utility) sun fire

Hi , during 2 weeks i´ve been trying to find them. i need DCMU packets for managing internal disks on sun fire x4500 and sun fire x4600 on rhel. i have opened to tickets to myoraclesupport but no answer. please anybody could tell me a link or anythiing?? i´ve been searching and searching... (1 Reply)
Discussion started by: pabloli150
1 Replies

6. Solaris

Problem with /app

Hi folks, i have a problem with my /app directory on solaris 10.It is mounted under rpool root and sometimes it increase dimension bringing root out of space.I want to mount /app under different position, maybe under secondary hardisk for which i have created a mount point with zfs pool...How... (10 Replies)
Discussion started by: mattpunk
10 Replies

7. UNIX for Dummies Questions & Answers

[Solved] Removing control-m characters from shell script

Hi All, I need to remove control m character from a file. Steps which i am doing in shell script are: 1) We are comparing the header of the file to the database table header Here the file header has control-m characters. How do i remove it. Please help. Below are the steps i am using,... (12 Replies)
Discussion started by: abhi_123
12 Replies

8. Programming

Wuhan Coronavirus Status App for China - Rapid Prototype using MQTT and the IoT OnOff IOS App

With a little bit of work, was able to build a nice "Wuhan Coronavirus Status" app using MQTT and the IoT-OnOff app. More on this technique here: ESP32 (ESP-WROOM-32) as an MQTT Client Subscribed to Linux Server Load Average Messages The result turned out nice, I think. I like the look and... (10 Replies)
Discussion started by: Neo
10 Replies
maillock(3MAIL) 					  User Mailbox Library Functions					   maillock(3MAIL)

NAME
maillock, mailunlock, touchlock - functions to manage lockfile(s) for user's mailbox SYNOPSIS
cc [ flag ... ] file ... -lmail [ library ... ] #include <maillock.h> int maillock(const char *user, int retrycnt); void mailunlock(void); void touchlock(void); DESCRIPTION
The maillock() function attempts to create a lockfile for the user's mailfile. If a lockfile already exists, and it has not been modified in the last 5 minutes, maillock() will remove the lockfile and set its own lockfile. It is crucial that programs locking mail files refresh their locks at least every three minutes to maintain the lock. Refresh the lockfile by calling the touchlock() function with no arguments. The algorithm used to determine the age of the lockfile takes into account clock drift between machines using a network file system. A zero is written into the lockfile so that the lock will be respected by systems running the standard version of System V. If the lockfile has been modified in the last 5 minutes the process will sleep until the lock is available. The sleep algorithm is to sleep for 5 seconds times the attempt number. That is, the first sleep will be for 5 seconds, the next sleep will be for 10 seconds, etc. until the number of attempts reaches retrycnt. When the lockfile is no longer needed, it should be removed by calling mailunlock(). The user argument is the login name of the user for whose mailbox the lockfile will be created. maillock() assumes that user's mailfiles are in the ``standard'' place as defined in <maillock.h>. RETURN VALUES
Upon successful completion, .maillock() returns 0. Otherwise it returns -1. FILES
/var/mail/* user mailbox files /var/mail/*.lock user mailbox lockfiles ATTRIBUTES
See attributes(5) for descriptions of the following attributes: +-----------------------------+-----------------------------+ | ATTRIBUTE TYPE | ATTRIBUTE VALUE | +-----------------------------+-----------------------------+ |MT-Level |Unsafe | +-----------------------------+-----------------------------+ SEE ALSO
libmail(3LIB),attributes(5) NOTES
The mailunlock() function will only remove the lockfile created from the most previous call to maillock(). Calling maillock() for different users without intervening calls to mailunlock() will cause the initially created lockfile(s) to remain, potentially blocking subsequent message delivery until the current process finally terminates. SunOS 5.10 29 Mar 1999 maillock(3MAIL)
All times are GMT -4. The time now is 09:07 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy