'\"macro stdmacro .\" .\" Copyright (c) 2000 Silicon Graphics, Inc. All Rights Reserved. .\" .\" This program is free software; you can redistribute it and/or modify it .\" under the terms of the GNU General Public License as published by the .\" Free Software Foundation; either version 2 of the License, or (at your .\" option) any later version. .\" .\" This program is distributed in the hope that it will be useful, but .\" WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY .\" or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License .\" for more details. .\" .\" .TH PMLOCK 1 "PCP" "Performance Co-Pilot" .SH "نام (NAME)" \f3pmlock\f1 \- قفل متقابل (mutex) ساده مبتنی بر فایل .SH "خلاصه دستور (SYNOPSIS)" .B $PCP_BINADM_DIR/pmlock [\fB\-i\fR \fIident\fR] [\fB\-v\fR] .I file .SH "توضیحات (DESCRIPTION)" .B pmlock تلاش می‌کند تا با ایجاد یک .I file با اندازه صفر و حالت (mode) دسترسی 0، یک قفل انحصاری به دست آورد. .PP گزینه .I \-i این رفتار را تغییر می‌دهد تا .I ident را به همراه یک نویسه خط جدید (newline) درون .IR file بنویسد؛ در این حالت، دسترسی فایل 0444 خواهد بود. .I ident یک رشته دلخواه است، اما طبق عرف، شناسه فرایند (PID) قفل‌کننده و در پی آن نام یا شناسه دستور یا اسکریپت قفل‌کننده است. .PP وضعیت خروج در صورت موفقیت 0 و در صورت شکست 1 است. .PP برای آزادسازی قفل، .I file را با .BR rm (1) یا .BR unlink (2) حذف کنید. .PP در صورت بروز شکست، گزینه .B \-v پیامی توضیحی در .I stderr تولید می‌کند. .SH "همچنین ببینید (SEE ALSO)" .BR rm (1) و .BR unlink (2).