Welcome! » Log In » Create A New Profile

vmchange script

Posted by Anonymous 
vmchange script
February 12, 2012 04:56AM
Hi Team,

Here's is my challenge.

Every week I have to change tapes in two libraries one has a cap size of 25 and another has of 35.

Now I get a list of tapes to be ejected and sent offsite via script the real challenge is ejecting them.

I can use the vmchange command in two separate consoles

Syntax : vmchange -res -multi_eject -w -rn 0 -rt tld -rh pnors950.mgroupnet.com -ml

Example :vmchange -res -multi_eject -w -rn 0 -rt tld -rh server.xyz.com -ml MO0371:MO0012:MO0454:MO0775:MO0017

I want to create a script which automates this one of the sample script is

FOR /F %%i IN (E:setin.txt) DO E:VERITASVolmgrbinvmchange -res -multi_eject -w -rn 3 -rt tld -rh pnors954.mgroupnet.com -ml %%i>>E:ejectoutput.txt

The above script uses a file setin.txt which would have list of labels with colon separated

MO0371:MO0012:MO0454:MO0775:MO0017

The only challenge is this I want the script to take input of labels as file and do not want manually colon separate them manually.

Please provide suggestions.

Anurag
vmchange script
February 12, 2012 05:27AM
Hi,

There is a better way.
There is an undocumented option called single_cycle.
This will put the tapes in the cap one by one and not prompt you to remove them.
The best of both worlds J

Example Syntax:
/usr/openv/volmgr/bin/vmchange -h "$MASTER_SERVER" -rh "$ROBOT_CTRL_HOST" -rn "$ROBOT_NUM" -rt "$ROBOT_TYPE" -multi_eject -map any -res -ml "$TAPE" -verbose -single_cycle

Justin.

From: veritas-bu-bounces < at > mailman.eng.auburn.edu [mailto] On Behalf Of Anurag Sharma
Sent: Sunday, February 12, 2012 7:40 AM
To: veritas-bu
Subject: [Veritas-bu] vmchange script

Hi Team,

Here's is my challenge.

Every week I have to change tapes in two libraries one has a cap size of 25 and another has of 35.

Now I get a list of tapes to be ejected and sent offsite via script the real challenge is ejecting them.

I can use the vmchange command in two separate consoles

Syntax : vmchange -res -multi_eject -w -rn 0 -rt tld -rh pnors950.mgroupnet.com -ml

Example :vmchange -res -multi_eject -w -rn 0 -rt tld -rh server.xyz.com -ml MO0371:MO0012:MO0454:MO0775:MO0017

I want to create a script which automates this one of the sample script is

FOR /F %%i IN (E:setin.txt) DO E:VERITASVolmgrbinvmchange -res -multi_eject -w -rn 3 -rt tld -rh pnors954.mgroupnet.com -ml %%i>>E:ejectoutput.txt

The above script uses a file setin.txt which would have list of labels with colon separated

MO0371:MO0012:MO0454:MO0775:MO0017

The only challenge is this I want the script to take input of labels as file and do not want manually colon separate them manually.

Please provide suggestions.

Anurag
vmchange script
February 12, 2012 05:59AM
Justin,

$Tape

What would that file contain

just the media labels

or

media labels which are colon seperated. if yes kind send how this script would look in windows nbu

From: jpiszcz < at > lucidpixels.com
To: sharma.anurag < at > hotmail.com; veritas-bu < at > mailman.eng.auburn.edu
Subject: RE: [Veritas-bu] vmchange script
Date: Sun, 12 Feb 2012 08:27:39 -0500

