| Summary: | Bad command-line example in handbook | ||
|---|---|---|---|
| Product: | Documentation | Reporter: | Björn Heidotting <b.heidotting> |
| Component: | Books & Articles | Assignee: | Benjamin Kaduk <bjk> |
| Status: | Closed FIXED | ||
| Severity: | Affects Only Me | ||
| Priority: | Normal | ||
| Version: | Latest | ||
| Hardware: | Any | ||
| OS: | Any | ||
|
Description
Björn Heidotting
2012-04-17 11:50:02 UTC
On Tue, Apr 17, 2012 at 10:45:08AM +0000, Björn Heidotting wrote:
>
> >Description:
> In Chapter 19.12 (Backup Basics) there is a bad command-line example. The handbooks shows the following:
>
> Example 19-2. Using dump over ssh with RSH set
> # RSH=/usr/bin/ssh /sbin/dump -0uan -f targetuser@targetmachine.example.com:/dev/sa0 /usr
>
> This won't work, because this are two commands which are not separated.
> ...
Actually, this line is correct. At least, for sh(1).
------------------------------------------------------------------------------
Simple Commands
If a simple command has been recognized, the shell performs the following
actions:
1. Leading words of the form ``name=value'' are stripped off and
assigned to the environment of the simple command. Redirection
operators and their arguments (as described below) are stripped off
and saved for processing.
-- (c) man 1 sh --------------------------------------------------------------
An example:
nx6125% /bin/sh
$ echo $VAR
$ VAR='tuesday' /bin/sh -c 'echo $VAR'
tuesday
$ echo $VAR
$
--
Best regards,
Taras Korenko
I´d like to inform you that the command-line in question is correct and works. It´s a little confusing when I first read it, and especially for beginners. But still, it works. So it´s no longer an issue. PR can be closed. Regards, Björn Heidotting ________________________________ Naber GmbH Entwicklung - Produktion - Vertrieb Björn Heidotting EDV Enschedestr. 24 48529 Nordhorn Telefon: +49 (0) 5921 - 704 161 Telefax: +49 (0) 5921 - 704 189 Internet: www.naber.de mailto: b.heidotting@naber.de<mailto:b.heidotting@naber.de> Amtsgericht Osnabrück, HRB 130146 Geschäftsführer: Ingrid Naber Hans-Joachim Naber Lasse Naber USt-Id-Nr.: DE117037037 ________________________________ Bitte beachten Sie: Diese E-Mail kann vertrauliche und/oder rechtlich geschützte Informationen enthalten. Der Inhalt ist ausschlieÃlich für den bezeichneten Adressaten bestimmt. Sollten Sie nicht der richtige Adressat bzw. dessen Vertreter sein, setzen Sie sich bitte mit dem Absender der E-Mail in Verbindung. Jede Form der Veröffentlichung, Vervielfältigung oder Weitergabe des Inhalts fehlgeleiteter E-Mails ist unzulässig. Wir möchten Sie weiter darauf hinweisen, dass die Kommunikation per E-Mail über das Internet unsicher ist. Es sind daher keine Ansprüche aus dem Umstand herzuleiten, dass Nachrichten und Dateianhänge von Dritten gelesen und manipuliert werden, verloren gehen oder von Viren befallen sein können. Die mit dieser E-Mail ggf. gelieferten Informationen bzw. Daten sind mit gröÃter Sorgfalt zusammengestellt worden. Dennoch können fehlerhafte Angaben nicht völlig ausgeschlossen werden. Die Naber GmbH haftet nicht für eventuelle Fehler und deren Folgen. Please note: This email may contain confidential and/or legally protected information. The contents are only intended for the designated recipient. If you are not the intended recipient or his representative, please contact the sender of the email. Any form of publication, reproduction or disclosure of the content or wrongly routed emails is not permissible. We would like to point out that communication by email via the Internet is unsafe. Therefore, no claims can be derived in the event that messages and attached files are read and manipulated by third parties, get lost or infected by viruses. Any information or data contained in this email has been compiled with the utmost care. Incorrect statements cannot, however, be fully excluded. Naber GmbH is not liable for any errors or their consequences. ________________________________ State Changed From-To: open->closed the fix and original have two different meanings. The fix will last beyond the first command, the latter will nt State Changed From-To: closed->open This can be more portable (work with csh and sh) using env; http://www.bayofrum.net/~crees/patches/handbook-dump-over-ssh.diff Responsible Changed From-To: freebsd-doc->bjk I will take this one. State Changed From-To: open->closed Committed in r38941. Thanks for following up on the closed PR. |