Database Generator Script Script Listing

Putting It All Together

This whole section is just a listing of a current development script. I make no claims to its accuracy or functionality. Being a development site most of my scripts are in constant change anyway, which is why I embarked on a method of simplification and supportability. In these pages you should find more than enough examples of ways to do things. Some good, some not so good. The thing is, you should now be able to understand what this listing means and how it works.

Database Generator Script:

This listing is a Bourne Shell Script which uses many of the features already described in this document. There are still some areas where another function would be helpful but the script is still in flux and will not yet submit to functions in all areas. The script itself is used to create an empty Oracle database on a Solaris platform. The script expects a particular disk structure based on the Oracle Flexible Architecture scheme and so there is some hard coding in places. The tablespace sizes and extent and segment defaults are all selected and calculated from some dependant environment variables which are set up on a per server basis, with numbers based on expected user community size. There is a special profile called .profile_references which contains the complete networked site parameters for all the servers in the network that this script runs on. This profile is also duplicated in appendix A for your information.

generate_db listing

Please note that there looks to be several areas where formatting of the script has gone astray. The raw file is fine however and this just appears to be an artifact when viewed in html format via a browser. If you download the the complete fileset the script will be formatted correctly. I also apologise for the width of this file. This is due in part to the line by line comments which I have provided to ease the readers understanding.

Home Next Preface Introduction Basic Shells Shell Syntax Built-In Commands Command Substitution Startup & Environment Pipes, Lists & Redirection Input & Output Using Files Design Considerations Functions Debugging Putting It All Together Appendix Code Examples Page 214 This page was brought to you by rhreepe@injunea.demon.co.uk