scriptmgr - utility for controlling other skytools scripts.
scriptmgr.py [switches] config.ini <command> [-a | -t service | job_name...]
scriptmgr is used to manage several scripts together. It discovers potential jobs based on config file glob expression. From config file it gets both job_name and service type (that is the main section name, e.g. [cube_dispatcher]). For each service type there is subsection in the config how to handle it. Unknown services are ignored.
status scriptmgr config.ini status Show status for all known jobs. start scriptmgr config.ini start -a scriptmgr config.ini start -t service scriptmgr config.ini start job_name1 job_name2 ... Launch script(s) that are not running. stop scriptmgr config.ini stop -a scriptmgr config.ini stop -t service scriptmgr config.ini stop job_name1 job_name2 ... Stop script(s) that are running. restart scriptmgr config.ini restart -a scriptmgr config.ini restart -t service scriptmgr config.ini restart job_name1 job_name2 ... Restart scripts. reload scriptmgr config.ini reload -a scriptmgr config.ini reload -t service scriptmgr config.ini reload job_name1 job_name2 ... Send SIGHUP to scripts that are running.
Common configuration parameters job_name Name for particulat job the script does. Script will log under this name to logdb/logserver. The name is also used as default for PgQ consumer name. It should be unique. pidfile Location for pid file. If not given, script is disallowed to daemonize. logfile Location for log file. loop_delay If continuisly running process, how long to sleep after each work loop, in seconds. Default: 1. connection_lifetime Close and reconnect older database connections. use_skylog foo. scriptmgr parameters config_list List of glob patterns for finding config files. Example: config_list = ~/dbscripts/conf/*.ini, ~/random/conf/*.ini Service section parameters cwd Working directory for script. args Arguments to give to script, in addition to -d. script Path to script. Unless script is in PATH, full path should be given. disabled If this service should be ignored. user Launch service as different unix user. Scriptmgr uses sudo to switch users. So it either needs to be run as root, or sudo config must allow it to launch daemons. Example config file [scriptmgr] job_name = scriptmgr_livesrv logfile = ~/log/%(job_name)s.log pidfile = ~/pid/%(job_name)s.pid config_list = ~/scripts/conf/*.ini # defaults for all service sections [DEFAULT] cwd = ~/scripts [table_dispatcher] script = table_dispatcher.py args = -v [cube_dispatcher] script = python2.4 cube_dispatcher.py disabled = 1 [pgqadm] script = ~/scripts/pgqadm.py args = ticker
Following switches are common to all skytools.DBScript-based Python programs. -h, --help show help message and exit -q, --quiet make program silent -v, --verbose make program more verbose -d, --daemon make program go background --ini show commented template config file. Following switches are used to control already running process. The pidfile is read from config then signal is sent to process id specified there. -r, --reload reload config (send SIGHUP) -s, --stop stop program safely (send SIGINT) -k, --kill kill program immidiately (send SIGTERM) Options specific to scriptmgr: -a, --all Operate on all non-disabled scripts. -t service, --type=service Operate on all non-disabled scripts of this service type. -w, --wait Wait for script(s) after signalling. 01/15/2016 SCRIPTMGR(1)
Personal Opportunity - Free software gives you access to billions of dollars of software at no cost. Use this software for your business, personal use or to develop a profitable skill. Access to source code provides access to a level of capabilities/information that companies protect though copyrights. Open source is a core component of the Internet and it is available to you. Leverage the billions of dollars in resources and capabilities to build a career, establish a business or change the world. The potential is endless for those who understand the opportunity.
Business Opportunity - Goldman Sachs, IBM and countless large corporations are leveraging open source to reduce costs, develop products and increase their bottom lines. Learn what these companies know about open source and how open source can give you the advantage.
Free Software provides computer programs and capabilities at no cost but more importantly, it provides the freedom to run, edit, contribute to, and share the software. The importance of free software is a matter of access, not price. Software at no cost is a benefit but ownership rights to the software and source code is far more significant.
Free Office Software - The Libre Office suite provides top desktop productivity tools for free. This includes, a word processor, spreadsheet, presentation engine, drawing and flowcharting, database and math applications. Libre Office is available for Linux or Windows.
The Free Books Library is a collection of thousands of the most popular public domain books in an online readable format. The collection includes great classical literature and more recent works where the U.S. copyright has expired. These books are yours to read and use without restrictions.
Source Code - Want to change a program or know how it works? Open Source provides the source code for its programs so that anyone can use, modify or learn how to write those programs themselves. Visit the GNU source code repositories to download the source.
Study at Harvard, Stanford or MIT - Open edX provides free online courses from Harvard, MIT, Columbia, UC Berkeley and other top Universities. Hundreds of courses for almost all major subjects and course levels. Open edx also offers some paid courses and selected certifications.
Linux Manual Pages - A man or manual page is a form of software documentation found on Linux/Unix operating systems. Topics covered include computer programs (including library and system calls), formal standards and conventions, and even abstract concepts.