12-11-2011
also, kindly check if the port opened by your app, has a lock file created ?
This User Gave Thanks to solaris040 For This Post:
9 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
hi. Im trying to install a switch.
And the manual says i should type a command including a SerialPortDevicePath. which is the filepath to serial port used for connection.
However.. nothing about how to find this info.
Could anyone help me where to find this path?
thx
mr.T (6 Replies)
Discussion started by: tyskertøs
6 Replies
2. Emergency UNIX and Linux Support
Dear All,
I was having powerpath 5.2 on SUN server with SVM connected to CLARIION box.Please find the following output :
root # powermt display dev=all
Pseudo name=emcpower3a
CLARiiON ID=CK200073400372
Logical device ID=60060160685D1E004DD97FB647BFDC11
state=alive; policy=CLAROpt;... (1 Reply)
Discussion started by: Reboot
1 Replies
3. Linux
A product I am working on manages storage. We are currently porting it from Solaris to Linux.
The product allows its user, among other things, to add and remove file server volumes, where these volumes are exported using the NFS or the CIFS protocol.
The problem is that when the user requests to... (5 Replies)
Discussion started by: dhzdh
5 Replies
4. Shell Programming and Scripting
Hi,
I have line in input file as below:
3G_CENTRAL;INDONESIA_(M)_TELKOMSEL;SPECIAL_WORLD_GRP_7_FA_2_TELKOMSEL
My expected output for line in the file must be :
"1-Radon1-cMOC_deg"|"LDIndex"|"3G_CENTRAL|INDONESIA_(M)_TELKOMSEL"|LAST|"SPECIAL_WORLD_GRP_7_FA_2_TELKOMSEL"
Can someone... (7 Replies)
Discussion started by: shis100
7 Replies
5. UNIX for Dummies Questions & Answers
Hi Everyone,
I am trying to remove a directory:
$ rm -rf directory_name/
rm: cannot remove `directory_name/filename': Device or resource busy
What does this mean, and why can't I remove these files? I already tried moving into the directory, and removing the files individually, but I... (7 Replies)
Discussion started by: Anna_Z
7 Replies
6. Red Hat
Hi,
I´ve given only this info to configure a network interface : "port 1 PCI 4"
I´ve been searching for any kind of relationship in the system which allow me to find the etc that must be configured...
Please, could anybody help me?
rhxx:#/root# lspci |grep -i "PCI BRIDGE"
00:01.0 PCI... (0 Replies)
Discussion started by: pabloli150
0 Replies
7. SCO
Hi there
After making a backup copy of it sometimes happens that when I want to unmount an NFS indicates the error:umount: /path_mount busy: Device busy (Error 16)
if I run lsoff, I can not find the process that is blocking the application.
I'm using OpenServer 5.0.2c as one NFS server ... (14 Replies)
Discussion started by: flako
14 Replies
8. Solaris
Hi all, I have a LUN that is in "Online Busy" when I issue the dev_gestate subcommand of luxadm:
root@es088wb6:~# luxadm -v -e dev_getstate /dev/rdsk/c21t50050763090887FEd4s2
phys path = "/devices/pci@6c0/pci@1/pci@0/pci@4/SUNW,qlc@0/fp@0,0/ssd@w50050763090887fe,4:c,raw"
... (5 Replies)
Discussion started by: ludiegu
5 Replies
9. Shell Programming and Scripting
Hello.
System : opensuse leap 42.3
I have a bash script that build a text file.
I would like the last command doing :
print_cmd -o page-left=43 -o page-right=22 -o page-top=28 -o page-bottom=43 -o font=LatinModernMono12:regular:9 some_file.txt
where :
print_cmd ::= some printing... (1 Reply)
Discussion started by: jcdole
1 Replies
SHLOCK(1) BSD General Commands Manual SHLOCK(1)
NAME
shlock -- create or verify a lock file for shell scripts
SYNOPSIS
shlock [-du] [-p PID] -f lockfile
DESCRIPTION
The shlock command can create or verify a lock file on behalf of a shell or other script program. When it attempts to create a lock file, if
one already exists, shlock verifies that it is or is not valid. If valid, shlock will exit with a non-zero exit code. If invalid, shlock
will remove the lock file, and create a new one.
shlock uses the link(2) system call to make the final target lock file, which is an atomic operation (i.e. "dot locking", so named for this
mechanism's original use for locking system mailboxes). It puts the process ID ("PID") from the command line into the requested lock file.
shlock verifies that an extant lock file is still valid by using kill(2) with a zero signal to check for the existence of the process that
holds the lock.
The -d option causes shlock to be verbose about what it is doing.
The -f argument with lockfile is always required.
The -p option with PID is given when the program is to create a lock file; when absent, shlock will simply check for the validity of the lock
file.
The -u option causes shlock to read and write the PID as a binary pid_t, instead of as ASCII, to be compatible with the locks created by
UUCP.
EXIT STATUS
A zero exit code indicates a valid lock file.
EXAMPLES
BOURNE SHELL
#!/bin/sh
lckfile=/tmp/foo.lock
if shlock -f ${lckfile} -p $$
then
# do what required the lock
rm ${lckfile}
else
echo Lock ${lckfile} already held by `cat ${lckfile}`
fi
C SHELL
#!/bin/csh -f
set lckfile=/tmp/foo.lock
shlock -f ${lckfile} -p $$
if ($status == 0) then
# do what required the lock
rm ${lckfile}
else
echo Lock ${lckfile} already held by `cat ${lckfile}`
endif
The examples assume that the file system where the lock file is to be created is writable by the user, and has space available.
HISTORY
shlock was written for the first Network News Transfer Protocol (NNTP) software distribution, released in March 1986. The algorithm was sug-
gested by Peter Honeyman, from work he did on HoneyDanBer UUCP.
AUTHORS
Erik E. Fair <fair@clock.org>
BUGS
Does not work on NFS or other network file system on different systems because the disparate systems have disjoint PID spaces.
Cannot handle the case where a lock file was not deleted, the process that created it has exited, and the system has created a new process
with the same PID as in the dead lock file. The lock file will appear to be valid even though the process is unrelated to the one that cre-
ated the lock in the first place. Always remove your lock files after you're done.
BSD
June 29, 1997 BSD