.ExternalClass p.ecxMsoNormal, .ExternalClass li.ecxMsoNormal, .ExternalClass div.ecxMsoNormal {margin-bottom:.0001pt;font-size:12.0pt;font-family:"Times New Roman","serif";} .ExternalClass a:link, .ExternalClass span.ecxMsoHyperlink {color:blue;text-decoration:underline;} .ExternalClass a:visited, .ExternalClass span.ecxMsoHyperlinkFollowed {color:purple;text-decoration:underline;} .ExternalClass p {margin-right:0in;margin-left:0in;font-size:12.0pt;font-family:"Times New Roman","serif";} .ExternalClass span.ecxEmailStyle18 {font-family:"Calibri","sans-serif";color:#1F497D;} .ExternalClass .ecxMsoChpDefault {font-size:10.0pt;} < at > page WordSection1 {size:8.5in 11.0in;} .ExternalClass div.ecxWordSection1 {page:WordSection1;}
Hi,

There is a better way.
There is an undocumented option called –single_cycle.
This will put the tapes in the cap one by one and not prompt you to remove them.
The best of both worlds J

Example Syntax:
/usr/openv/volmgr/bin/vmchange -h "$MASTER_SERVER" -rh "$ROBOT_CTRL_HOST" -rn "$ROBOT_NUM" -rt "$ROBOT_TYPE" -multi_eject -map any -res -ml "$TAPE" -verbose -single_cycle

Justin.

From: veritas-bu-bounces < at > mailman.eng.auburn.edu [mailto] On Behalf Of Anurag Sharma
Sent: Sunday, February 12, 2012 7:40 AM
To: veritas-bu
Subject: [Veritas-bu] vmchange script

Hi Team,

Here's is my challenge.

Every week I have to change tapes in two libraries one has a cap size of 25 and another has of 35.

Now I get a list of tapes to be ejected and sent offsite via script the real challenge is ejecting them.

I can use the vmchange command in two separate consoles

Syntax : vmchange -res -multi_eject -w -rn 0 -rt tld -rh pnors950.mgroupnet.com -ml

Example :vmchange -res -multi_eject -w -rn 0 -rt tld -rh server.xyz.com -ml MO0371:MO0012:MO0454:MO0775:MO0017

I want to create a script which automates this one of the sample script is

FOR /F %%i IN (E:setin.txt) DO E:VERITASVolmgrbinvmchange -res -multi_eject -w -rn 3 -rt tld -rh pnors954.mgroupnet.com -ml %%i>>E:ejectoutput.txt

The above script uses a file setin.txt which would have list of labels with colon separated

MO0371:MO0012:MO0454:MO0775:MO0017

The only challenge is this I want the script to take input of labels as file and do not want manually colon separate them manually.

Please provide suggestions.

Anurag
vmchange script
February 12, 2012 06:35AM
Hi,

That would be just the media label&#8212; one command per TAPE.

vmchange .. etc etc .. ml TAPE01
vmchange .. etc etc .. ml TAPE02
vmchange .. etc etc .. ml TAPE03

Justin.

From: Anurag Sharma [mailto]
Sent: Sunday, February 12, 2012 8:59 AM
To: jpiszcz < at > lucidpixels.com; veritas-bu
Subject: RE: [Veritas-bu] vmchange script

Justin,

$Tape

What would that file contain

just the media labels

or

media labels which are colon seperated. if yes kind send how this script would look in windows nbu

From: jpiszcz < at > lucidpixels.com (jpiszcz &lt; at &gt; lucidpixels.com)
To: sharma.anurag < at > hotmail.com (sharma.anurag &lt; at &gt; hotmail.com); veritas-bu < at > mailman.eng.auburn.edu (veritas-bu &lt; at &gt; mailman.eng.auburn.edu)
Subject: RE: [Veritas-bu] vmchange script
Date: Sun, 12 Feb 2012 08:27:39 -0500
Hi,

There is a better way.
There is an undocumented option called single_cycle.
This will put the tapes in the cap one by one and not prompt you to remove them.
The best of both worlds J

Example Syntax:
/usr/openv/volmgr/bin/vmchange -h "$MASTER_SERVER" -rh "$ROBOT_CTRL_HOST" -rn "$ROBOT_NUM" -rt "$ROBOT_TYPE" -multi_eject -map any -res -ml "$TAPE" -verbose -single_cycle

Justin.

From: veritas-bu-bounces < at > mailman.eng.auburn.edu (veritas-bu-bounces &lt; at &gt; mailman.eng.auburn.edu) [mailto] ([mailto]) On Behalf Of Anurag Sharma
Sent: Sunday, February 12, 2012 7:40 AM
To: veritas-bu
Subject: [Veritas-bu] vmchange script

Hi Team,

Here's is my challenge.

Every week I have to change tapes in two libraries one has a cap size of 25 and another has of 35.

Now I get a list of tapes to be ejected and sent offsite via script the real challenge is ejecting them.

I can use the vmchange command in two separate consoles

Syntax : vmchange -res -multi_eject -w -rn 0 -rt tld -rh pnors950.mgroupnet.com -ml

Example :vmchange -res -multi_eject -w -rn 0 -rt tld -rh server.xyz.com -ml MO0371:MO0012:MO0454:MO0775:MO0017

I want to create a script which automates this one of the sample script is

FOR /F %%i IN (E:setin.txt) DO E:VERITASVolmgrbinvmchange -res -multi_eject -w -rn 3 -rt tld -rh pnors954.mgroupnet.com -ml %%i>>E:ejectoutput.txt

The above script uses a file setin.txt which would have list of labels with colon separated

MO0371:MO0012:MO0454:MO0775:MO0017

The only challenge is this I want the script to take input of labels as file and do not want manually colon separate them manually.

Please provide suggestions.

Anurag
vmchange script
February 14, 2012 01:30AM
Hi

Last time i use this to generate a file with colon separated media labels:

< at > bpimagelist -A -media -idonly -hoursago 24 | find "MO" | tr rn ":" | sed -e s/::/:/g -e s/:$//g > %MEDIA_FILE%

Hope it help.

Leo

On Sun, Feb 12, 2012 at 10:35 PM, Justin Piszcz <jpiszcz < at > lucidpixels.com (jpiszcz &lt; at &gt; lucidpixels.com)> wrote:
Quote

Hi,
 
That would be just the media label— one command per TAPE.
 
vmchange .. etc etc .. –ml TAPE01
vmchange .. etc etc .. –ml TAPE02
vmchange .. etc etc .. –ml TAPE03
 
Justin.
 
From: Anurag Sharma [mailto]sharma.anurag < at > hotmail.com[/email])]
Sent: Sunday, February 12, 2012 8:59 AM
To: jpiszcz < at > lucidpixels.com (jpiszcz &lt; at &gt; lucidpixels.com); veritas-bu
Subject: RE: [Veritas-bu] vmchange script

 

Justin,

$Tape

What would that file contain

just the media labels

or

media labels which are colon seperated. if yes kind send how this script would look in windows nbu



From: jpiszcz < at > lucidpixels.com (jpiszcz &lt; at &gt; lucidpixels.com)
To: sharma.anurag < at > hotmail.com (sharma.anurag &lt; at &gt; hotmail.com); veritas-bu < at > mailman.eng.auburn.edu (veritas-bu &lt; at &gt; mailman.eng.auburn.edu)
Subject: RE: [Veritas-bu] vmchange script
Date: Sun, 12 Feb 2012 08:27:39 -0500
Hi,
 
