]> git.sur5r.net Git - bacula/docs/blobdiff - docs/manual/console.tex
This commit was manufactured by cvs2svn to create tag
[bacula/docs] / docs / manual / console.tex
index af9b0701bc71bba01838341802edff4c45e77cbd..2c98c45f01a95c3e082bece6da9c1464cf7c5206 100644 (file)
@@ -120,8 +120,127 @@ returned to the main command prompt or if appropriate the previous prompt (in
 the case of nested prompts). In a few places such as where it is asking for a
 Volume name, the period will be taken to be the Volume name. In that case, you
 will most likely be able to cancel at the next prompt. 
-\label{list}
 
+\label{keywords}
+\subsection*{Alphabetic List of Console Keywords}
+\index[general]{Keywords!Alphabetic List of Console }
+\index[general]{Alphabetic List of Console Keywords }
+\index[console]{Keywords!Alphabetic List of Console }
+\index[console]{Alphabetic List of Console Keywords }
+\addcontentsline{toc}{subsection}{Alphabetic List of Console Keywords}
+Unless otherwise specified, each of the following keywords
+takes an argument, which is specified after the keyword following
+an equal sign. For example:
+
+\begin{verbatim}
+jobid=536
+\end{verbatim}
+
+Please note, this list is incomplete as it is currently in
+the process of being created and is not currently totally in 
+alphabetic
+order ...
+
+\begin{description}
+\item [restart]
+  Permitted on the python command, and causes the Python 
+  interpreter to be restarted. Takes no argument.
+\item [all]
+  Permitted on the status and show commands to specify all components or
+  resources respectively.
+\item [before]
+  Used in the restore command.
+\item [bootstrap]
+  Used in the restore command.
+\item [catalog]
+  Allowed in the use command to specify the catalog name
+  to be used.
+\item [catalogs]
+  Used in the show command. Takes no arguments.
+\item [client | fd]
+\item [clients]
+  Used in the show, list, and llist commands. Takes no arguments.
+\item [counters]
+  Used in the show command. Takes no arguments.
+\item [current]
+  Used in the restore command. Takes no argument.
+\item [days]
+\item [devices]
+  Used in the show command. Takes no arguments.
+\item [dir | director]
+\item [directors]
+  Used in the show command. Takes no arguments.
+\item [directory]
+  Used in the restore command.
+\item [done]
+  Used in the restore command. Takes no argument.
+\item [file]
+  Used in the restore command.
+\item [files]
+  Used in the list and llist commands. Takes no arguments.
+\item [fileset]
+\item [filesets]
+  Used in the show command. Takes no arguments.
+\item [help]
+  Used in the show command. Takes no arguments.
+\item [jobs]
+  Used in the show, list and llist commands. Takes no arguments.
+\item [jobmedia]
+  Used in the list and llist commands. Takes no arguments.
+\item [jobtotals]
+  Used in the list and llist commands. Takes no arguments.
+\item [jobid]
+  The JobId is the numeric jobid that is printed in the Job
+  Report output. It is the index of the database record for the
+  given job. While it is unique for all the existing Job records
+  in the catalog database, the same JobId can be reused once a
+  Job is removed from the catalog. Probably you will refer
+  specific Jobs that ran using their numeric JobId.
+\item [job | jobname]
+  The Job or Jobname keyword refers to the name you specified
+  in the Job resource, and hence it refers to any number of
+  Jobs that ran.  It is typically useful if you want to list
+  all jobs of a particular name.
+\item [level]
+\item [listing]
+  Permitted on the estimate command. Takes no argument.
+\item [limit]
+\item [messages]
+  Used in the show command. Takes no arguments.
+\item [media]
+  Used in the list and llist commands. Takes no arguments.
+\item [nextvol | nextvolume]
+  Used in the list and llist commands. Takes no arguments.
+\item [on]
+  Takes no keyword.
+\item [off]
+  Takes no keyword.
+\item [pool]
+\item [pools]
+  Used in the show, list, and llist commands. Takes no arguments.
+\item [select]
+  Used in the restore command. Takes no argument.
+\item [storages]
+  Used in the show command. Takes no arguments.
+\item [schedules]
+  Used in the show command. Takes no arguments.
+\item [sd | store | storage]
+\item [ujobid]
+  The ujobid is a unique job identification that is printed
+  in the Job Report output. At the current time, it consists
+  of the Job name (from the Name directive for the job) appended
+  with the date and time the job was run. This keyword is useful
+  if you want to completely identify the Job instance run.
+\item [volume]
+\item [volumes]
+  Used in the list and llist commands. Takes no arguments.
+\item [where]
+  Used in the restore command.
+\item [yes]
+  Used in the restore command. Takes no argument.
+\end{description}
+
+\label{list}
 \subsection*{Alphabetic List of Console Commands}
 \index[general]{Commands!Alphabetic List of Console }
 \index[general]{Alphabetic List of Console Commands }
