As the first step in the decommissioning of sasCommunity.org the site has been converted to read-only mode.


Here are some tips for How to share your SAS knowledge with your professional network.


Quiet Install

From sasCommunity
Jump to: navigation, search

Steps

  1. Read the SAS Deployment Wizard Users Guide, Chapter 4
  2. locate your deployment folder
  3. familiarize yourself with a manual installation: setup.exe
  4. record a response file
  5. copy the response file:
    1. setup-W32d-response-file-testing.txt
    2. setup-W32d-response-file.txt
  6. test install with the SMALL testing response file
  7. test install with production response file

Notes: as of 2011-Jun-08 I have not been able to get the silent-install to complete the Systems Requirements Wizard (SRW). Reason: SRW initiates a reboot, when installing using setup.exe, setup.exe remembers passwords and can restart. When running from a batch file the batch file terminates during the reboot.

Solution: run setup.exe past the SRW, stop, then run the quiet install.

quiet-install-recording.bat

This is one line.

<UNC>\SAS\v9.2.3\Win-32-desk\setup.exe -loglevel 1 -record -responsefile "C:\temp\sas-setup\setup-W32d-record.txt"

quiet-install-TESTING.bat

<UNC>\SAS\v9.2.3\Win-32-desk\setup.exe -loglevel 1 -provision -quiet -wait -responsefile "<UNC>\SAS\v9.2.3\Win-32-desk\setup-W32d-response-file-testing.txt"

setup-W32d-response-file-testing.txt

