aboutsummaryrefslogtreecommitdiff
path: root/doc/sg_dd.8
diff options
context:
space:
mode:
authorDouglas Gilbert <dgilbert@interlog.com>2008-07-15 02:47:47 +0000
committerDouglas Gilbert <dgilbert@interlog.com>2008-07-15 02:47:47 +0000
commitf514890a9e9eefffc6487bf67c5db29fe005f57e (patch)
treea5b5af1c6fd086e0a54ca686f26c115db172c094 /doc/sg_dd.8
parent79e83bc385a5ead70b728f64829d1bebeba208dc (diff)
downloadsg3_utils-f514890a9e9eefffc6487bf67c5db29fe005f57e.tar.gz
sg_dd: flock(LOCK_EX|LOCK_NB) option
git-svn-id: https://svn.bingwo.ca/repos/sg3_utils/trunk@186 6180dd3e-e324-4e3e-922d-17de1ae2f315
Diffstat (limited to 'doc/sg_dd.8')
-rw-r--r--doc/sg_dd.813
1 files changed, 12 insertions, 1 deletions
diff --git a/doc/sg_dd.8 b/doc/sg_dd.8
index 2e585373..e98124fb 100644
--- a/doc/sg_dd.8
+++ b/doc/sg_dd.8
@@ -1,4 +1,4 @@
-.TH SG_DD "8" "April 2008" "sg3_utils\-1.26" SG3_UTILS
+.TH SG_DD "8" "July 2008" "sg3_utils\-1.27" SG3_UTILS
.SH NAME
sg_dd \- copies data to and from files and devices. Specialised for
devices that understand the SCSI command set.
@@ -243,6 +243,14 @@ excl
causes the O_EXCL flag to be added to the open of \fIIFILE\fR and/or
\fIOFILE\fR.
.TP
+flock
+after opening the associated file (i.e. \fIIFILE\fR and/or \fIOFILE\fR)
+an attempt is made to get an advisory exclusive lock with the flock()
+system call is made. The flock arguments are "FLOCK_EX | FLOCK_NB" which
+will cause the lock to be taken if available else a "temporarily unavailable"
+error is generated. An exit status of 90 is produced in the latter case
+and no copy is done.
+.TP
fua
causes the FUA (force unit access) bit to be set in SCSI READ and/or WRITE
commands. This only has an effect with sg devices or block devices
@@ -411,6 +419,9 @@ the sg3_utils(8) man page. Since this utility works at a higher level
than individual commands, and there are 'coe' and 'retries' flags,
individual SCSI command failures do not necessary cause the process
to exit.
+.PP
+An additional exit status of 90 is generated if the flock flag is given
+and some other process holds the advisory exclusive lock.
.SH AUTHORS
Written by Doug Gilbert and Peter Allworth.
.SH "REPORTING BUGS"