@@ -169,7 +288,7 @@ command below for  the list of legal characters in a Volume name.
    off, you must explicitly {\bf mount} the tape after a label command to
    use it.
 
-\item [{cancel [jobid=\lt{}number\gt{} job=\lt{}job-name\gt{}]}]
+\item [{cancel [jobid=\lt{}number\gt{} job=\lt{}job-name\gt{} ujobid=\lt{}unique-jobid\gt{}]}]
    \index[console]{cancel jobid}
    This command is used to cancel a job and accepts {\bf jobid=nnn} or {\bf
    job=xxx} as an argument where nnn is replaced by the JobId and xxx is
@@ -234,6 +353,24 @@ delete Job JobId=n,m,o-r,t ...
    number. That is a "delete jobid" accepts lists and ranges of
    jobids.
 
+\item [disable job\lt{}job-name\gt{}]
+  \index[console]{enable}
+  This command permits you to disable a Job for automatic scheduling. 
+  The job may have been previously enabled with the Job resource      
+  {\bf Enabled} directive or using the console {\bf enable} command.
+  The next time the Director is restarted or the conf file is reloaded,
+  the Enable/Disable state will be set to the value in the Job resource
+  (default enabled).
+
+\item [enable job\lt{}job-name\gt{}]
+  \index[console]{enable}
+  This command permits you to enable a Job for automatic scheduling. 
+  The job may have been previously disabled with the Job resource      
+  {\bf Enabled} directive or using the console {\bf disable} command.
+  The next time the Director is restarted or the conf file is reloaded,
+  the Enable/Disable state will be set to the value in the Job resource
+  (default enabled).
+
 \label{estimate}
 \item [estimate]
    \index[console]{estimate}
@@ -387,19 +524,26 @@ update storage=xxx pool=yyy slots=1-5,10 barcodes
 \begin{verbatim}
    list jobs
    
-   list jobid=\lt{}id\gt{}
+   list jobid=<id>           (list jobid id)
+
+   list ujobid<unique job name> (list job with unique name)
    
-   list job=\lt{}job-name\gt{}
+   list job=<job-name>   (list all jobs with "job-name")
+
+   list jobname=<job-name>  (same as above)
+
+     In the above, you can add "limit=nn" to limit the output to
+     nn jobs.
    
    list jobmedia
    
-   list jobmedia jobid=\lt{}id\gt{}
+   list jobmedia jobid=<id>
    
-   list jobmedia job=\lt{}job-name\gt{}
+   list jobmedia job=<job-name>
    
-   list files jobid=\lt{}id\gt{}
+   list files jobid=<id>
    
-   list files job=\lt{}job-name\gt{}
+   list files job=<job-name>
    
    list pools
    
@@ -409,19 +553,19 @@ update storage=xxx pool=yyy slots=1-5,10 barcodes
    
    list volumes
    
-   list volumes jobid=\lt{}id\gt{}
+   list volumes jobid=<id>
    
-   list volumes pool=\lt{}pool-name\gt{}
+   list volumes pool=<pool-name>
    
