[] [] [] []
Next: UBS Troubleshooting Up: Unattended Broadcasting System User Previous: Configuring the UBS   Contents

Running the UBS

Once the UBS has been successfully installed and configured, it can be launched in several different ways, from either a particular graphical frontend or the included command line utility. At the time of writing this draft, no fully functional graphical frontends exist for the UBS, so this document will focus primarily on the UBS shell. The UBS shell is a command line interface, similar to that of a unix command line interface. Although the UBS shell lacks much of the functionality in most unix shells, it is a sufficient interface for controlling various parts of the UBS.
To start the UBS shell, simply call the UBS executable from a regular unix command line. A transcript of this might look as such:
shell$ cd /usr/local/ubs
shell$ ./bin/ubs
Welcome to the UBS.  Use the 'help' command for more info.
ubs-0.15>
The shell currently recognizes approximately a dozen commands. For a complete list of commands, type help at the shell's command prompt. Each individual command also has its own specific help, which is available by running command -h. Each command also recognizes a number of different output formats, which are useful in various situations. The most commonly used output formats are:
-e
Regular English output. This is the default output format.
-w
HTML output. Useful for webpages, or web-based scripts accessing the UBS shell.
-c
Comma separated value output. Also useful for scripting.
-s
Silent; no output is produced.
To start the UBS daemons, the start command is used. The start command may take in the name of a single UBS daemon, in which case it will start only the one respective daemon. If no arguments are given, the shell will start all known daemons, which is anything in the form of ubs-name in the bin/ directory of the UBS installation. An example session of starting and stopping the UBS might look something like this:
ubs-0.15> start
ubs-event: Started
ubs-sched: Started
ubs-play: Started
ubs-0.15> stop
ubs-event: Stopped
ubs-sched: Stopped
ubs-play: Stopped
Other commands recognized by the UBS include:
events
Displays information about all known events as specified in the ubs.conf file.
help
Print out more help about a particular command. If no specific command is given, all known commands are printed out.
log
Gives information about logfiles, and can also display the tail portion of a particular logfile. The log command must be passed the name of a logfile, which can be acquired from the "-l" option. Known arguments include:
-n
Number of lines to seek back in the logfile.
-l
List all known logs.
queue
Displays information about the queue, and can also add files to or clear out the current queue. Known arguments include:
-d
Display the current queue (default action).
-a
Append the filename given after this argument to the end of the queue.
-p
Prepend the filename given after this argument to the front of the queue.
-z
Clear out all entries in the queue.
restart
Issues a stop and start command to all known daemons if no arguments are given, or a single daemon specified on the command line.
sched
Shows the schedule for the current week, and what shows are to be played in which timeslots.
search
Frontend to the UBS search engine, which is capable of locating filenames based on querying ID3 tags in all known music files. Will return all files which match either by filename or metadata (ogg/id3 tag) based on a query given from the command line. Known arguments include:
-r
Recache the data for the search engine. This must be done on a regular basis, since the UBS caches the music metadata in a single file, rather than searching all music files each time a query is done.
shows
Displays information about the schedule of shows. Known arguments include:
-n
Only display information for the show currently playing on the air.
-p
Display information for the song currently playing on the air.
start
Starts the UBS daemons (all if no argument is given, a single one otherwise), launching them into the background. Note that if the shell is exited, the daemons will continue to run.
status
Displays the current status of each daemon.
stop
Stops the UBS daemons or a single daemon if given as an argument.
tag
Prints out information from ID3/Ogg Vorbis tags in music files.
version
Show the current version of the UBS.
exit
Quit the UBS. This will not terminate any UBS daemons that are running.


[] [] [] []
Next: UBS Troubleshooting Up: Unattended Broadcasting System User Previous: Configuring the UBS   Contents
2003-10-30