From owner-freebsd-bugs Fri Jun 9 11:21:04 1995 Return-Path: bugs-owner Received: (from majordom@localhost) by freefall.cdrom.com (8.6.10/8.6.6) id LAA24160 for bugs-outgoing; Fri, 9 Jun 1995 11:21:04 -0700 Received: from irz301.inf.tu-dresden.de (irz301.inf.tu-dresden.de [141.76.1.11]) by freefall.cdrom.com (8.6.10/8.6.6) with SMTP id LAA24124 for ; Fri, 9 Jun 1995 11:20:56 -0700 Received: from sax.sax.de by irz301.inf.tu-dresden.de with SMTP (5.67b+/DEC-Ultrix/4.3) id AA16502; Fri, 9 Jun 1995 20:20:53 +0200 Received: by sax.sax.de (8.6.12/8.6.12-s1) with UUCP id UAA23387; Fri, 9 Jun 1995 20:20:52 +0200 Received: (from j@localhost) by uriah.heep.sax.de (8.6.11/8.6.9) id TAA04032; Fri, 9 Jun 1995 19:35:24 +0200 From: J Wunsch Message-Id: <199506091735.TAA04032@uriah.heep.sax.de> Subject: Re: dump having problems with remote tape drive To: ruplit@fitipc31.tu-graz.ac.at (Michael Ruplitsch) Date: Fri, 9 Jun 1995 19:35:24 +0200 (MET DST) Cc: freebsd-bugs@FreeBSD.org In-Reply-To: from "Michael Ruplitsch" at Jun 9, 95 03:11:07 pm Reply-To: joerg_wunsch@uriah.heep.sax.de (Joerg Wunsch) X-Phone: +49-351-2012 669 X-Mailer: ELM [version 2.4 PL23] Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit Content-Length: 1497 Sender: bugs-owner@FreeBSD.org Precedence: bulk As Michael Ruplitsch wrote: > > Hi, Moin, > Today I wanted to use `dump' to backup my hard drive onto a remote scsi tape > drive. dump terminated with the message: > Cannot open output "/dev/rmt/ctapen". > I found out that dump tries to open the remote tape for reading and > writing (by sending "Otape-device\n2\n" to rmt where 2 means O_RDWR) > instead of opening it for writing only (`1' instead of `2'). Is this a bug > or is it a feature of dump? A feature. Why do you think _this_ might be the problem? j@uriah 140% /sbin/rdump 9Bf 150000 localhost:/dev/rst0 / DUMP: Date of this level 9 dump: Fri Jun 9 19:31:06 1995 DUMP: Date of last level 8 dump: Mon Jun 5 15:07:39 1995 DUMP: Dumping /dev/rsd0a (/) to /dev/rst0 on host localhost DUMP: mapping (Pass I) [regular files] DUMP: mapping (Pass II) [directories] DUMP: estimated 540 tape blocks on 0.00 tape(s). DUMP: dumping (Pass III) [directories] DUMP: dumping (Pass IV) [regular files] DUMP: DUMP: 537 tape blocks on 1 volumes(s) DUMP: Closing /dev/rst0 DUMP: DUMP IS DONE Is there any reason why a tape driver should not allow an O_RDWR access where it does allow O_WRONLY? Anyway, i found another bogon while i've been looking at this: dump doesn't use an absolute path (/etc/rmt) as it ought to be; instead it thinks it should rely on "rmt" only. -- cheers, J"org joerg_wunsch@uriah.heep.sax.de -- http://www.sax.de/~joerg/ Never trust an operating system you don't have sources for. ;-)