-   list volumes job=\lt{}job-name\gt{}
+   list volumes job=<job-name>
    
-   list volume=\lt{}volume-name\gt{}  
+   list volume=<volume-name>  
 
-   list nextvolume job=\lt{}job-name\gt{}
+   list nextvolume job=<job-name>
    
-   list nextvol job=\lt{}job-name\gt{}
+   list nextvol job=<job-name>
 
-   list nextvol job=\lt{}job-name\gt{} days=nnn
+   list nextvol job=<job-name> days=nnn
 
 
 
@@ -862,15 +1006,94 @@ status [all | dir=\lt{}dir-name\gt{} | director |
    occurrence of each run statement for the job will be displayed for the
    period specified.
 
+   If your job seems to be blocked, you can get a general idea of the
+   problem by doing a {\bf status dir}, but you can most often get a 
+   much more specific indication of the problem by doing a
+   {\bf status storage=xxx}.  For example, on an idle test system, when
+   I do {\bf status storage=File}, I get:
+\footnotesize
+\begin{verbatim}
+status storage=File
+Connecting to Storage daemon File at 192.168.68.112:8103
+
+rufus-sd Version: 1.39.6 (24 March 2006) i686-pc-linux-gnu redhat (Stentz)
+Daemon started 26-Mar-06 11:06, 0 Jobs run since started.
+
+Running Jobs:
+No Jobs running.
+====
+
+Jobs waiting to reserve a drive:
+====
+
+Terminated Jobs:
+ JobId  Level   Files          Bytes Status   Finished        Name 
+======================================================================
+    59  Full        234      4,417,599 OK       15-Jan-06 11:54 kernsave
+====
+
+Device status:
+utochanger "DDS-4-changer" with devices:
+   "DDS-4" (/dev/nst0)
+Device "DDS-4" (/dev/nst0) is mounted with Volume="TestVolume002"
+Pool="*unknown*"
+    Slot 2 is loaded in drive 0.
+    Total Bytes Read=0 Blocks Read=0 Bytes/block=0
+    Positioned at File=0 Block=0
+Device "Dummy" is not open or does not exist.
+No DEVICE structure.
+
+Device "DVD-Writer" (/dev/hdc) is not open.
+Device "File" (/tmp) is not open.
+====
+
+In Use Volume status:
+====
+\end{verbatim}
+\normalsize
+
+Now, what this tells me is that no jobs are running and that none of
+the devices are in use.  Now, if I {\bf unmount} the autochanger, which
+will not be used in this example, and then start a Job that uses the
+File device, the job will block.  When I re-issue the status storage
+command, I get for the Device status:
+
+\footnotesize
+\begin{verbatim}
+status storage=File
+...
+Device status:
+Autochanger "DDS-4-changer" with devices:
+   "DDS-4" (/dev/nst0)
+Device "DDS-4" (/dev/nst0) is not open.
+    Device is BLOCKED. User unmounted.
+    Drive 0 is not loaded.
+Device "Dummy" is not open or does not exist.
+No DEVICE structure.
+
+Device "DVD-Writer" (/dev/hdc) is not open.
+Device "File" (/tmp) is not open.
+    Device is BLOCKED waiting for media.
+====
+...
+\end{verbatim}
+\normalsize
+
+Now, here it should be clear that if a job were running that wanted
+to use the Autochanger (with two devices), it would block because
+the user unmounted the device. The real problem for the Job I started
+using the "File" device is that the device is blocked waiting for
+media -- that is Bacula needs you to label a Volume.
+
 \item [unmount]
    \index[console]{unmount}
    This command causes the indicated Bacula Storage  daemon to unmount the
    specified device. The forms of the command  are the same as the mount command:
 \footnotesize
 \begin{verbatim}
-unmount storage=\lt{}storage-name\gt{}
+unmount storage=<storage-name>
 
-unmount [ jobid=\lt{}id\gt{} | job=\lt{}job-name\gt{} ]
+unmount [ jobid=<id> | job=<job-name> ]
 \end{verbatim}
 \normalsize