Re: [Discuss] Backing up LVM partitions using snapshots

2011-12-15 Thread markw
From: discuss-bounces+blu=nedharvey@blu.org [mailto:discuss- bounces+blu=nedharvey@blu.org] On Behalf Of Bill Bogstad On Wed, Dec 14, 2011 at 10:53 AM, Richard Pieri richard.pi...@gmail.com wrote: On Dec 13, 2011, at 11:11 PM, ma...@mohawksoft.com wrote: Using a block level

[Discuss] Bourne Shell variable assignment question

2011-12-15 Thread Jerry Feldman
I have not done my homework on this as much as I should. A coworker needs to set variable names and values input from another file. Normally, I would source that file, but he specifically wants to parse the file. So, in simple terms, he has a file that has something like: var1=foo Instead of

Re: [Discuss] Bourne Shell variable assignment question

2011-12-15 Thread Matt Shields
On Thu, Dec 15, 2011 at 3:57 PM, Jerry Feldman g...@blu.org wrote: I have not done my homework on this as much as I should. A coworker needs to set variable names and values input from another file. Normally, I would source that file, but he specifically wants to parse the file. So, in

Re: [Discuss] Bourne Shell variable assignment question

2011-12-15 Thread Ben Eisenbraun
On Thu, Dec 15, 2011 at 03:57:04PM -0500, Jerry Feldman wrote: I have not done my homework on this as much as I should. A coworker needs to set variable names and values input from another file. Normally, I would source that file, but he specifically wants to parse the file. So, in simple

Re: [Discuss] Bourne Shell variable assignment question

2011-12-15 Thread Peter Doherty
On Dec 15, 2011, at 15:57 , Jerry Feldman wrote: I have not done my homework on this as much as I should. A coworker needs to set variable names and values input from another file. Normally, I would source that file, but he specifically wants to parse the file. So, in simple terms, he has a

Re: [Discuss] Bourne Shell variable assignment question

2011-12-15 Thread Richard Pieri
On 12/15/2011 4:25 PM, Peter Doherty wrote: Of course, one has to ask why your co-worker is doing this, and not just sourcing the file. Also, my example will break if you have an equal sign in your variable name or value name. This. Sourcing the file is going to be the fastest and most

Re: [Discuss] Bourne Shell variable assignment question

2011-12-15 Thread Jerry Feldman
On 12/15/2011 04:22 PM, Ben Eisenbraun wrote: On Thu, Dec 15, 2011 at 03:57:04PM -0500, Jerry Feldman wrote: I have not done my homework on this as much as I should. A coworker needs to set variable names and values input from another file. Normally, I would source that file, but he

Re: [Discuss] Bourne Shell variable assignment question

2011-12-15 Thread Ben Eisenbraun
On Thu, Dec 15, 2011 at 04:27:34PM -0500, Richard Pieri wrote: On 12/15/2011 4:25 PM, Peter Doherty wrote: Of course, one has to ask why your co-worker is doing this, and not just sourcing the file. Also, my example will break if you have an equal sign in your variable name or value

Re: [Discuss] Bourne Shell variable assignment question

2011-12-15 Thread Jerry Feldman
On 12/15/2011 04:27 PM, Richard Pieri wrote: On 12/15/2011 4:25 PM, Peter Doherty wrote: Of course, one has to ask why your co-worker is doing this, and not just sourcing the file. Also, my example will break if you have an equal sign in your variable name or value name. This. Sourcing the

Re: [Discuss] Bourne Shell variable assignment question

2011-12-15 Thread Chris Tyler
On Thu, 2011-12-15 at 16:35 -0500, Jerry Feldman wrote: On 12/15/2011 04:27 PM, Richard Pieri wrote: On 12/15/2011 4:25 PM, Peter Doherty wrote: Of course, one has to ask why your co-worker is doing this, and not just sourcing the file. Also, my example will break if you have an equal

Re: [Discuss] Bourne Shell variable assignment question

2011-12-15 Thread Jerry Feldman
On 12/15/2011 04:31 PM, Jerry Feldman wrote: On 12/15/2011 04:22 PM, Ben Eisenbraun wrote: On Thu, Dec 15, 2011 at 03:57:04PM -0500, Jerry Feldman wrote: I have not done my homework on this as much as I should. A coworker needs to set variable names and values input from another file.

Re: [Discuss] Bourne Shell variable assignment question

2011-12-15 Thread Jerry Feldman
Thanks guys. I have several workable solutions for him. The underlying issue is that he wants to prevent malicious code. In the context he is working on, I don't think that is a risk, but using egrep to reject any lines that are not in the form 'var=value'. I also think that his script must be

Re: [Discuss] Bourne Shell variable assignment question

2011-12-15 Thread Chuck Anderson
On Thu, Dec 15, 2011 at 05:16:32PM -0500, Jerry Feldman wrote: Thanks guys. I have several workable solutions for him. The underlying issue is that he wants to prevent malicious code. In the context he is working on, I don't think that is a risk, but using egrep to reject any lines that are

Re: [Discuss] Bourne Shell variable assignment question

2011-12-15 Thread Dan Kressin
On 12/15/2011 04:31 PM, Jerry Feldman wrote: Just want to simplify. #!/bin/bash varname=myvar varvalue=foo --- do something to create myvar. myvar=$varvalue echo $myvar I think 'declare' might be what you were looking for, although AFIACT it's not part of Bourne.  But this works with BASH when

Re: [Discuss] Bourne Shell variable assignment question

2011-12-15 Thread Richard Pieri
On Dec 15, 2011, at 4:35 PM, Jerry Feldman wrote: This is 100% agreed. The issue is that he does not want to source the file and I have not been able to talk him out of it. In the past I have written scripts where you could read the name of a variable, and then convert it to a variable name,

[Discuss] Justify your existence

2011-12-15 Thread Edward Ned Harvey
You're in a social situation - at a party or something - You're talking with some CFO or otherwise interesting financial person about work, and Dilbert cartoons, and the wastefulness and inefficiencies of typical corporations or typical organizations, etc. Somebody uses a term like overhead or

Re: [Discuss] Bourne Shell variable assignment question

2011-12-15 Thread Gordon Ross
On Thu, Dec 15, 2011 at 3:57 PM, Jerry Feldman g...@blu.org wrote: I have not done my homework on this as much as I should. A coworker needs to set variable names and values input from another file. Normally, I would source that file, but he specifically wants to parse the file. So, in simple

Re: [Discuss] Justify your existence

2011-12-15 Thread Greg Rundlett (freephile)
On Thu, Dec 15, 2011 at 10:56 PM, Edward Ned Harvey b...@nedharvey.comwrote: You're in a social situation - at a party or something - You're talking with some CFO or otherwise interesting financial person about work, and Dilbert cartoons, and the wastefulness and inefficiencies of typical

Re: [Discuss] Justify your existence

2011-12-15 Thread Jack Coats
Here are a few personal truisms about 'overhead'. A long time ago, I found that you are 'overhead' if you are not in the 'Business of the Business'. If you are in healthcare doctor or a nurse, you are in the business, if you are mopping the floors in a hospital, doing IT, doing accounting, you

Re: [Discuss] Justify your existence

2011-12-15 Thread Bill Horne
On 12/15/2011 10:56 PM, Edward Ned Harvey wrote: You're in a social situation - at a party or something - You're talking with some CFO or otherwise interesting financial person about work, and Dilbert cartoons, and the wastefulness and inefficiencies of typical corporations or typical