20
Chapter 02 -- Installation of the EMS A Nearly Complete Guide to the EMS V13 Chapter | 2-1 Chapter 2: Installation of the EMS Chapter Contents: 2.1 Introduction -- because you have to start somewhere 2.2 System requirements for installing the ems 2.3 Installing the EMS 2.3.1 The basics - the stuff you should know 2.3.2 What happens during the installation process? 2.3.3 Installing from DVD 2.3.4 Installing from the internet 2.3.5 Local network installation 2.3.6 Making sure your Installation was a success 2.3.7 Potentially useful options when installing the EMS 2.4 Updating your EMS with passion 2.4.1 More basics - the stuff you sorta gotta know 2.4.2 Potentially useful updating options 2.5 Some basic information that may only be of limited use 2.6 Still more options, but this time, potentially valuable 2.7 Target binaries and you 2.1 Introduction -- Because You Have To Start Somewhere Installation of the EMS requires the use of ems_install.pl, which was developed to tackle all the challenges you might encounter during a manual installation of an NWP system. It is highly recommend that you use the most current release of this routine, as your life will become less complicated and more fulfilled if you do. And that’s a statement only a few modeling systems can make! So, “Where might I get this ems_install.pl utility thing,” you ask? All NOAA-affiliated users of the EMS may simply request the current routine from the SOO Science and Training Coordinator (SOO STRC). All non-NOAA users, (i.e., everyone else), must register for the EMS on the SOO/STRC site: http://strc.comet.ucar.edu/software/newrems Registration allows the user to receive notification of updates as they become available, and also allows the developer to advance his world geography knowledge when a request from Mauritius is submitted. Note that there may be a delay in receiving the ems_install.pl utility following registration, as the submitted information is checked both for some semblance of legitimacy and to avoid advertisements for “personal enhancement” products from being sent to valid users. Once the EMS concierge is able to confirm your registration, which typically takes a few minutes, or as much as a week should the lone support person be out of the office or comatose, you will receive a second message with the

Installation

Embed Size (px)

DESCRIPTION

komputer

