From: | Bill Hacker <wbh@xxxxxxxxxxxxx> |
Date: | Mon, 16 Feb 2009 22:55:30 +0800 |
Am Sun, 15 Feb 2009 21:38:54 -0800 (PST) schrieb Matthew Dillon <dillon@apollo.backplane.com>:
:I have what appears to be a 'Catch 22', wherein: : :hammer mirror-stream /master <user>@<remote_IP>:/new_slave : :returns: : :PFS slave /new-slave does not exist. :Do you want to create a new slave PFS? (yes|no) No terminal for response :Aborting operation :validate_mrec_header: short read : :'No terminal for response' .was ass u me ed to be a byproduct of comign :in off an Xfce4-terminal (Xorg & Xfce4 are quite happy on 2.3.0, BTW) : :Dropped back out to the raw tty0 console and tried it from there. : :No joy.
Definitely a bug in the hammer utility, I'm not sure there is anything I can do about it though because the remote ssh
connection has no channel to accept a Y or N answer... stdin and
stdout are used for the protocol stream and I think stderr is output
only.
In anycase, I think what this means is that this feature currently only works if the slave is local (non-ssh connection). So you would be able to do it with <remote_master> <local_slave>.
Hm, I remember that we implemented this feature (auto-creation of
slaves) so that it can operate over ssh. And IIRC, it once worked for me using ssh (I am not sure if this was a remote machine or not).
Does this mean, it is broken?
:Command *appear* to succeed if/as/when I *manually* create 'new_slave' :in advance with a matching shared_uuid. A local mirror-copy to it :suceeds, with new_slave showing the files mirrored. : :However, while the -vvv flag gives 5-sec updates, they all show a newer :starting point that pfs-status has for the target, and the contents of :the slave never change.
You must access the slave via its softlink to get the latest version synced from the master. If you try to access the slave via a null-mount you will be accessing a snapshot of the slave, not the current state of the slave. The null mount locks in the transaction id of the slave.
:By way of contrast, mirror-stream between on-box master and on-box slave : - same command otherwise - works fine. No chdir needed to see the :updates, just a 'View, Reload' in thunar and sputniks.
You are probably accessing it via the softlink, yes? The gui is probably using an absolute path. If you were to CD into a sub-directory (even through the softlink), you would be accessing a snapshot as-of when you did the CD, not the latest synced copy.
:Query: Can the loop that seeks a 'yes' be changed to a 5-second :countdown-timer with a message such as:
:
:Creating <new_slave> Hit Ctrl-c to abort
:
:.absent which it JFDI.
:
:Thanks,
:
:Bill Hacker
That won't work, the target over an ssh link has no tty channel.
Adding an option to create the slave automatically and passing it to the target hammer utility when it is run via the ssh, so it never has to ask at all, would work. If someone would like to do that and submit a patch, I don't think it would take more then 20 minutes of programming.
You mean, something like a -f (force) option? Should be damn easy to implement. I can do that, once I sit in front of a real computer
(with DragonFly) again :)
Regards,
Michael