TapeTrack Documentation

Because there is more to tape management than you ever realized

User Tools

Site Tools


technote:command_line_diagnosis

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
technote:command_line_diagnosis [2025/07/04 03:28] – [Locate Batch File Via Windows Scheduler] Scott Cunliffetechnote:command_line_diagnosis [2025/07/04 04:27] (current) – [Forwarding The Stdout And Stderr Files] Scott Cunliffe
Line 49: Line 49:
 {{event.png}} {{event.png}}
  
-In this example you can see the batch file Daily.bat is located at C:Program Files\TapeTrack\TapeTrack Framework Server\scrips+In this example you can see the batch file Daily.bat is located at ''C:Program Files\TapeTrack\TapeTrack Framework Server\scripts''
  
 +==== Locate Stdout And Stderr ====
  
 +navigate to the batch file using File Explorer, right click on the batch file and select ''Edit'' or ''Open in Notepad'' to view the code.
  
 +The file may contain different variables at the top, setting various actions for the creation of the report or task.  Following this will be a line of code calling the command line program with various attributes followed by the redirections of the stdout and stderr streams.
 +
 +<code>
 +TMSS10Inventory -S user:-pass@serveraddress -V "US01.*.*" > ./reports/Inventory_Report.txt 2> ./reports/Inventory_Report_stderr.txt
 +</code>
 +
 +The redirect ''>'' redirects the stdout stream, Inventory_Report.txt, to the reports folder in the current directory.
 +
 +The redirect ''2>'' redirects the stderr stream, called Inventory_Report_stderr.txt to the reports folder in the current directory.
 +
 +If the file location uses variables in the path, you will need to find the value of the variable to decode the path.
 +
 +Standard variables set by TapeTrack upon installation include
 +
 +<code>
 +TMSS10BACK=C:\Program Files\TapeTrack\TapeTrack Framework Server\var\backup
 +TMSS10DB=C:\Program Files\TapeTrack\TapeTrack Framework Server\var\db
 +TMSS10REPORTS=C:\Program Files\TapeTrack\TapeTrack Framework Server\var\reports
 +TMSS10SCRIPTS=C:\Program Files\TapeTrack\TapeTrack Framework Server\scripts
 +TMSS10SYNCBASE=C:\Program Files\TapeTrack\TapeTrack Sync\
 +</code>
 +
 +For example
 +
 +<code>
 +TMSS10MoveList -S %TTSERVER% > "%TMSS10REPORTS%\movelist_report.txt" 2> "%TMSS10REPORTS%\movelist_error.txt" 
 +</code>
 +
 +The stderr stream is directed to ''C:\Program Files\TapeTrack\TapeTrack Framework Server\var\reports\movelist_error.txt''
 +==== Forwarding The Stdout And Stderr Files ====
 +
 +Using a file zipping program, such as winzip or 7zip, zip up the files (batch file, stdout and stderr files) and attach the file to the [[common:support_details|support ticket]] along with the best description of the problem you are experiencing.
 +
 +{{tag>technote cli}}
technote/command_line_diagnosis.1751599689.txt.gz · Last modified: 2025/07/04 03:28 by Scott Cunliffe