#273042 - 13/01/2006 21:26
Re: empeg in cold weather. it's ch-ch-chilly and it won't b-b-boot. He
[Re: mlord]
|
carpal tunnel
Registered: 20/12/1999
Posts: 31597
Loc: Seattle, WA
|
Excellent. What are the exact FTP commands you're using? Of course, I'm sure you're testing on Linux. It would be cool if someone else could follow up and make sure the same command work with the Windows FTP command-line. They *should* but of course, who knows. It's Windows after all. I'd do it myself but I'm doing other stuff today...
|
Top
|
|
|
|
#273043 - 13/01/2006 21:58
Re: empeg in cold weather. it's ch-ch-chilly and it won't b-b-boot. He
[Re: tfabris]
|
carpal tunnel
Registered: 29/08/2000
Posts: 14493
Loc: Canada
|
Quote: Excellent. What are the exact FTP commands you're using?
Entire disk: GET /dev/hda
Any single partition, same command, change hda to hda3 or whatever (I don't remember which partition holds the dynamic data).
|
Top
|
|
|
|
#273044 - 13/01/2006 22:17
Re: empeg in cold weather. it's ch-ch-chilly and it won't b-b-boot. He
[Re: mlord]
|
carpal tunnel
Registered: 20/12/1999
Posts: 31597
Loc: Seattle, WA
|
So the entire disk includes all partitions including the dynamic data?
so an example of an entire disk backup for a two drive player is:
GET /dev/hda GET /dev/hdb
I assume you have to put the FTP software into binary mode first... or at least that's what you'd want to do on windows anyway...
To restore, what would the PUT commands look like?
|
Top
|
|
|
|
#273045 - 13/01/2006 22:22
Re: empeg in cold weather. it's ch-ch-chilly and it won't b-b-boot. He
[Re: tfabris]
|
carpal tunnel
Registered: 29/08/2000
Posts: 14493
Loc: Canada
|
Yup, that's all correct.
And going the other way is just a simple PUT command. For example, these two commands copy the drive to a PC, and then write it back again (pointless in itself):
GET /dev/hda junk PUT junk /dev/hda
Those just use "junk" as the name for the file on the PC side. Or one could omit that, and the two lines become:
GET /dev/hda put hda /dev/hda
Cheers
|
Top
|
|
|
|
#273046 - 13/01/2006 22:36
Re: empeg in cold weather. it's ch-ch-chilly and it won't b-b-boot. He
[Re: mlord]
|
carpal tunnel
Registered: 20/12/1999
Posts: 31597
Loc: Seattle, WA
|
Okay, very very cool. I shall update the FAQ entry with this, soon.
|
Top
|
|
|
|
#273047 - 15/01/2006 19:57
Re: empeg in cold weather. it's ch-ch-chilly and it won't b-b-boot. He
[Re: tfabris]
|
addict
Registered: 18/08/2002
Posts: 544
Loc: New Jersey
|
and make sure it's in E N G L I S H for the rest of us illiterates!!!
_________________________
...One man gathers what another man spills
|
Top
|
|
|
|
#273048 - 15/01/2006 20:47
Re: empeg in cold weather. it's ch-ch-chilly and it won't b-b-boot. He
[Re: mlord]
|
carpal tunnel
Registered: 20/12/1999
Posts: 31597
Loc: Seattle, WA
|
Quick question: Do you need to put the player into RW mode before doing the PUT commands?
|
Top
|
|
|
|
#273049 - 15/01/2006 21:03
Re: empeg in cold weather. it's ch-ch-chilly and it won't b-b-boot. He
[Re: tfabris]
|
carpal tunnel
Registered: 25/12/2000
Posts: 16706
Loc: Raleigh, NC US
|
No. It's safer to leave them RO. Even safer to unmount them altogether, but that's not really possible.
_________________________
Bitt Faulk
|
Top
|
|
|
|
#273050 - 15/01/2006 21:05
Re: empeg in cold weather. it's ch-ch-chilly and it won't b-b-boot. He
[Re: mlord]
|
carpal tunnel
Registered: 25/12/2000
Posts: 16706
Loc: Raleigh, NC US
|
Actually, Mark, will the NFS server work if the disk has just been replaced? And will it understand what /dev/hda even is? It is a filesystem construct, after all.
And, in the case of a restore onto an "old", already-built disk, is Hijack going to panic when it notices a filesystem inconsistency?
Edited by wfaulk (15/01/2006 21:09)
_________________________
Bitt Faulk
|
Top
|
|
|
|
#273051 - 15/01/2006 21:37
Re: empeg in cold weather. it's ch-ch-chilly and it won't b-b-boot. He
[Re: wfaulk]
|
carpal tunnel
Registered: 20/12/1999
Posts: 31597
Loc: Seattle, WA
|
Quote: Actually, Mark, will the NFS server work if the disk has just been replaced?
In the instructions I'm writing, I'm making sure that before someone does a PUT to restore the disk, they've done a full disk rebuild, software install, and hijack install, so that the player is fully working again.
Although I have a related question: Should the player software be exited out to the shell prompt before doing a full-disk PUT operation? And if so, is there a hijack command that'll do that for me via the FTP command-line interface, similar to the SITE RO and SITE RW commands?
|
Top
|
|
|
|
#273052 - 15/01/2006 21:51
Re: empeg in cold weather. it's ch-ch-chilly and it won't b-b-boot. He
[Re: tfabris]
|
carpal tunnel
Registered: 29/08/2000
Posts: 14493
Loc: Canada
|
Quote:
Although I have a related question: Should the player software be exited out to the shell prompt before doing a full-disk PUT operation? And if so, is there a hijack command that'll do that for me via the FTP command-line interface, similar to the SITE RO and SITE RW commands?
It would be best to stop the player app while doing the image restore, but it should work regardless. I think Bitt once figured out the correct FTP SITE EXEC for that.
Cheers
|
Top
|
|
|
|
#273053 - 15/01/2006 22:17
Re: empeg in cold weather. it's ch-ch-chilly and it won't b-b-boot. He
[Re: mlord]
|
carpal tunnel
Registered: 20/12/1999
Posts: 31597
Loc: Seattle, WA
|
Quote: I think Bitt once figured out the correct FTP SITE EXEC for that.
Cool, thanks. that'd be useful to put into the instructions, if anyone knows it.
|
Top
|
|
|
|
#273054 - 15/01/2006 22:34
Re: empeg in cold weather. it's ch-ch-chilly and it won't b-b-boot. He
[Re: tfabris]
|
carpal tunnel
Registered: 20/12/1999
Posts: 31597
Loc: Seattle, WA
|
Okay, the updated FAQ entry is here. I'm a bit brain-addled at the moment and can't bear the thought of fact-checking and typo-checking that entry right now. So if anyone notices any errors, please report them here. Thanks. Doug, your one-click backup/restore solution is now just a batch file away. I think you know how to write the batch file at this point, you've done FTP scripts before, right?
|
Top
|
|
|
|
#273055 - 16/01/2006 01:04
Re: empeg in cold weather. it's ch-ch-chilly and it won't b-b-boot. He
[Re: tfabris]
|
carpal tunnel
Registered: 25/12/2000
Posts: 16706
Loc: Raleigh, NC US
|
This:
Code:
SITE EXEC kill -2 `ps ax | grep player | grep -v grep | awk '{print $1;}'`
might work, but don't quote me on that. Someone test it first.
Edited by wfaulk (16/01/2006 01:05)
_________________________
Bitt Faulk
|
Top
|
|
|
|
#273056 - 16/01/2006 02:47
Re: empeg in cold weather. it's ch-ch-chilly and it won't b-b-boot. He
[Re: tfabris]
|
carpal tunnel
Registered: 08/07/1999
Posts: 5549
Loc: Ajijic, Mexico
|
you've done FTP scripts before, right?
Yes, like the ones I run to use the player as a file taxi.
tanstaafl.
_________________________
"There Ain't No Such Thing As A Free Lunch"
|
Top
|
|
|
|
#273057 - 16/01/2006 03:11
Re: empeg in cold weather. it's ch-ch-chilly and it won't b-b-boot. He
[Re: wfaulk]
|
carpal tunnel
Registered: 20/12/1999
Posts: 31597
Loc: Seattle, WA
|
Cool, thanks Bitt. Okay, that's a pretty complicated little command, there. I understand why it has to be complicated, but for now I think I'll leave the FAQ entry as-is, where it says to kill the player via the shell prompt with the serial cable.
|
Top
|
|
|
|
#273058 - 16/01/2006 08:31
Re: empeg in cold weather. it's ch-ch-chilly and it won't b-b-boot. He
[Re: wfaulk]
|
veteran
Registered: 01/10/2001
Posts: 1307
Loc: Amsterdam, The Netherlands
|
Quote: Code:
SITE EXEC kill -2 `ps ax | grep player | grep -v grep | awk '{print $1;}'`
Trivial simplification: Code:
SITE EXEC kill -2 `ps ax | grep -v grep | awk '/player/{print $1;}'`
|
Top
|
|
|
|
#273059 - 16/01/2006 12:15
Re: empeg in cold weather. it's ch-ch-chilly and it won't b-b-boot. He
[Re: julf]
|
carpal tunnel
Registered: 25/12/2000
Posts: 16706
Loc: Raleigh, NC US
|
Well, if you're going to do that, you probably don't need the other grep either. Code:
SITE EXEC kill -2 `ps ax | awk '/player/{print $1;}'`
_________________________
Bitt Faulk
|
Top
|
|
|
|
#273060 - 16/01/2006 12:38
Re: empeg in cold weather. it's ch-ch-chilly and it won't b-b-boot. He
[Re: wfaulk]
|
veteran
Registered: 21/01/2002
Posts: 1380
Loc: Erie, CO
|
awk isn't included in the default player image, though.
|
Top
|
|
|
|
#273061 - 16/01/2006 13:09
Re: empeg in cold weather. it's ch-ch-chilly and it won't b-b-boot. He
[Re: wfaulk]
|
veteran
Registered: 01/10/2001
Posts: 1307
Loc: Amsterdam, The Netherlands
|
Quote: Well, if you're going to do that, you probably don't need the other grep either.
Well, unless you anchor the awk pattern (not able to connect to my empeg right now to see the output of ps), you will end up selecting the grep line too...
|
Top
|
|
|
|
#273062 - 16/01/2006 13:51
Re: empeg in cold weather. it's ch-ch-chilly and it won't b-b-boot. He
[Re: julf]
|
carpal tunnel
Registered: 25/12/2000
Posts: 16706
Loc: Raleigh, NC US
|
What grep? There are no greps left.
_________________________
Bitt Faulk
|
Top
|
|
|
|
#273063 - 16/01/2006 14:07
Re: empeg in cold weather. it's ch-ch-chilly and it won't b-b-boot. He
[Re: cushman]
|
carpal tunnel
Registered: 25/12/2000
Posts: 16706
Loc: Raleigh, NC US
|
ISTR it working at some point. Maybe it's in the developer image?
Hmm, all in bash. Tough one. It'd help if bash wasn't a pile of crap (they really need to stop claiming it's ksh-compatible).
Code:
SITE EXEC kill -2 `set $(ps ax | grep player | grep -v grep); echo $1`
_________________________
Bitt Faulk
|
Top
|
|
|
|
#273064 - 16/01/2006 14:39
Re: empeg in cold weather. it's ch-ch-chilly and it won't b-b-boot. He
[Re: wfaulk]
|
veteran
Registered: 01/10/2001
Posts: 1307
Loc: Amsterdam, The Netherlands
|
Quote: What grep? There are no greps left.
Duhhh! I need more coffee...
|
Top
|
|
|
|
#273065 - 16/01/2006 14:41
Re: empeg in cold weather. it's ch-ch-chilly and it won't b-b-boot. He
[Re: wfaulk]
|
enthusiast
Registered: 11/06/2003
Posts: 384
|
If you put the first letter of your search string in square brackets you don't need the grep -v. (The process table will show the brackets but grep parses them as indicators of a class that consists of the lowercase p.) Code:
SITE EXEC kill -2 `set $(ps ax | grep [p]layer); echo $1` --Nathan
|
Top
|
|
|
|
#273066 - 16/01/2006 16:15
Re: empeg in cold weather. it's ch-ch-chilly and it won't b-b-boot. He
[Re: Mataglap]
|
carpal tunnel
Registered: 25/12/2000
Posts: 16706
Loc: Raleigh, NC US
|
Ah, good trick.
_________________________
Bitt Faulk
|
Top
|
|
|
|
|
|