There is a better way.
There is an undocumented option called –single_cycle.
This will put the tapes in the cap one by one and not prompt you to remove them.
The best of both worlds J
 
Example Syntax:
/usr/openv/volmgr/bin/vmchange -h "$MASTER_SERVER" -rh "$ROBOT_CTRL_HOST" -rn "$ROBOT_NUM" -rt "$ROBOT_TYPE" -multi_eject -map any -res -ml "$TAPE" -verbose -single_cycle
 
Justin.
 
From: veritas-bu-bounces < at > mailman.eng.auburn.edu (veritas-bu-bounces &lt; at &gt; mailman.eng.auburn.edu) [mailto] ([mailto]) On Behalf Of Anurag Sharma
Sent: Sunday, February 12, 2012 7:40 AM
To: veritas-bu
Subject: [Veritas-bu] vmchange script

 
Hi Team,

Here&#39;s is my challenge.

Every week I have to change tapes in two libraries one has a cap size of 25 and another has of 35.

Now I get a list of tapes to be ejected and sent offsite via script the real challenge is ejecting them.

I can use the vmchange command in two separate consoles

Syntax : vmchange -res -multi_eject -w -rn 0 -rt tld -rh pnors950.mgroupnet.com -ml 

Example :vmchange -res -multi_eject -w -rn 0 -rt tld -rh server.xyz.com -ml MO0371:MO0012:MO0454:MO0775:MO0017

I want to create a script which automates this one of the sample script is

FOR /F %%i IN (E:setin.txt) DO E:VERITASVolmgrbinvmchange -res -multi_eject -w -rn 3 -rt tld -rh pnors954.mgroupnet.com -ml %%i>>E:ejectoutput.txt

The above script uses a file setin.txt which would have list of labels with colon separated

MO0371:MO0012:MO0454:MO0775:MO0017

The only challenge is this I want the script to take input of labels as file and do not want manually colon separate them manually.

Please provide suggestions.

Anurag

 



_______________________________________________
Veritas-bu maillist  -  Veritas-bu < at > mailman.eng.auburn.edu (Veritas-bu &lt; at &gt; mailman.eng.auburn.edu)
http://mailman.eng.auburn.edu/mailman/listinfo/veritas-bu
vmchange script
February 20, 2012 02:39AM
Thank you Leo,

Could please tell me how can get a : seprated output if I already have a list of media to be expired in another text file in a tabular format ?

What I'm asking is this - I want a command which converts

:MO0174 :MO0928 :MO0486 :MO0074 :MO0718 :MO0355 :MO0789
to this :MO0174 :MO0928 :MO0486 :MO0074 :MO0718 :MO0355 :MO0789

Date: Tue, 14 Feb 2012 17:30:07 +0800
Subject: Re: [Veritas-bu] vmchange script
From: dreamleo < at > gmail.com
To: veritas-bu < at > mailman.eng.auburn.edu
CC: sharma.anurag < at > hotmail.com

Hi

Last time i use this to generate a file with colon separated media labels:

< at > bpimagelist -A -media -idonly -hoursago 24 | find "MO" | tr rn ":" | sed -e s/::/:/g -e s/:$//g > %MEDIA_FILE%

Hope it help.

Leo

On Sun, Feb 12, 2012 at 10:35 PM, Justin Piszcz <jpiszcz < at > lucidpixels.com (jpiszcz &lt; at &gt; lucidpixels.com)> wrote:
Quote

Hi,

That would be just the media label— one command per TAPE.

vmchange .. etc etc .. –ml TAPE01
vmchange .. etc etc .. –ml TAPE02
vmchange .. etc etc .. –ml TAPE03

Justin.

From: Anurag Sharma [mailto]sharma.anurag < at > hotmail.com[/email])]
Sent: Sunday, February 12, 2012 8:59 AM
To: jpiszcz < at > lucidpixels.com (jpiszcz &lt; at &gt; lucidpixels.com); veritas-bu
Subject: RE: [Veritas-bu] vmchange script



Justin,

$Tape

What would that file contain

just the media labels

or

media labels which are colon seperated. if yes kind send how this script would look in windows nbu



From: jpiszcz < at > lucidpixels.com (jpiszcz &lt; at &gt; lucidpixels.com)
To: sharma.anurag < at > hotmail.com (sharma.anurag &lt; at &gt; hotmail.com); veritas-bu < at > mailman.eng.auburn.edu (veritas-bu &lt; at &gt; mailman.eng.auburn.edu)
Subject: RE: [Veritas-bu] vmchange script
Date: Sun, 12 Feb 2012 08:27:39 -0500
Hi,

There is a better way.
There is an undocumented option called –single_cycle.
This will put the tapes in the cap one by one and not prompt you to remove them.
The best of both worlds J

Example Syntax:
/usr/openv/volmgr/bin/vmchange -h "$MASTER_SERVER" -rh "$ROBOT_CTRL_HOST" -rn "$ROBOT_NUM" -rt "$ROBOT_TYPE" -multi_eject -map any -res -ml "$TAPE" -verbose -single_cycle

Justin.

From: veritas-bu-bounces < at > mailman.eng.auburn.edu (veritas-bu-bounces &lt; at &gt; mailman.eng.auburn.edu) [mailto] ([mailto]) On Behalf Of Anurag Sharma
Sent: Sunday, February 12, 2012 7:40 AM
To: veritas-bu
Subject: [Veritas-bu] vmchange script