NOTES:

  • provided as an example for viewing
  • This file has been reduced!
  • DO NOT COPY THIS FILE! IT IS INCOMPLETE!
  • pound sign (#) is used for comments
  • does not work: SAS_HOME=C:\Program Files\SAS-quiet-test
  • reducing these options to minimum cuts install testing from one hour to 15 minutes; ymmv
    • PRODUCT_SELECTION
    • SASFOUNDATION_SELECTION
    • LANGUAGE_SELECTION


# Response file for the SAS Deployment Wizard
# Created: May 3, 2011 9:57:24 AM
#
# Responses with multiple options are separated with / characters.

# Select Deployment Task
# Select the deployment task you would like to perform.
#START_TASK=install/depot/manage
 START_TASK=install

# Specify SAS Home
# Specify the location where SAS software will be installed on this machine.
#SAS_HOME=<full path>
 SAS_HOME=C:\Program Files\SAS-quiet-test
# SAS_HOME=C:\Program Files\SAS

# Select Deployment Type
# Select the type of deployment you want to perform.
#DEPLOYMENT_TYPE=planned/nonplanned/additional
 DEPLOYMENT_TYPE=nonplanned
#PLANNED_INSTALL=yes/no
 PLANNED_INSTALL=yes
#PLANNED_CONFIGURE=yes/no
 PLANNED_CONFIGURE=no

# Select Products to Install
# Select the products you want to install on this machine.
 PRODUCT_SELECTION1=sasinstall

# Select SAS Foundation Products
# Further customize the software by selecting the SAS Foundation products to install.
#SASFOUNDATION_SELECTION=<comma delimited SAS Foundation (MVA) product codes>
 SASFOUNDATION_SELECTION=base

# Select Language Support
# Select the languages for your software to support.
#LANGUAGE_SELECTION=<comma delimited language codes>
 LANGUAGE_SELECTION=en
# LANGUAGE_SELECTION=07,en,1d,u8


quiet-install.bat

Notes:

  • <UNC> means your folder containing SAS depot with setup.exe
  • copy *.lnk refers to SAS-v9-2.lnk and SAS-OnLine-Doc.lnk
  • did you catch that we renamed the previous installation?
    • why? because we want a new installation, not just an update.
rem <UNC>\SAS\v9.2.3\Win-32-desk\setup-W32d-quiet-install.bat
echo on
echo quiet install of SAS v9.2.3 on Windows 32 workstation for
set  UserName
echo *************************************
echo NOTICE: must be run with admin rights
echo NOTICE: must have run setup.exe past Systems Requirements Wizard
echo ****************************************************************
echo task list:
echo * make backups of !sasroot:
echo * * autoexec.sas
echo * * SASv9.cfg
echo * install SAS v9.2.3  ESTIMATED time: one hour
echo * rename SASv9.cfg
echo * copy CDC standard SASv9.cfg to !sasroot
echo * end task list
set qi_SASroot=C:\Program Files\SAS\SASFoundation\9.2
set qi_save=C:\temp\sas-save-quiet-install
md %qi_save%
set qi_home=<UNC>\SAS\v9.2.3\Win-32-desk
set qi_
rem pause

if exist "%qi_SASroot%\autoexec.sas" xcopy "%qi_SASroot%\autoexec.sas" %qi_save%\autoexec-user.sas  /Q /V /Y
if exist "%qi_SASroot%\SASV9.CFG"    xcopy "%qi_SASroot%\SASV9.CFG"    %qi_save%\SASV9-user.CFG  /Q /V /Y
if exist "%qi_SASroot%" rename "%qi_SASroot%" "%qi_SASroot%-previous"
rem testing
rem <UNC>\SAS\v9.2.3\Win-32-desk\setup.exe -loglevel 1 -provision -quiet -wait -responsefile "<UNC>\SAS\v9.2.3\Win-32-desk\setup-W32d-response-file-testing.txt"
REM PRODUCTION
rem
call      %qi_home%\setup.exe -loglevel 1 -provision -quiet -wait -responsefile %qi_home%\setup-W32d-response-file.txt
rename   "%qi_SASroot%\SASV9.CFG" SASV9-installed.CFG
xcopy     %qi_home%\SASv9.cfg        "%qi_SASroot%\"  /Q /V /Y
xcopy     %qi_home%\proc-setinit.*   "%qi_SASroot%\"  /Q /V /Y
xcopy    "%qi_home%\*.lnk" "%C:\Documents and Settings\%username%\Desktop\"  /Q /V /Y

echo copies of user autoexec.sas or SASv9.cfg are in this folder:
dir %qi_save%\*.*

pause
echo starting SAS
"%qi_SASroot%\SAS.exe"

SAS-v9.2.lnk

NOTE: SAS installation provides a link file that has -CONFIG pointing to the primary config file: !sasroot\nls\en\SASv9.cfg

If you are wondering why your desktop link == shortcut does not use your customized configuration file, i.e.: !sasroot\SASV9.CFG this is the reason.

Target:
"C:\Program Files\SAS\SASFoundation\9.2\sas.exe" -CONFIG "C:\Program Files\SAS\SASFoundation\9.2\SASV9.CFG"


SAS-OnLine-Doc.lnk

Target:
"C:\Program Files\SAS\SASFoundation\9.2\core\help\common.chm"


SASv9.cfg

This is the what is installed.

-CONFIG "C:\Program Files\SAS\SASFoundation\9.2\nls\en\SASV9.CFG" /* */


Notes:

  • this file is copied from SAS depot to user sasroot
  • line 1 must call the Primary Configuration == sasroot\nls\en\SASv9.cfg
  • turn off trivia
  • allocate name of temp folder
  • reset
    • environment variable MySASfiles
    • options SASuser and Work
  • reason for reset: avoid problems with laptops not working when disconnected from network
/*name: <UNC>\SAS\v9.2.3\Win-32-desk\SASv9.cfg
RJF2 2011-06-01 for CDC quiet install **/
-CONFIG "C:\Program Files\SAS\SASFoundation\9.2\nls\en\SASV9.CFG" /* */
-noovp       /* no OverPrint in log of Errors and Warnings */
-nosplash    /* no SAS Splash while initializing */
-nostatuswin /* no Windows status pop-ups */

/* reset SAS defaults of environment variables and options
         to avoid problems with 'My Documents' on laptops*/
-SET UserTemp 'C:\temp\SAS-files-v9.2'
/*   MYSASFILES system variable*/
-SET MYSASFILES "!UserTemp\My-Files"
/* SAS System user profile folder */
-SASUSER        "!UserTemp\SASuser"
/* SAS System user work folder    */
-WORK           "!UserTemp\work-temp-files"

proc-setinit.sas

Every good admin needs a program to send to the user to check their expiration date.

* name:
\\cdc\project\intra_stat\SAS\v9.2.3-2011\Win-32-desk\proc-setinit.sas;
* mailto:SASsiteRep@MyCompany.com;
options linesize = max
        pagesize = max
        nosource;

%Put note: Site     =&SysSite.;
%Put note: Host     =&SysHostName.;
%Put note: UserId   =&SysUserId.;
%Put note: SysScpL  =&SysScpL.;
%Put note: SysVlong =&SysVlong.;
%Put note: CSIDL_PERSONAL==My Documents;
%Put note: MySASfiles %sysfunc(sysget(MySASfiles));
%Put note: SASuser %sysfunc(getoption(SASuser));
%Put note: Work %sysfunc(getoption(Work));
%Put note: for Sudaan:;
%Put note: HelpRegister=%sysfunc(getoption(HelpRegister));
%Put note: Path %sysfunc(compbl(%sysfunc(getoption(Path))));

options source;

proc setinit;
run;


References

--macro maven == the radical programmer 14:02, 9 June 2011 (UTC)