Citation preview

  • Chapter 02 -- Installation of the EMS

    A Nearly Complete Guide to the EMS V13 C h a p t e r | 2-1

    Chapter 2: Installation of the EMS Chapter Contents:

    2.1 Introduction -- because you have to start somewhere

    2.2 System requirements for installing the ems

    2.3 Installing the EMS

    2.3.1 The basics - the stuff you should know 2.3.2 What happens during the installation process? 2.3.3 Installing from DVD 2.3.4 Installing from the internet 2.3.5 Local network installation 2.3.6 Making sure your Installation was a success 2.3.7 Potentially useful options when installing the EMS

    2.4 Updating your EMS with passion

    2.4.1 More basics - the stuff you sorta gotta know 2.4.2 Potentially useful updating options

    2.5 Some basic information that may only be of limited use

    2.6 Still more options, but this time, potentially valuable

    2.7 Target binaries and you

    2.1 Introduction -- Because You Have To Start Somewhere Installation of the EMS requires the use of ems_install.pl, which was developed to tackle all the challenges you might encounter during a manual installation of an NWP system. It is highly recommend that you use the most current release of this routine, as your life will become less complicated and more fulfilled if you do. And thats a statement only a few modeling systems can make! So, Where might I get this ems_install.pl utility thing, you ask? All NOAA-affiliated users of the EMS may simply request the current routine from the SOO Science and Training Coordinator (SOO STRC). All non-NOAA users, (i.e., everyone else), must register for the EMS on the SOO/STRC site:

    http://strc.comet.ucar.edu/software/newrems Registration allows the user to receive notification of updates as they become available, and also allows the developer to advance his world geography knowledge when a request from Mauritius is submitted. Note that there may be a delay in receiving the ems_install.pl utility following registration, as the submitted information is checked both for some semblance of legitimacy and to avoid advertisements for personal enhancement products from being sent to valid users. Once the EMS concierge is able to confirm your registration, which typically takes a few minutes, or as much as a week should the lone support person be out of the office or comatose, you will receive a second message with the

  • Chapter 02 -- Installation of the EMS

    A Nearly Complete Guide to the EMS V13 C h a p t e r | 2-2

    ems_install.pl routine attached. Enjoy!

    2.2 System Requirements For Installing The EMS There are a few system requirements for installing and running the EMS, which are listed below:

    A relatively current Linux distribution, but not too current The EMS has been tested on Red Hat Enterprise, Fedora, CentOS, SuSe, and Ubuntu distributions, although the use of Ubuntu has required some changes to the (dash/bash) interpreter in the past. Other distributions will probably work; however, its simply too difficult to keep up with all the releases and updates. There is usually a lag before the EMS developer can install a newly released distribution and run the tests. So just stick with what works and well both be happier for it.

    16 Gb of available disk space This requirement pertains to the installation of the EMS only. Of course, running an NWP model can use up a significant amount of disk space, so this requirement should be considered as an absolute minimum.

    The T|C shell must be installed on the system Linux purists may get all upset about this requirement, but thats just the way it is for now; however, it may change in the future. Note that in many current Linux releases, the default is not to install tcsh, so you may have to install it separately. The ems_install.pl routine will check whether it is installed and provide an error message if it isnt.

    The EMS user must be using a T|C shell If you are installing the EMS under a known user, then they must be running csh or tcsh; otherwise horrible things may happen, such as the EMS failing to run, and you dont want that to happen. There are ways around this requirement, but were not going there right now.

    Root permission and/or write permission on a large disc partition. The ems_install.pl routine was designed to be run as root user. You will have the opportunity to assign ownership to an existing or new user during the processes. That said, an existing user could install the EMS provided the user has write permission on the drive where the package will reside.

    2.3 Installing the EMS 2.3.1 The Basics - The Stuff You Should Know

    Whether or not you have an existing EMS release on your system, you can still do a fresh install with ems_install.pl. The novice ems_install.pl user should embrace the most basic of installation commands:

    % ems_install.pl --install [release version] Note that the release version is optional, as indicated by the [square brackets], since the default is the most current official release. If you are looking to install a beta release, say release 3.2.1.5.22.beta, then you must specify the release as an argument to --install. For example:

  • Chapter 02 -- Installation of the EMS

    A Nearly Complete Guide to the EMS V13 C h a p t e r | 2-3

    % ems_install.pl --install 3.2.1.5.22.beta

    The above example is for demonstration purposes only, since release 3.2.1.5.22.beta may not actually exist. So dont try it at home. There is additional information on determining the available releases in Section 2.5.

    2.3.2 What happens during the installation process? Regardless of what option you choose when installing the EMS, the process will include the following:

    A greeting, just because thats important and youre worth the effort Prompt you for the installation directory (Default: /usr1) Check to make sure the directory exists and whether you have write permission Determine whether an existing EMS installation resides at that location:

    o Get the version of an existing installation o Ask whether you want to rename the existing installation to wrfems.

    Prompt you for the name of the user to assign ownership of the package Create a new account and home directory if the user does not exist Check that the user's login shell is either tcsh or csh Prompt you for a password if a new user was created Finally install the EMS from the specified source Do the post-install configuration Congratulate you on another wise decision

    Note that all sorts of useful information will be printed to the screen while the installation is running, so don't leave the room. During the installation process, the ems_install.pl routine will also attempt to:

    Determine the appropriate run-time binaries based on the CPU type on your system. See Section 2.6 for more blather on target binaries.

    Attempt to determine the number of physical CPU and cores per CPU on your system. Should a problem occur, you will be prompted to give up this information, and you will be powerless to resist.

    Install an entry (disabled) in the user's crontab file to automate the process of updating the EMS. You will be able to configure the ems_install.pl utility to automatically download and install updates from the SOO/STRC EMS servers and notify user(s) of any changes. More on the updating capabilities utility later.

    Install an entry (again, disabled) in the user's crontab file to assist in the automation of real-time forecasting. All you need to do is make the appropriate changes to this entry and youre off!

    See, isn't that simple? The EMS practically installs itself.

  • Chapter 02 -- Installation of the EMS

    A Nearly Complete Guide to the EMS V13 C h a p t e r | 2-4

    Note that the downloading of EMS tarfiles from the SOO/STRC server may require a considerable amount of time, depending upon the speed of your connection. Be patient, as your effort will be well rewarded.

    2.3.3 Installing from DVD

    If you are lucky enough to possess one of the fabulous DVDs from the EMS collector series, then consider yourself blessed, because life doesnt get any better. Besides being a great coaster, the DVD can be used to install the EMS. This capability does come with a few caveats however, so dont get too excited. Ok, go ahead and jump up and down a little. In order to install the EMS from DVD, you will need to actually mount the DVD, which may require root privilege on your system. For the sake of this guidance it will be assumed that you have mounted the EMS DVD under /media/cdrom, although the exact location may differ on your machine. Since youre actually reading these instructions, its assumed you can figure out what to do.

    Step a. Load EMS DVD

    Step b. Change directories to DVD drive, e.g. cd /media/cdrom

    At this point you should see a copy of the install routine on the DVD. Use this release for the installation unless told otherwise by a bowl of fruit or a domesticated farm animal with fur, not feathers. You cant trust the feathered ones.

    Step c. Run the ems_install.pl routine like you want something good to happen:

    # ./ems_install.pl

    With any luck something good will happen and the installation process will begin. On some systems however, you may see an error such as:

    # /ems_install.pl bash: ./ems_install.pl: /usr/bin/perl: bad interpreter: Permission denied

    Or % ems_install.pl

    ems_install.pl: Permission denied.

    The above errors likely indicate that your DVD is mounted noexec, meaning you cant run an executable file from the DVD. Silly security restrictions. All is not lost, other than the time required to interpret the error message, because there is a work-around available:

    Step c1. Copy ems_install.pl from the DVD to another location such as /tmp.

    Step c2. Run ems_install.pl from that location with the following flags:

  • Chapter 02 -- Installation of the EMS

    A Nearly Complete Guide to the EMS V13 C h a p t e r | 2-5

    # ./ems_install.pl --dvd /media/cdrom (or wherever you mounted the DVD)

    That should solve your EMS installation-related problems for now.

    2.3.4 Installing From The Internet

    Unless you are installing the EMS directly from DVD (Section 2.3.3), the default behavior of the ems_install.pl routine is to attempt to download the necessary files from the EMS severs. There is no need to include any special arguments or flags as everything is built into ems_install.pl. Just follow the basic guidance provided in Section 2.3.1.

    2.3.5 A Local Network Installation

    If you dont have direct access to the EMS servers you can still install the EMS. This method requires that the tar files be manually downloaded from the server and placed in a directory where they are accessible. Simply follow these few steps:

    Step a. Create a temporary directory where the files are to be downloaded. This can be called anything, provided that you have at least 6Gb of space on that partition. For this example, the directory will be named /usr1/emsfiles.

    # mkdir /usr1/emsfiles

    Step b. Open up the EMS site in your browser for a list of full releases:

    http://soostrc.comet.ucar.edu/wrfems/releases

    and determine which release you want to install, which should be the most current one if you know whats good for you. The releases are identified by such silly names as 3.2.1.5.99.beta or 3.1.1.5.0, because the developer was born without an imagination.

    Step c. Create a second sub directory below /usr1/emsfiles with the name of the release

    to be downloaded. For example:

    # mkdir /usr1/emsfiles/3.1.1.5.0 Step d. Again open up the EMS site to the desired release

    http://soostrc.comet.ucar.edu/wrfems/releases/3.1.1.5.0

    and download all the tar files to your /usr1/emsfiles/3.1.1.5.0 directory. There may be quite a few, and some are rather large, so while you are waiting you can take up waterfall kayaking or some other worthwhile activity.

  • Chapter 02 -- Installation of the EMS

    A Nearly Complete Guide to the EMS V13 C h a p t e r | 2-6

    Step e. Once all the files are downloaded and your injuries have healed, run the ems_install.pl routine as follows (Replacing the example with the actual location of the downloaded files on your system):

    # ./ems_install.pl --install --repodir /usr1/emsfiles

    Step f. Congratulate yourself on another risky yet rewarding skill mastered the EMS

    installation, not the waterfall kayaking.

    2.3.6 Making Sure Your Installation Was A Success Following a successful and care-free installation, you should log out and return as the EMS user. Make sure your EMS environment is set correctly by attempting the following commands:

    % cd $EMS And you should be located at the top level of the EMS

    Then try:

    % ls $EMS_STRC

    There you will see the contents of the $EMS/strc directory. If both of the above tests are successful, then try running the "sysinfo" command provided with your EMS (and it IS yours now):

    % sysinfo You should see a summary of your system configuration that includes the Linux distribution and additional information, such as your blood pressure (just kidding). Please make sure that the following values are correct:

    Physical CPUs : # The number of CPUs or mice that you would see if you opened up

    the computer case Cores per CPU : # The number of cores on each physical CPU, the stuff you cant see Total Processors : # This value should be just Physical CPUs * Cores per CPU

    If either the number of Physical CPUs or the Cores per CPU is incorrect, you will have to change these values in the $EMS/etc/EMS.cshrc and $EMS/etc/EMS.profile files. If everything appears to be correct, then your installation is complete and you are ready to become a modeler. If not, just give your not-so-local SOO STRC a call, or send a message along with some baked goods.

    2.3.7 Potentially Useful Options When Installing The EMS

    There are many command-line flags and options that may be passed to the ems_install.pl routine, not all of which are listed here simply because Ive long forgotten what many of them do.

  • Chapter 02 -- Installation of the EMS

    A Nearly Complete Guide to the EMS V13 C h a p t e r | 2-7

    However, I can recall enough to impart upon you sufficient knowledge to meet most of your EMS installation desires. And thats really all you want out of life, isnt it? Below is a list of flags and options that are used during an EMS installation on your system. Note that there may be additional options listed in the other sections depending upon whether you are doing an installation or update. Be sure not to miss them, as the life you save may be your own. a. Option: --install [install release version]

    What this option can do for you: The --install option is one of the primary or must have flags passed to ems_install.pl. Passing --install without any other flags tells the installation routine that you want to do a fresh install of the EMS (described in Section 2.3). The default behavior is to install the most current EMS release available. This behavior can be overridden by including a release number as an argument to --install, in which case your requested release will be installed, provided that it exists. If you are doing a fresh install but have an existing EMS installation on the system, the previous installation will be renamed unless you pass the --scour flag, in which case it will be wiped off the face of your computer. If there are any computational domains residing in the existing wrfems/runs directory, they will automatically be transferred to the wrfems/runs directory of the new installation and updated unless you include the --noimport flag. If you have domains located somewhere else that you want imported to the new installation, then you will need to include the --import option. There are a couple of secondary options with which the --install flag must be included. Please see the --binonly and --tarfile options for more details.

    b. Option: --emsdir What this option can do for you: Include the --emsdir flag if you want to specify either the location of an existing EMS installation for updates or the future home of a fresh installation when passing the --install flag. For the most part passing this flag is unnecessary as the ems_install.pl routine will figure everything out. So, unless you have a good reason for using it, dont.

    c. Option: --repodir What this option can do for you: Use the --repodir flag when you want to override the default behavior of accessing the EMS tar files on the EMS servers and go hunt those buggers down locally (/). It may be used with the --update, --install or --list options. The directory location, , should be the path to the directory where the

  • Chapter 02 -- Installation of the EMS

    A Nearly Complete Guide to the EMS V13 C h a p t e r | 2-8

    individual release subdirectories are located. You do not include the release number in the pathname specified by . The install routine will figure that part out. For example, suppose on your local system you have a directory that contains EMS releases, lets call that directory /usr/local/ems/releases. Beneath the /usr/local/ems/releases directory you would have subdirectories containing the tarfiles for each release. The name of each release subdirectory should indicate the release number, such as:

    /usr/local/ems/releases/3.1.0.3.1 and

    /usr/local/ems/releases/3.1.1.3.56 and

    /usr/local/ems/releases/3.2.1.6.1 Then, when using the --repodir option, you would not include the release number, i.e.,

    % ems_update.pl --install --repodir /usr/local/ems/releases The magic contained within the install routine will figure out the rest.

    d. Option: --target or current or system What this option can do for you: Passing --target allows you to specify which precompiled EMS binaries you wish to install. Not passing the --target flag will result in the default behavior of having the installation routine select the target binaries for you. If this is a new installation, the target binary type will be set to whatever is compatible with the CPU on the installation computer (this corresponds to the system option). If you are updating your system then the target binary will be set to the flavor that you are currently running, provided that this information can be determined (this corresponds to the current option). Note that --target should be included when passing the --binonly option. The list of available specially-compiled CPU target options for each release is available when running ems_install.pl with the --list flag. Check it out. Additional information on target binaries and the target option is available in Section 2.6.

    e. Option: --import What this option can do for you: Pass the --import flag during a new installation if you wish to import existing domain directories from a previous EMS installation. You do not need to pass the --import flag if those directories reside in the wrfems/runs directory of a current installation as those are included by default. The --import flag is used if you have moved the directories to another location for safe keeping, which is why you need to include the

  • Chapter 02 -- Installation of the EMS

    A Nearly Complete Guide to the EMS V13 C h a p t e r | 2-9

    the domain directories> as an argument to --import, because otherwise, the almighty ems_install.pl will not have a clue as to what you want and this sentence will become even longer. In addition to importing, the requested domains configuration files will be updated and relocalized. If you have been living right, then all of your settings will be preserved. Beginning to sweat a bit now arent you?

    f. Option: --noimport What this option can do for you: When including the --noimport flag, you are telling the install routine not to import the domain directories from any existing wrfems/runs directory, which is the default behavior. Passing --noimport has no effect on the --import option, so go ahead and use them together, or not at all, with complete recklessness.

    g. Option: --noupdate What this option can do for you: Include the --noupdate flag if you do not want to update the computational domain directories that exist under wrfems/runs. If this is a fresh installation, then these directories would have been copied over from an existing installation; or, should this be an update, then only the directories hanging around under wrfems/runs will not be affected. This means that all your domains will not be touched following an update or installation and will have the same configuration files and localization as before. Of course they no longer work, but youll be happy in simply knowing that you have some control in your life. If you are doing a fresh install and included the --import flag, then the imported directories will retain the smell of the previous release. Should you have a change of heart then the updating and re-localization can be accomplished by entering a domain directory and running the following command:

    % ems_domain --update --localize

    h. Option: --package =[x64|x32] What this option can do for you: Passing --package allows the user to override the default system architecture, either 32- or 64-bit, when installing the binary packages included with the EMS. This option is not to be used for installing the primary WRF target binaries (See the --target option), but rather it is used for downloading and installing the packages in the wrfems/utils directory. The argument to --package is a string that will be matched to a tar file name (e.g. nawips),

  • Chapter 02 -- Installation of the EMS

    A Nearly Complete Guide to the EMS V13 C h a p t e r | 2-10

    followed by an optional =x64 or =x32 that will be used to select the 64- or 32-bit version of the package respectively. Should you not include either x64 or x32, then the install routine will use the information provided by the uname -m command on the installation system to determine whats best for your EMS. Here is an example: % ems_install.pl --install [other stuff] --package mpich=x32 The above example will specify the installation of the 32-bit mpich2 binaries on a users machine. If the machine is 64-bit and the default target binaries have not been overridden, then the 32-bit mpich2 package will be downloaded and installed. If the machine is already 32-bit, then the user is just wasting his or her time. Note that the matching string, mpich, and the requested architecture, x32, are separated by an equals sign (=). Yes, the = must be included or this will not be your lucky day. If the user wants to override the default tar file for multiple packages, then the --package flag may be passed multiple times: % ems_install.pl --install --package mpich=x32 --package grads=x32

    i. Option: --nounpack What this option can do for you: Include the --nounpack flag if you do not want to install the downloaded EMS files (the default is to install them), whether they are for a new installation, an update, a --binonly party, or a --tarfile slam-fest. Just let them sit in the wrfems/release|updates/ directory until theyve cooled off. This flag is not called --noinstall just because I thought that might be confusing; however, you can try --noinstall and see how far it gets you.

    j. Option: --nogeog What this option can do for you: When including the --nogeog flag, you are telling the install routine not to include the large WRF static GEOG files during installation. Remember that you actually need these data sets to run the model, but if you already have them locally, you may not need to download them again. You can just copy the files over to the new EMS installation. However, there are times when this data set changes and you may need the updated files. Remember, with the EMS, stuff just happens. Dont let it happen to you.

  • Chapter 02 -- Installation of the EMS

    A Nearly Complete Guide to the EMS V13 C h a p t e r | 2-11

    k. Option: --x32 and --x64

    What these options can do for you: Passing either the --x32 or --x64 flag will override the EMS-determined machine architecture, either 32- or 64-bit, and install the specified version of the EMS package binaries. Including either of these flags will not impact the choice of WRF target binaries, but rather, only impact the executables that will reside under the wrfems/utils directory.

    l. Option: --reldir What this option can do for you: Passing the --reldir flag will override the default location where the downloaded EMS update or release tar files will reside respectively. When updating or installing the EMS, the tar files are placed in the "/wrfems/release/" directory unless you pass the --reldir option. The default is best unless you have a good reason to change.

    m. Option: --nowkp What this option can do for you: Passing the --nowkp flag instructs the ems_install.pl routine not to include any of the classroom exercises that come with a new release or update. These files are fairly large and you dont use them anyway.

    n. Option: --curl and --wget What these options can do for you:

    Passing the --curl or --wget flag instructs the ems_install.pl routine to use that Linux utility for http communication. The default is to use whatever tool is available on your system, but you have the option to say otherwise should one method be failing you.

    o. Option: --host What this option can do for you: Including the --host option instructs the ems_install.pl routine to contact the specified host for information on EMS updates and installations. The default behavior is to randomly contact one of the EMS servers, but you can request a different server should there be any.

  • Chapter 02 -- Installation of the EMS

    A Nearly Complete Guide to the EMS V13 C h a p t e r | 2-12

    p. Option: --dvd What this option can do for you: You would use the --dvd option only if you were installing off a DVD (yes, DVDs are available) and had to copy the ems_install.pl routine from the DVD to another location because you could not mount the drive with executable permission. See Section 2.3.3 for guidance on DVD installation.

    q. Option: --debug What this option can do for you: Including the --debug flag will cause the ems_install.pl routine to print out more information about what is going on inside its brain while its attempting to figure out just what you want from it.

    2.4 Updating Your EMS With Passion

    You will eventually want to update your old, crusty, buggy, and yet well-loved EMS with a newer and shinier model containing fresh bugs and that new WRF smell. When that moment arrives, you can call upon your EMS installation tool (yeah, it's a tool now) to tackle the job. It will someday be known as the Swiss Army knives of EMS installation tools, but for now its just the leather awl of installation tools. As you may or may not recall, when you installed the EMS, an entry was placed in your crontab file that allows you to automatically download and install updates. If you fancy this auto-update option, then you must enable the crontab entry by removing the comment, #, from in front of the command line. If automation makes you nervous, then keep it disabled and just fly manually while following the guidance provided, you Luddite. 2.4.1 More Basics - The Stuff You Sorta Gotta Know

    Just as with the EMS installation processes, the great EMS unwashed should embrace the most basic of updating commands:

    % ems_install.pl --update [update release version] Note that the update release version is optional, as indicated by the [square brackets], as the default is the most current release. It is recommended that you not include the update release and allow the ems_install.pl tool to do its magic. If you have been a slacker and find yourself a few dozen updates behind, no problem, ems_install.pl will figure out what updates you need to bring your system up to date. With any (a lot of) luck, the tool will download and install each missing update until you are current and just as brilliant as the day you first installed the EMS. At least thats the plan.

  • Chapter 02 -- Installation of the EMS

    A Nearly Complete Guide to the EMS V13 C h a p t e r | 2-13

    2.4.2 Potentially Useful Updating Options

    Below is a list of flags and options that are used during an update of the EMS on your system. Note that there may be additional options listed in the other sections depending upon whether you are doing an installation or update. Be sure not to miss them, as the life you save may be your own. a. Option: --update [update release version]

    What this option can do for you: The --update option is one of the primary, or must have flags passed to ems_install.pl. Passing --update tells the installation routine that you want to update your EMS to the current release. The optional argument to --update is the release number to which you want your system updated. Including the release number overrides the default behavior of updating your EMS to the most current release available. If you do not include any other flags, then the EMS servers will be checked for updates. If any exist, the update tar files will be downloaded and installed. If you have any domains located in your wrfems/runs directory, then they will also be updated with new configuration files and localization. Your existing configuration settings will be retained (no, really!). At the risk of a complete failure, if you do not wish to update your domains, then include --noupdate" flag.

    b. Option: --emsdir What this option can do for you: Include the --emsdir flag if you want to specify the location of an existing EMS installation for updates. For the most part, passing this flag is unnecessary as the ems_install.pl routine will figure everything out. So unless you have a good reason for using it, dont.

    c. Option: --repodir What this option can do for you: Use the --repodir flag when you want to override the default behavior of accessing the EMS tar files on the EMS servers and go hunt those buggers down locally (/). It may be used with the --update, --install or --list options. The directory location, , should be the path to the directory where the individual release subdirectories are located. You do not include the release number in the pathname specified by . The install routine will figure that part out. For example, if on your local system you have a directory that contains EMS updates, lets call

  • Chapter 02 -- Installation of the EMS

    A Nearly Complete Guide to the EMS V13 C h a p t e r | 2-14

    that directory /usr/local/ems/updates, and beneath the /usr/local/ems/updates directory you have subdirectories containing the tarfiles for each update with the name of each update subdirectory indicating the update release number, such as:

    /usr/local/ems/updates/3.1.0.3.1 And

    /usr/local/ems/updates/3.1.1.3.56 And

    /usr/local/ems/updates/3.2.1.6.1 Then, when using the --repodir option, do not include the release number, i.e.

    % ems_update.pl --update --repodir /usr/local/ems/updates The magic contained within the install routine will figure out the rest.

    d. Option: --target or current or system What this option can do for you: Passing --target allows you to specify which precompiled EMS binaries you wish to install. Not passing the --target flag will result in the default behavior of having the installation routine select the target binaries for you. If this is a new installation the target binary type will be set to whatever is compatible with the CPU on the installation computer (same as the system option). If you are updating your system then the target binary will be set to the flavor that you are currently running, provided that this information can be determined (same as the current option). Note that --target should be included when passing the --binonly option. The list of available specially-compiled CPU target options for each release is available when running ems_install.pl with the --list flag. Check it out. Additional information on target binaries and the target option is available in Section 2.7.

    e. Option: --nounpack What this option can do for you: Include the --nounpack flag if you do not want to install the downloaded EMS files (the default is to install them), whether they be for a new installation, an update, a --binonly party, or a --tarfile slam-fest. Just let them sit in the wrfems/updates/ directory until theyve cooled off. This flag is not called --noinstall just because I thought that might be confusing; however, you can try --noinstall and see how far that gets you.

    f. Option: --noupdate What this option can do for you:

  • Chapter 02 -- Installation of the EMS

    A Nearly Complete Guide to the EMS V13 C h a p t e r | 2-15

    Include the --noupdate flag if you do not want to update the computational domain directories that exist under wrfems/runs. If this is a fresh installation, then these directories would have been copied over from an existing installation; or, if this is an update, then only the directories hanging around under wrfems/runs will not be affected. This means that all your domains will not be touched following an update or installation and will have the same configuration files and localization as before. Of course they no longer work, but youll be happy in simply knowing that you have some control in your life. If you are doing a fresh install and included the --import flag, then the imported directories will retain the smell of the previous release. Should you have a change of heart, then the updating and re-localization can be accomplished by entering a domain directory and running the following command:

    % ems_domain --update --localize

    g. Option: --package =[x64|x32] What this option can do for you: Passing the --package flag allows the user to override the default system architecture, either 32- or 64-bit, when installing the binary packages included with the EMS. This option is not to be used for installing the primary WRF target binaries (See the --target option), but rather it is used for downloading and installing the packages in the wrfems/utils directory. The argument to --package is a string that will be matched to a tar file name (E.g., nawips), followed by an optional =x64 or =x32 that will be used to select the 64- or 32-bit version of the package respectively. Should you not include either x64 or x32, then the install routine will use the information provided by the uname -m command on the installation system to determine whats best for your EMS. Here is an example: % ems_install.pl --update [other stuff] --package mpich=x32 The above example will specify the installation of the 32-bit mpich2 binaries on a users machine. If the machine is 64-bit and the default target binaries have not been overridden, then the 32-bit mpich2 package will be downloaded and installed. If the machine is already 32-bit, then the user is just wasting his or her time. Note that the matching string, mpich, and the requested architecture, x32, are separated by an equals sign (=). Yes, the = must be included or this will not be your lucky day. If the user wants to override the default tar file for multiple packages, then the --package flag may be passed multiple times: % ems_install.pl --update --package mpich=x32 --package grads=x32

  • Chapter 02 -- Installation of the EMS

    A Nearly Complete Guide to the EMS V13 C h a p t e r | 2-16

    h. Option: --nolocal

    What this option can do for you: Passing the --nolocal option overrides the default behavior of looking for existing EMS tar files in the wrfems/updates or wrfems/release directories. Should tar files exist, simply ignore them and download fresh files. The old ones were attracting fruit flies anyway.

    i. Option: --force What this option can do for you: Passing the --force flag will force the installation of an update even though it's already installed. Maybe you messed something up and can't figure out where you went so terribly wrong, or maybe you want get your frustration out. I know, Ive been there, which is why I included --force instead of a --smelltheroses option. Just because it feels better.

    j. Option: --allyes What this option can do for you: Passing the --allyes flag says to the ems_install.pl routine, Yes, yes, I love you and trust you completely. While I have never heard those words myself, here is your chance to say them without the need to verbalize. The only time you will need the --allyes flag is when doing automated updates, since without it the routine will hang while waiting for you to respond to some silly rhetorical question.

    k. Option: --x32 and --x64 What these options can do for you: Passing the --x32 or --x64 flag will override the EMS-determined machine architecture, either 32- or 64-bit, and install the specified version of the EMS package binaries. Including either of these flags will not impact the choice of WRF target binaries, but rather, only impact the executables that will reside under the wrfems/utils directory.

    l. Option: --updir What this option can do for you: Passing the --updir path/some directory> flag will override the default location where the downloaded EMS update or release tar files will reside. When updating or installing the EMS, the tar files are placed in the "/wrfems/updates/" directory unless you

  • Chapter 02 -- Installation of the EMS

    A Nearly Complete Guide to the EMS V13 C h a p t e r | 2-17

    pass the --updir option. The default is best unless you have a good reason to change.

    m. Option: --nowkp What this option can do for you: Passing the --nowkp flag instructs the ems_install.pl routine not to include any of the classroom exercises that come with a new release or update. These files are fairly large, and you dont use them anyway.

    n. Option: --curl and --wget What these options can do for you: Passing the --curl or --wget flag instructs the ems_install.pl routine to use that Linux utility for http communication. The default is to use whatever tool is available on your system but you have the option to say otherwise should one method be failing you.

    o. Option: --host What this option can do for you: Including the --host option instructs the ems_install.pl routine to contact the specified host for information on EMS updates and installations. The default behavior is to randomly contact one of the EMS servers, but you can request a different server should there be any.

    p. Option: --debug What this option can do for you: Including the --debug flag will cause the ems_install.pl routine to print out more information about what is going on inside its brain while its attempting to figure out just what you want from it.

    2.5 Some Basic Information That May Only Be Of Limited Use If you take anything away from this section, it should be that you can always pass the --help flag to any of the EMS utilities in hopes that it will provide some semblance of clarity. Whether it actually does help anything will depend upon the ability of the developer (that be me) to communicate an idea, and the user (that be you) to comprehend the information presented. So go ahead and feel free to give the --help option a test drive and behold the wonders of the EMS installation routine.

    % ems_install.pl --help

  • Chapter 02 -- Installation of the EMS

    A Nearly Complete Guide to the EMS V13 C h a p t e r | 2-18

    A couple of other semi-useful options are the --list and --listall flags. These flags are used to interrogate the EMS servers to find out the available releases and updates. In their simplest use:

    % ems_install.pl --list Or

    % ems_install.pl --listall When passed, the install utility will contact the EMS servers to get any information on the available release and update situation, and then spew it in a semi-comprehensible format to the screen. It will also provide you with some semi-valuable data on your system, as well as tell you whether your current EMS release is up to date. In addition, a list of the supported target binaries for each release is also provided. The difference between the --list and --listall options is that --listall will give you the EMS equivalent of the full Monty by printing out all the available tar files for each release, while the --list option retains a bit of humility. But only a bit. If you wish to interrogate a local source of EMS release and update tar files, then be sure to include the --repodir option, because otherwise, you would be connecting to the EMS data servers. Finally, there is the --version flag,

    % ems_install.pl --version This does nothing else besides display the version number of the ems_install.pl routine and then bail out on you. Simply for informational and support purposes only.

    2.6 Still More, But This Time, Potentially Valuable Options

    Below is a list of additional flags and options that are valid with ems_install.pl. Note that there may be additional valid options listed in the other sections. Be sure not to miss them, as the life you save may be your own. a. Option: --tarfile ,,,,,,

    What this option can do for you: Passing --tarfile allows you to install or reinstall selected tar files from an EMS server or local repository. This option will only work with existing EMS installations, and you can only install a tar file for a currently installed release simply because it would be silly to install a tar file from a different release. The argument to --tarfile is list of one or more tar files, including the [release.], separated by a comma and without spaces in between. The name of the file must match exactly. You can get a list of the available tar files by passing the --listall flag.

  • Chapter 02 -- Installation of the EMS

    A Nearly Complete Guide to the EMS V13 C h a p t e r | 2-19

    Here is another fine example of the ems_install.pl power: % ems_install.pl --install --tarfile release.3.2.1.5.2.beta.utils.ncview.tbz The --install flag must be included. Just because I said so, thats why. The above example will install the ncview package tarfile for the EMS release 3.2.1.5.2.beta, assuming that is the same as the currently installed release. The ems_install.pl utility will also do any necessary configuration, just because it appreciates your patronage.

    b. Option: --binonly

    What this option can do for you: Use the --binonly flag along with the --install flag to download/install an EMS WRF target binary tarfile. The target binaries are just those executables that reside in the wrfems/bin directory and compiled for specific CPU architecture (see Section 2.7). If you are unhappy with your system crashing due to illegal instruction errors, you have the option of replacing those poorly compiled WRF binaries with ones that are reasonably well-tailored for your system. To find out which target binaries are available for your release, use the --list or --listall flag:

    % ems_install.pl --list [--repodir ] And look for the list beneath the Supported XXXX release target binaries line. At that point you can either choose one of the supported target binaries or let the EMS select the binary set what is most appropriate for your system. Its very similar to selecting a wine by yourself or having a sommelier do the job for you. Really. Then, when you are through window shopping, request and install the target binary set of your dreams by:

    % ems_install.pl --install --binonly --target

    2.7 Target binaries and you As stated previously, the EMS installation routine will attempt to determine which binaries are best for your system. It accomplishes this feat by checking the architecture of your machine, either x64 or i386, and then uses the wrfems/util/bin/cpuid routine to determine the level of CPU on your system based upon the supported instruction sets. The EMS takes this information and determines the best fit from the various precompiled binary sets. While there are many target CPUs for which EMS binaries can be created, an attempt has been made to keep the number of possible options down while not sacrificing performance. This was done to save the developers sanity, which is probably long gone anyway. Amazingly, the routine that determines the CPU level of your system is not perfect and sometimes

  • Chapter 02 -- Installation of the EMS

    A Nearly Complete Guide to the EMS V13 C h a p t e r | 2-20

    makes mistakes. Ya, I know its hard to believe but its true. A common indication that the installed binaries are not appropriate for your system is the appearance of the dreaded Illegal instruction error when running the EMS. Should this error ever appear, you can install one of the other binary sets by using the --binonly flag and --target flags with ems_install.pl. If you dont know which target binaries are supported for your release then just use the --list flag:

    % ems_install.pl --list [--repodir ] And look for the list beneath the Supported XXXX release target binaries line. At that point you can either choose one of the supported target binaries or let the EMS select the binary set what is most appropriate for your system. You can then use the --binonly flag to install the desired binaries, For example:

    % ems_install.pl --install --binonly --target penryn If youve made a terrible mistake and installed a target binary set that does not run on your system, you can always install the EMS-preferred binaries:

    % ems_install.pl --install --binonly --target system Be sure to include the --repodir if you dont want to approach the EMS servers. The above command forces the installation of the 32-bit Penryn binaries on your machine rather than the ones it thinks you should have. Thats shown the EMS install tool whos boss! Failing to include the desired target binary will defer the selection to the EMS wizard.