Hi Team,

Here's is my challenge.

Every week I have to change tapes in two libraries one has a cap size of 25 and another has of 35.

Now I get a list of tapes to be ejected and sent offsite via script the real challenge is ejecting them.

I can use the vmchange command in two separate consoles

Syntax : vmchange -res -multi_eject -w -rn 0 -rt tld -rh pnors950.mgroupnet.com -ml

Example :vmchange -res -multi_eject -w -rn 0 -rt tld -rh server.xyz.com -ml MO0371:MO0012:MO0454:MO0775:MO0017

I want to create a script which automates this one of the sample script is

FOR /F %%i IN (E:setin.txt) DO E:VERITASVolmgrbinvmchange -res -multi_eject -w -rn 3 -rt tld -rh pnors954.mgroupnet.com -ml %%i>>E:ejectoutput.txt

The above script uses a file setin.txt which would have list of labels with colon separated

MO0371:MO0012:MO0454:MO0775:MO0017

The only challenge is this I want the script to take input of labels as file and do not want manually colon separate them manually.

Please provide suggestions.

Anurag



_______________________________________________
Veritas-bu maillist - Veritas-bu < at > mailman.eng.auburn.edu (Veritas-bu &lt; at &gt; mailman.eng.auburn.edu)
http://mailman.eng.auburn.edu/mailman/listinfo/veritas-bu
vmchange script
February 20, 2012 04:27AM
Hi,
 
Windows:
 
type <file name> | find ":"
 
*NIX
grep ":" <file name>
or
grep -v "^$" <file name>
 
I can&#39;t find the windows equivalent of the last command, if there is one.
 
Regards,
 
Patrick

  On 20 February 2012 at 10:38 Anurag Sharma <sharma.anurag < at > hotmail.com> wrote: > > > Thank you Leo, > > Could please tell me how can get a : seprated output if I already have a list of media to be expired in another text file in a tabular format ? > > What I&#39;m asking is this - I want a command which converts > > >  >  >   :MO0174 >  >  >   :MO0928 >  >  >   :MO0486 >  >  >   :MO0074 >  >  >   :MO0718 >  >  >   :MO0355 >  >  >   :MO0789 >  > > to this >   :MO0174 >   :MO0928 >   :MO0486 >   :MO0074 >   :MO0718 >   :MO0355 >   :MO0789 > > > > > Date: Tue, 14 Feb 2012 17:30:07 +0800 > Subject: Re: [Veritas-bu] vmchange script > From: dreamleo < at > gmail.com > To: veritas-bu < at > mailman.eng.auburn.edu > CC: sharma.anurag < at > hotmail.com > > Hi > > Last time i use this to generate a file with colon separated media labels: > > < at > bpimagelist -A -media -idonly -hoursago 24 | find "MO" | tr rn ":" | sed -e s/::/:/g -e s/:$//g > %MEDIA_FILE% > > > Hope it help. > > Leo > > On Sun, Feb 12, 2012 at 10:35 PM, Justin Piszcz <jpiszcz < at > lucidpixels.com> wrote: > > Hi, >  That would be just the media label— one command per TAPE. >  vmchange .. etc etc .. –ml TAPE01 > vmchange .. etc etc .. –ml TAPE02vmchange .. etc etc .. –ml TAPE03 >  Justin. >  > From: Anurag Sharma [mailto] > > Sent: Sunday, February 12, 2012 8:59 AM > To: jpiszcz < at > lucidpixels.com; veritas-bu > Subject: RE: [Veritas-bu] vmchange script >  > > Justin, > > $Tape > > > What would that file contain > > just the media labels > > or > > media labels which are colon seperated. if yes kind send how this script would look in windows nbu > > > > From: jpiszcz < at > lucidpixels.com > To: sharma.anurag < at > hotmail.com; veritas-bu < at > mailman.eng.auburn.edu > > Subject: RE: [Veritas-bu] vmchange script > Date: Sun, 12 Feb 2012 08:27:39 -0500Hi, >  > There is a better way. > There is an undocumented option called –single_cycle. > This will put the tapes in the cap one by one and not prompt you to remove them. > The best of both worlds J >  > Example Syntax: > /usr/openv/volmgr/bin/vmchange -h "$MASTER_SERVER" -rh "$ROBOT_CTRL_HOST" -rn "$ROBOT_NUM" -rt "$ROBOT_TYPE" -multi_eject -map any -res -ml "$TAPE" -verbose -single_cycle >  > Justin. >  > From: veritas-bu-bounces < at > mailman.eng.auburn.edu [mailto] On Behalf Of Anurag Sharma > > Sent: Sunday, February 12, 2012 7:40 AM > To: veritas-bu > Subject: [Veritas-bu] vmchange script > Hi Team, > > Here&#39;s is my challenge. > > Every week I have to change tapes in two libraries one has a cap size of 25 and another has of 35. > > > Now I get a list of tapes to be ejected and sent offsite via script the real challenge is ejecting them. > > I can use the vmchange command in two separate consoles > > Syntax : vmchange -res -multi_eject -w -rn 0 -rt tld -rh pnors950.mgroupnet.com -ml  > > > Example :vmchange -res -multi_eject -w -rn 0 -rt tld -rh server.xyz.com -ml MO0371:MO0012:MO0454:MO0775:MO0017 > > > I want to create a script which automates this one of the sample script is > > > FOR /F %%i IN (E:setin.txt) DO E:VERITASVolmgrbinvmchange -res -multi_eject -w -rn 3 -rt tld -rh pnors954.mgroupnet.com -ml %%i>>E:ejectoutput.txt > > > The above script uses a file setin.txt which would have list of labels with colon separated > > MO0371:MO0012:MO0454:MO0775:MO0017 > > The only challenge is this I want the script to take input of labels as file and do not want manually colon separate them manually. > > > > Please provide suggestions. > > Anurag > > > >  > > > _______________________________________________ > > Veritas-bu maillist  -  Veritas-bu < at > mailman.eng.auburn.edu > > [mailman.eng.auburn.edu] > > > >                                               
