|

Ubuntu 64, SAS 9.2 & What I Do All Day

The next time your boss asks what you do all day or why it takes you so long to answer a question, show him or her this …

Now, unlike this blog. where I basically drink Chardonnay and say whatever the hell I feel like, when people are paying me for answers, I take my work pretty seriously. Years ago, on the very cool resource, SAS-L there was a (thankfully, short) trend where people would post answers with the note “Code not tested”, which is a polite way of saying, “I don’t know if this will work.”

When anyone asks me a question, unless it is something like “Do you end SAS statements with a period or a semi-colon?”, I test my answer before I send it. For one thing, with changes in versions, different operating systems and other variations, something that may work in one situation may not work in another.

So… the very simple question asked was:
“How do I renew SAS for Linux 64?”

First problem: I do not have SAS installed on a 64-bit Linux system to renew, so, I decide to install it on this Ubuntu VM I happen to have , and it doesn’t work at all. Well, I had ASSUMED that since it is a VM running on a 64-bit Mac that also has a 64-bit Windows 7 VM and a 64-bit Vista VM that it must be a 64-bit Ubuntu VM.

The first time the install failed I thought, gee, maybe I should check. Well, I had created this VM about a year ago to test some things on the 32-bit version of Ubuntu for someone so …

Delete VM I no longer need.

Go here:

http://www.ubuntu.com/desktop/get-ubuntu/download

Download the 64-bit iso.

Curious that it says not recommended for daily desktop usage. Read several posts speculating on why it said that but nothing to convince me it was a big problem.

http://ubuntuforums.org/showthread.php?p=9370540

Downloaded and installed anyway.

Second problem: COULD NOT GET PAST LOGIN SCREEN! Ubuntu would not take my password. It was as if it did not recognize the keyboard. Turns out this is a known problem with VMware/Mac/Ubuntu combination.

Must be relatively new because I did not have it before.

Searching Google, source of all knowledge, I found the answer on the source of all knowledge on Ubuntu, the Ubuntu forums

http://ubuntuforums.org/showthread.php?t=1467905

I’ve had the keyboard problem with Ubuntu 10.04 in VMware Fusion 3.0.2 on a MacBook, US keyboard layout. I got around the problem as follows:

  • At the logon screen, go to the Accessibility Preferences at the bottom of the screen, and tick on screen keyboard.
  • You may have to reboot if the virtual keyboard doesn’t start.
  • You can now type in your password using the virtual keyboard on the logon screen. Once logged in, your physical keyboard works.

To fix the problem with your keyboard

  • *Open a terminal, and reconfigure your console using the command:

sudo dpkg-reconfigure console-setup

Once logged in, I went to

cd /media

cd to the external hard drive where all my SAS deployment folders are (we have MANY versions of SAS for many different operating systems)

Then did

cp -R sas92Linux64 ~/sasinst

This copied all the files and directories in the deployment folder to the ~/sasinst folder on my hard drive

I changed to bash

sudo rm /bin/sh
sudo ln -s /bin/bash /bin/sh

I then went to the folder where I had copied the deployment files, typed

sudo ./setup.sh

Third problem: The deployment wizard started …. and then stopped

Nothing>

Now, at this point I have created a new VM, gotten around the keyboard problem, copied over the files and still nothing

I then found this FABULOUS web page from the National Center for Ecological Analysis and Synthesis

http://help.nceas.ucsb.edu/Install_SAS_on_Ubuntu

VERY IMPORTANT ADVICE …

install required packages:

sudo apt-get install xauth x11-apps libstdc++5 ia32-libs libxp6

Then, of course, comes the question, where do you find libstdc++5

Here is one place

http://packages.debian.org/stable/base/libstdc++5

So…. I download libstdc++5 , run the command above to get everything I need installed.

THEN …

I go back and typed

sudo bash setup.sh

Everything installed.

Getting SAS to work

First, create a directory to act as your working directory. I called mine tmp
I went to usr/local and typed

mkdir tmp

Give everyone access to write to the tmp directory

sudo chmod 777 /usr/tmp

To get SAS to start the first time I had to type

/usr/local/SAS/SASFoundation/9.2/sas - work /usr/local/tmp

———– One more thing —-

Since I always like to tie up the loose ends, I took one final bit of advice from the wonderful NCEAS site and typed the following :

sudo ln -s /usr/local/SAS/SASFoundation/9.2/sas /usr/bin/sas

Now when I start SAS all I need to do is type

sas -work /tmp

I like that better.

Fourth problem: I get an error message telling me that there is a mismatch between my license and the version of SAS I have installed. I talk to a few people at SAS and get several other things I need, like an electronic software download for the latest version of SAS for Linux 64, the SID file to renew Linux 64 for a different site, and I have a long conversation with someone who tells me that what I have installed is Linux 32. Since the current (expired) SID file says Linux 64 and when I run a PROC SETINIT it says Linux 64, and the original ESD from a year ago says Linux 64, I tell her that while it is theoretically possible that it is, in fact, Linux 32 which was mislabeled in four different ways, I kind of doubt it. She finally gives in to my superior logic, tracks down the SID file for this version and emails it to me.

Once you do actually have the correct SID file …

Here is the answer I actually sent on how to renew SAS on Ubuntu (Remember, that was the original question)

================

1. Open up a terminal window (under applications > accessories)
2. cd to where you have your sas software installed
cd /usr/local/SAS/SASFoundation/9.2

3. Start the renewal utility by typing
sudo ./sassetup

4. Hit enter to continue
5. Type 1 for Run Setup Utilities
6. Type 1 for Renew SAS Software
7. You’ll be prompted for the file containing the SAS installation data file. If you downloaded it from an email sent to you by your SAS Administrator, it will probably be something like

/home/ademars/Downloads/SAS92_Linux64.txt

(by the way, when I tried ~/Downloads/SAS92_Linux64.txt it didn’t work )

The Setup Utilities Menu will pop up again.
Type q

You have now renewed.

Similar Posts

7 Comments

  1. It depends on your situation. At some universities, there is a license for an unlimited number of installs so you can get SAS for free or a small fee.

    I worked on one campus where they had SAS of tons of Windows machines and they just sort of tacked Linux on to their license.

    Depending on where you work/ attend school it may be available anywhere from free to $150 a year.

    I worked at another institution where the Linux license cost way more because they factored in the extra technical support to help you get it installed – see above. If you just wanted to get a copy and be on your own, you could get it at a third of the cost. No one picked that option, which struck me as pretty odd.

  2. Thanks. Nice blog entry and useful.

    Why SAS can’t have something like that, I have no idea. SAS documentation is like Microsoft Support – volumes of verbiage that while not necessarily incorrect, does nothing to help you solve your problem.

    This helped more than 22 pages of official SAS docs.

  3. “I test my answer before I send it”

    Sorry, can’t resist…

    “First, create a directory to act as your working directory. I called mine tmp
    I went to usr/local and typed

    mkdir tmp

    Give everyone access to write to the tmp directory

    sudo chmod 777 /usr/tmp”

    your chmod is missing a ‘local/’, no?

    Still enjoyed the read though. Thanks 🙂

  4. Hi, Annmaria, your instruction is wonderful. I know it is probably too late to ask you questions but I do have two problems after installing SAS 9.3 on Ubuntu 12.04 using your methods. First, the double-left-click stops working. For example, to go to another library, I need to left-click, then right-click, then choose “Open” from the drop-down menu. The second problem is that I am not able to select/highlight the codes that I want to submit in the program editor. It is either all or nothing. Can you have another solution? Many thanks.

Leave a Reply

Your email address will not be published. Required fields are marked *