echo "*** mkfs"
+# this test only works for version 1 logs currently
lversion=1
lsize=16777216
_scratch_mkfs_xfs -lsize=$lsize,version=$lversion >$tmp.mkfs0 2>&1
[ $? -ne 0 ] && \
_notrun "Cannot mkfs for this test using MKFS_OPTIONS specified"
-_filter_mkfs <$tmp.mkfs0 2>/dev/null
+_filter_mkfs <$tmp.mkfs0 2>$tmp.mkfs1
+. $tmp.mkfs1
+[ $lversion -ne 1 ] && \
+ _notrun "Cannot run this test yet using MKFS_OPTIONS specified"
+
_check_mount
_check_require_logdev
void
lock_mtab (void) {
+#if 0 /* nathans: dont limit, we are forcing lots of parallel accesses */
int tries = 3;
+#endif
char linktargetfile[PATH_MAX + 20];
if (!signals_have_been_setup) {
if (fd < 0) {
int errsv = errno;
/* Strange... Maybe the file was just deleted? */
+#if 0 /* nathans: dont limit, we are forcing lots of parallel accesses */
if (errno == ENOENT && tries-- > 0)
+#endif
+ if (errno == ENOENT)
continue;
- fprintf(stderr, "can't open lock file %s: %s "
- "(use -n flag to override)",
+ fprintf(stderr, "can't open lock file %s: %s\n",
mounted_lock, strerror (errsv));
exit(1);
}
if (j == 0) {
/* We made the link. Now claim the lock. */
if (fcntl (fd, F_SETLK, &flock) == -1 &&
- errno != EBUSY) {
+ errno != EBUSY && errno != EAGAIN) {
int errsv = errno;
printf(_("Can't lock lock file %s: %s\n"),
mounted_lock, strerror (errsv));
/* Someone else made the link. Wait. */
alarm(LOCK_TIMEOUT);
if (fcntl (fd, F_SETLKW, &flock) == -1 &&
- errno != EBUSY) {
+ errno != EBUSY && errno != EAGAIN) {
int errsv = errno;
fprintf(stderr, "can't lock lock file %s: %s",
mounted_lock, (errno == EINTR) ?