vmchange script
February 21, 2012 11:39PM
Hello,
Just an info about unix and windows scripting.
There are many ports of unix commands at windows . You can find grep and awk for windows with a Google search.
I’m using msgit for windows which is a complete bash sell and it is portable.

From: veritas-bu-bounces < at > mailman.eng.auburn.edu [mailto] On Behalf Of netbackup < at > whelan-consulting.co.uk
Sent: Monday, February 20, 2012 2:26 PM
To: veritas-bu; dreamleo < at > gmail.com; Anurag Sharma
Subject: Re: [Veritas-bu] vmchange script

Hi,

Windows:

type <file name> | find ":"

*NIX
grep ":" <file name>
or
grep -v "^$" <file name>

I can't find the windows equivalent of the last command, if there is one.

Regards,

Patrick

On 20 February 2012 at 10:38 Anurag Sharma <sharma.anurag < at > hotmail.com> wrote:

Quote


Thank you Leo,

Could please tell me how can get a : seprated output if I already have a list of media to be expired in another text file in a tabular format ?

What I'm asking is this - I want a command which converts

:MO0174

:MO0928

:MO0486

:MO0074

:MO0718

:MO0355

:MO0789

to this
:MO0174
:MO0928
:MO0486
:MO0074
:MO0718
:MO0355
:MO0789

Date: Tue, 14 Feb 2012 17:30:07 +0800
Subject: Re: [Veritas-bu] vmchange script
From: dreamleo < at > gmail.com
To: veritas-bu < at > mailman.eng.auburn.edu
CC: sharma.anurag < at > hotmail.com

Hi

Last time i use this to generate a file with colon separated media labels:

< at > bpimagelist -A -media -idonly -hoursago 24 | find "MO" | tr rn ":" | sed -e s/::/:/g -e s/:$//g > %MEDIA_FILE%

Hope it help.

Leo

On Sun, Feb 12, 2012 at 10:35 PM, Justin Piszcz <jpiszcz < at > lucidpixels.com> wrote:

Hi,
That would be just the media label— one command per TAPE.
vmchange .. etc etc .. –ml TAPE01
vmchange .. etc etc .. –ml TAPE02vmchange .. etc etc .. –ml TAPE03
Justin.

From: Anurag Sharma [mailto]

Sent: Sunday, February 12, 2012 8:59 AM
To: jpiszcz < at > lucidpixels.com; veritas-bu
Subject: RE: [Veritas-bu] vmchange script

Justin,

$Tape

What would that file contain

just the media labels

or

media labels which are colon seperated. if yes kind send how this script would look in windows nbu

From: jpiszcz < at > lucidpixels.com
To: sharma.anurag < at > hotmail.com; veritas-bu < at > mailman.eng.auburn.edu

Subject: RE: [Veritas-bu] vmchange script
Date: Sun, 12 Feb 2012 08:27:39 -0500Hi,

There is a better way.
There is an undocumented option called –single_cycle.
This will put the tapes in the cap one by one and not prompt you to remove them.
The best of both worlds J

Example Syntax:
/usr/openv/volmgr/bin/vmchange -h "$MASTER_SERVER" -rh "$ROBOT_CTRL_HOST" -rn "$ROBOT_NUM" -rt "$ROBOT_TYPE" -multi_eject -map any -res -ml "$TAPE" -verbose -single_cycle

Justin.

From: veritas-bu-bounces < at > mailman.eng.auburn.edu [mailto] On Behalf Of Anurag Sharma

Sent: Sunday, February 12, 2012 7:40 AM
To: veritas-bu
Subject: [Veritas-bu] vmchange script
Hi Team,

Here's is my challenge.

Every week I have to change tapes in two libraries one has a cap size of 25 and another has of 35.

Now I get a list of tapes to be ejected and sent offsite via script the real challenge is ejecting them.

I can use the vmchange command in two separate consoles

Syntax : vmchange -res -multi_eject -w -rn 0 -rt tld -rh pnors950.mgroupnet.com -ml

Example :vmchange -res -multi_eject -w -rn 0 -rt tld -rh server.xyz.com -ml MO0371:MO0012:MO0454:MO0775:MO0017

I want to create a script which automates this one of the sample script is

FOR /F %%i IN (E:setin.txt) DO E:VERITASVolmgrbinvmchange -res -multi_eject -w -rn 3 -rt tld -rh pnors954.mgroupnet.com -ml %%i>>E:ejectoutput.txt

The above script uses a file setin.txt which would have list of labels with colon separated

MO0371:MO0012:MO0454:MO0775:MO0017

The only challenge is this I want the script to take input of labels as file and do not want manually colon separate them manually.

Please provide suggestions.

Anurag

_______________________________________________

Veritas-bu maillist - Veritas-bu < at > mailman.eng.auburn.edu

[mailman.eng.auburn.edu]
vmchange script
February 22, 2012 05:43AM
In fact you can install free Cygwin under windows which is a full Linux distro that allows you to do almost anything you can do in a native Linux install.

From: veritas-bu-bounces < at > mailman.eng.auburn.edu [mailto] On Behalf Of smpt
Sent: Wednesday, February 22, 2012 2:39 AM
To: netbackup < at > whelan-consulting.co.uk; 'veritas-bu'; dreamleo < at > gmail.com; 'Anurag Sharma'
Subject: Re: [Veritas-bu] vmchange script

Hello,
Just an info about unix and windows scripting.
There are many ports of unix commands at windows . You can find grep and awk for windows with a Google search.
I’m using msgit for windows which is a complete bash sell and it is portable.

From: veritas-bu-bounces < at > mailman.eng.auburn.edu [mailto] On Behalf Of netbackup < at > whelan-consulting.co.uk
Sent: Monday, February 20, 2012 2:26 PM
To: veritas-bu; dreamleo < at > gmail.com; Anurag Sharma
Subject: Re: [Veritas-bu] vmchange script

Hi,

Windows:

type <file name> | find ":"

*NIX
grep ":" <file name>
or
grep -v "^$" <file name>

I can't find the windows equivalent of the last command, if there is one.

Regards,

Patrick

On 20 February 2012 at 10:38 Anurag Sharma <sharma.anurag < at > hotmail.com> wrote:

Quote


Thank you Leo,

Could please tell me how can get a : seprated output if I already have a list of media to be expired in another text file in a tabular format ?

What I'm asking is this - I want a command which converts

:MO0174

:MO0928

:MO0486

:MO0074

:MO0718

:MO0355

:MO0789

to this
:MO0174
:MO0928
:MO0486
:MO0074
:MO0718
:MO0355
:MO0789

Date: Tue, 14 Feb 2012 17:30:07 +0800
Subject: Re: [Veritas-bu] vmchange script
From: dreamleo < at > gmail.com
To: veritas-bu < at > mailman.eng.auburn.edu
CC: sharma.anurag < at > hotmail.com

Hi

Last time i use this to generate a file with colon separated media labels:

< at > bpimagelist -A -media -idonly -hoursago 24 | find "MO" | tr rn ":" | sed -e s/::/:/g -e s/:$//g > %MEDIA_FILE%

Hope it help.

Leo

On Sun, Feb 12, 2012 at 10:35 PM, Justin Piszcz <jpiszcz < at > lucidpixels.com> wrote:

Hi,
That would be just the media label— one command per TAPE.
vmchange .. etc etc .. –ml TAPE01
vmchange .. etc etc .. –ml TAPE02vmchange .. etc etc .. –ml TAPE03
Justin.

From: Anurag Sharma [mailto]

Sent: Sunday, February 12, 2012 8:59 AM
To: jpiszcz < at > lucidpixels.com; veritas-bu
Subject: RE: [Veritas-bu] vmchange script

Justin,

$Tape

What would that file contain

just the media labels

or

media labels which are colon seperated. if yes kind send how this script would look in windows nbu

From: jpiszcz < at > lucidpixels.com
To: sharma.anurag < at > hotmail.com; veritas-bu < at > mailman.eng.auburn.edu

Subject: RE: [Veritas-bu] vmchange script
Date: Sun, 12 Feb 2012 08:27:39 -0500Hi,

There is a better way.
There is an undocumented option called –single_cycle.
This will put the tapes in the cap one by one and not prompt you to remove them.
The best of both worlds J

Example Syntax:
/usr/openv/volmgr/bin/vmchange -h "$MASTER_SERVER" -rh "$ROBOT_CTRL_HOST" -rn "$ROBOT_NUM" -rt "$ROBOT_TYPE" -multi_eject -map any -res -ml "$TAPE" -verbose -single_cycle

Justin.

From: veritas-bu-bounces < at > mailman.eng.auburn.edu [mailto] On Behalf Of Anurag Sharma

Sent: Sunday, February 12, 2012 7:40 AM
To: veritas-bu
Subject: [Veritas-bu] vmchange script
Hi Team,

Here's is my challenge.

Every week I have to change tapes in two libraries one has a cap size of 25 and another has of 35.

Now I get a list of tapes to be ejected and sent offsite via script the real challenge is ejecting them.

I can use the vmchange command in two separate consoles

Syntax : vmchange -res -multi_eject -w -rn 0 -rt tld -rh pnors950.mgroupnet.com -ml

Example :vmchange -res -multi_eject -w -rn 0 -rt tld -rh server.xyz.com -ml MO0371:MO0012:MO0454:MO0775:MO0017

I want to create a script which automates this one of the sample script is

FOR /F %%i IN (E:setin.txt) DO E:VERITASVolmgrbinvmchange -res -multi_eject -w -rn 3 -rt tld -rh pnors954.mgroupnet.com -ml %%i>>E:ejectoutput.txt

The above script uses a file setin.txt which would have list of labels with colon separated

MO0371:MO0012:MO0454:MO0775:MO0017

The only challenge is this I want the script to take input of labels as file and do not want manually colon separate them manually.

Please provide suggestions.

Anurag

_______________________________________________

Veritas-bu maillist - Veritas-bu < at > mailman.eng.auburn.edu

[mailman.eng.auburn.edu]

Athena®, Created for the Cause™
Making a Difference in the Fight Against Breast Cancer

How can I show my support for bottled water?
Take a minute to sign a petition in support of bottled water. Your signature COUNTS! Available through the bottledwatermatters.org/luv-bottled-water website, the goal is 50,000 signatures. Please include your personal email address when submitting. Once completed, share the website with your family and friends, to ensure as many bottled water supporters as possible sign the petition

---------------------------------
CONFIDENTIALITY NOTICE: This e-mail may contain privileged or confidential information and is for the sole use of the intended recipient(s). If you are not the intended recipient, any disclosure, copying, distribution, or use of the contents of this information is prohibited and may be unlawful. If you have received this electronic transmission in error, please reply immediately to the sender that you have received the message in error, and delete it. Thank you.
----------------------------------
vmchange script
February 22, 2012 06:52AM
Try findstr /v on Windows for the second example. I’m not sure what “^$” evaluates to, but this should help.

http://technet.microsoft.com/en-us/library/bb490907.aspx

-Jonathan

From: veritas-bu-bounces < at > mailman.eng.auburn.edu [mailto] On Behalf Of netbackup < at > whelan-consulting.co.uk
Sent: Monday, February 20, 2012 7:26 AM
To: veritas-bu; dreamleo < at > gmail.com; Anurag Sharma
Subject: Re: [Veritas-bu] vmchange script

Hi,

Windows:

type <file name> | find ":"

*NIX
grep ":" <file name>
or
grep -v "^$" <file name>

I can't find the windows equivalent of the last command, if there is one.

Regards,

Patrick

On 20 February 2012 at 10:38 Anurag Sharma <sharma.anurag < at > hotmail.com> wrote:

Quote


Thank you Leo,

Could please tell me how can get a : seprated output if I already have a list of media to be expired in another text file in a tabular format ?

What I'm asking is this - I want a command which converts

:MO0174

:MO0928

:MO0486

:MO0074

:MO0718

:MO0355

:MO0789

to this
:MO0174
:MO0928
:MO0486
:MO0074
:MO0718
:MO0355
:MO0789

Date: Tue, 14 Feb 2012 17:30:07 +0800
Subject: Re: [Veritas-bu] vmchange script
From: dreamleo < at > gmail.com
To: veritas-bu < at > mailman.eng.auburn.edu
CC: sharma.anurag < at > hotmail.com

Hi

Last time i use this to generate a file with colon separated media labels:

< at > bpimagelist -A -media -idonly -hoursago 24 | find "MO" | tr rn ":" | sed -e s/::/:/g -e s/:$//g > %MEDIA_FILE%

Hope it help.

Leo

On Sun, Feb 12, 2012 at 10:35 PM, Justin Piszcz <jpiszcz < at > lucidpixels.com> wrote:

Hi,
That would be just the media label— one command per TAPE.
vmchange .. etc etc .. –ml TAPE01
vmchange .. etc etc .. –ml TAPE02vmchange .. etc etc .. –ml TAPE03
Justin.

From: Anurag Sharma [mailto]

Sent: Sunday, February 12, 2012 8:59 AM
To: jpiszcz < at > lucidpixels.com; veritas-bu
Subject: RE: [Veritas-bu] vmchange script

Justin,

$Tape

What would that file contain

just the media labels

or

media labels which are colon seperated. if yes kind send how this script would look in windows nbu

From: jpiszcz < at > lucidpixels.com
To: sharma.anurag < at > hotmail.com; veritas-bu < at > mailman.eng.auburn.edu

Subject: RE: [Veritas-bu] vmchange script
Date: Sun, 12 Feb 2012 08:27:39 -0500Hi,

There is a better way.
There is an undocumented option called –single_cycle.
This will put the tapes in the cap one by one and not prompt you to remove them.
The best of both worlds J

Example Syntax:
/usr/openv/volmgr/bin/vmchange -h "$MASTER_SERVER" -rh "$ROBOT_CTRL_HOST" -rn "$ROBOT_NUM" -rt "$ROBOT_TYPE" -multi_eject -map any -res -ml "$TAPE" -verbose -single_cycle

Justin.

From: veritas-bu-bounces < at > mailman.eng.auburn.edu [mailto] On Behalf Of Anurag Sharma

Sent: Sunday, February 12, 2012 7:40 AM
To: veritas-bu
Subject: [Veritas-bu] vmchange script
Hi Team,

Here's is my challenge.

Every week I have to change tapes in two libraries one has a cap size of 25 and another has of 35.

Now I get a list of tapes to be ejected and sent offsite via script the real challenge is ejecting them.

I can use the vmchange command in two separate consoles

Syntax : vmchange -res -multi_eject -w -rn 0 -rt tld -rh pnors950.mgroupnet.com -ml

Example :vmchange -res -multi_eject -w -rn 0 -rt tld -rh server.xyz.com -ml MO0371:MO0012:MO0454:MO0775:MO0017

I want to create a script which automates this one of the sample script is

FOR /F %%i IN (E:setin.txt) DO E:VERITASVolmgrbinvmchange -res -multi_eject -w -rn 3 -rt tld -rh pnors954.mgroupnet.com -ml %%i>>E:ejectoutput.txt

The above script uses a file setin.txt which would have list of labels with colon separated

MO0371:MO0012:MO0454:MO0775:MO0017

The only challenge is this I want the script to take input of labels as file and do not want manually colon separate them manually.

Please provide suggestions.

Anurag

_______________________________________________

Veritas-bu maillist - Veritas-bu < at > mailman.eng.auburn.edu

[mailman.eng.auburn.edu]
vmchange script
February 22, 2012 11:24AM
< at > Echo Off
For /F "tokens=* delims=" %A in (yourfilename) Do Echo %A

in a batch file, use %%A.

On Wed, Feb 22, 2012 at 9:51 AM, Martin, Jonathan <JMARTI05 < at > intersil.com> wrote:
Quote

Try findstr /v on Windows for the second example. I’m not sure what “^$”
evaluates to, but this should help.

[technet.microsoft.com]

-Jonathan

From: veritas-bu-bounces < at > mailman.eng.auburn.edu
[mailto] On Behalf Of
netbackup < at > whelan-consulting.co.uk
Sent: Monday, February 20, 2012 7:26 AM
To: veritas-bu; dreamleo < at > gmail.com; Anurag Sharma
Subject: Re: [Veritas-bu] vmchange script

Hi,

Windows:

type <file name> | find ":"

*NIX

grep ":" <file name>

or

grep -v "^$" <file name>

I can't find the windows equivalent of the last command, if there is one.

Regards,

Patrick

On 20 February 2012 at 10:38 Anurag Sharma <sharma.anurag < at > hotmail.com>
wrote:

Quote


Thank you Leo,

Could please tell me how can get a : seprated output if I already have a
list of media to be expired in another text file in a tabular format ?

What I'm asking is this - I want a command which converts

   :MO0174

   :MO0928

   :MO0486

   :MO0074

   :MO0718

   :MO0355

   :MO0789

to this
   :MO0174
   :MO0928
   :MO0486
   :MO0074
   :MO0718
   :MO0355
   :MO0789

Date: Tue, 14 Feb 2012 17:30:07 +0800
Subject: Re: [Veritas-bu] vmchange script
From: dreamleo < at > gmail.com
To: veritas-bu < at > mailman.eng.auburn.edu
CC: sharma.anurag < at > hotmail.com

Hi

Last time i use this to generate a file with colon separated media labels:

< at > bpimagelist -A -media -idonly -hoursago 24 | find "MO" | tr rn ":" |
sed -e s/::/:/g -e s/:$//g > %MEDIA_FILE%

Hope it help.

Leo

On Sun, Feb 12, 2012 at 10:35 PM, Justin Piszcz <jpiszcz < at > lucidpixels.com>
wrote:

Hi,
  That would be just the media label— one command per TAPE.
  vmchange .. etc etc .. –ml TAPE01
vmchange .. etc etc .. –ml TAPE02vmchange .. etc etc .. –ml TAPE03
  Justin.

From: Anurag Sharma [mailto]

Sent: Sunday, February 12, 2012 8:59 AM
To: jpiszcz < at > lucidpixels.com; veritas-bu
Subject: RE: [Veritas-bu] vmchange script

Justin,

$Tape

What would that file contain

just the media labels

or

media labels which are colon seperated. if yes kind send how this script
would look in windows nbu

From: jpiszcz < at > lucidpixels.com
To: sharma.anurag < at > hotmail.com; veritas-bu < at > mailman.eng.auburn.edu

Subject: RE: [Veritas-bu] vmchange script
Date: Sun, 12 Feb 2012 08:27:39 -0500Hi,

There is a better way.
There is an undocumented option called –single_cycle.
This will put the tapes in the cap one by one and not prompt you to remove
them.
The best of both worlds J

Example Syntax:
/usr/openv/volmgr/bin/vmchange -h "$MASTER_SERVER" -rh "$ROBOT_CTRL_HOST"
-rn "$ROBOT_NUM" -rt "$ROBOT_TYPE" -multi_eject -map any -res -ml "$TAPE"
-verbose -single_cycle

Justin.

From: veritas-bu-bounces < at > mailman.eng.auburn.edu
[mailto] On Behalf Of Anurag
Sharma

Sent: Sunday, February 12, 2012 7:40 AM
To: veritas-bu
Subject: [Veritas-bu] vmchange script
Hi Team,

Here's is my challenge.

Every week I have to change tapes in two libraries one has a cap size of
25 and another has of 35.

Now I get a list of tapes to be ejected and sent offsite via script the
real challenge is ejecting them.

I can use the vmchange command in two separate consoles

Syntax : vmchange -res -multi_eject -w -rn 0 -rt tld -rh
pnors950.mgroupnet.com -ml

Example :vmchange -res -multi_eject -w -rn 0 -rt tld -rh server.xyz.com
-ml MO0371:MO0012:MO0454:MO0775:MO0017

I want to create a script which automates this one of the sample script is

FOR /F %%i IN (E:setin.txt) DO E:VERITASVolmgrbinvmchange -res
-multi_eject -w -rn 3 -rt tld -rh pnors954.mgroupnet.com -ml
%%i>>E:ejectoutput.txt

The above script uses a file setin.txt which would have list of labels
with colon separated

MO0371:MO0012:MO0454:MO0775:MO0017

The only challenge is this I want the script to take input of labels as
file and do not want manually colon separate them manually.

Please provide suggestions.

Anurag

_______________________________________________

Veritas-bu maillist  -  Veritas-bu < at > mailman.eng.auburn.edu

[mailman.eng.auburn.edu]

_______________________________________________
Veritas-bu maillist  -  Veritas-bu < at > mailman.eng.auburn.edu
[mailman.eng.auburn.edu]
_______________________________________________
Veritas-bu maillist - Veritas-bu < at > mailman.eng.auburn.edu
[mailman.eng.auburn.edu]
Sorry, only registered users may post in this forum.

Click here to login


Parse error: syntax error, unexpected 'GoogleAnalyticsObject' (T_STRING), expecting ']' in /tmp/tpl-lightweight_blue-footer-bc9d4c1f6d5e5fdfdcbff526fb7bae92.php-stage2 on line 6