Jump to content

Steve.mccall

Member
  • Posts

    38
  • Joined

  • Last visited

  • Donations

    0.00 USD 
  • Country

    United Kingdom

Posts posted by Steve.mccall

  1. Hi,

    I'm back!

    I'm having a few problems getting RIS to work with different drivers. Here is my current .sif file that works fine with one hardware configuration...

    ;SetupMgrTag
    [Data]
    AutoPartition=1
    MsDosInitiated="1"
    UnattendedInstall="Yes"
    floppyless="1"
    OriSrc = "\\%SERVERNAME%\RemInst\%INSTALLPATH%\%MACHINETYPE%"
    OriTyp="4"
    LocalSourceOnCD=1

    [SetupData]
    OsLoadOptions="/noguiboot /fastdetect"
    SetupSourceDevice = "\Device\LanmanRedirector\%SERVERNAME%\RemInst\%INSTALLPATH%"

    [Unattended]
    UnattendMode=FullUnattended
    OemSkipEula=Yes
    OemPreinstall=yes
    TargetPath=\WINDOWS
    FileSystem=LeaveAlone
    NtUpgrade=No
    OverwriteOemFilesOnUpgrade=No
    OemPnPDriversPath="Drivers\000_chipset\IntelINF;Drivers\001_network\Marvell;Drivers\002_graphics\Intel;Drivers\003_audio;Drivers\004_SATA"
    DriverSigningPolicy=Ignore
    ExtendOEMPartition = 0
    InstallFilesPath = "\\%SERVERNAME%\RemInst\%INSTALLPATH%\%MACHINETYPE%"
    LegacyNIC = 1

    [GuiUnattended]
    AdminPassword="bogbrain"
    EncryptedAdminPassword=NO
    DefaultDomainName="claimtec"
    AutoAdminLogon=1
    AutoLogon=Yes
    AutoLogonCount=3
    OEMSkipRegional=1
    TimeZone=%TIMEZONE%
    OemSkipWelcome=1

    [UserData]
    ProductKey=xx
    FullName="Steve McCall"
    OrgName="xx"
    ComputerName=%MACHINENAME%

    [Display]
    BitsPerPel=32
    Xresolution=1024
    YResolution=768
    Vrefresh=60

    [RegionalSettings]
    LanguageGroup=1
    SystemLocale=00000809
    UserLocale=00000809
    InputLocale=0809:00000809

    [SetupMgr]
    DistFolder=C:\windist
    DistShare=windist

    [GuiRunOnce]
    Command0=%systemdrive%\install\Commands\%BUILDTYPE%.cmd
    command1=%systemdrive%\install\Commands\shutdown.cmd


    [Networking]
    InstallDefaultComponents=No
    ProcessPageSections=Yes

    [NetAdapters]
    Adapter1=params.Adapter1

    [params.Adapter1]
    INFID=*

    [NetClients]
    MS_MSClient=params.MS_MSClient

    [NetServices]
    MS_SERVER=params.MS_SERVER

    [NetProtocols]
    MS_TCPIP=params.MS_TCPIP

    [params.MS_TCPIP]
    DNS=No
    UseDomainNameDevolution=No
    EnableLMHosts=Yes
    AdapterSections=params.MS_TCPIP.Adapter1

    [params.MS_TCPIP.Adapter1]
    SpecificTo=Adapter1
    DHCP=Yes
    DNSServerSearchOrder=xx
    WINS=No
    NetBIOSOptions=0

    [Identification]
    DomainAdmin = xx
    DomainAdminPassword = xx
    JoinDomain=CLAIMTEC
    DoOldStyleDomainJoin=Yes

    [RemoteInstall]
    Repartition=Yes
    UseWholeDisk = Yes

    [OSChooser]
    Description="Windows XP SP2"
    Help="Installs Windows XP SP2 Setup for GA81945"
    LaunchFile="%INSTALLPATH%\%MACHINETYPE%\templates\startrom.com"
    ImageType=Flat

    This works fine as I have the correct drivers in the relevent folders, but when I try to modify the script so it will check in another folder for the drivers...

    OemPnPDriversPath="Drivers\000_chipset\PE1;Drivers\001_network\PE1;Drivers\002_graphics\PE1;Drivers\003_audio\PE1;Drivers\004_SATA\PE1"

    I get stuck at the 'Setup is Inspecting your computers hadware config' screen.

    I assume that setup can't find my NIC drivers, or possibly SATA.

    Steve

  2. Hi,

    I need to write a script that will allow me to add a user as an administrator to a computer the first time they ever try to log on to it.

    All the computers are part of a small network that uses AD to administrate it.

    Basically I need the logon script to...

    Read the Username and Password input by the user.

    Check to see if the user is in the AD

    Add the user to the Computer within the Administrator group

    I'm not really sure how to go about this though and I think there will be credential problems as the new user will not have authority to change it's group to the administrator group.

    Steve

  3. Well what is happening is that the commands to install the applications are called from within the GuiRunOnce section of the .sif file.

    They in turn add the application reg keys to the registry.

    The applications are then installed via GuiRunOnce when the computer first logs on.

    The problem seems to be that windows can't recognise when an installation has finished and starts the next one in the series too early.

    Steve

  4. Told you I'd be back!

    I'm having a few problems with my next installation type. It involves much moving around of directories and applying of patches. Here is my current script...

    Ensign.cmd

    cmdow @ /HID
    @echo off

    SET KEY=HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnceEx

    REG ADD %KEY% /V TITLE /D "Installing Ensign Applications" /f

    REG ADD %KEY%\005 /VE /D "Installing ODBC" /f
    REG ADD %KEY%\005 /V 1 /D "regedit.exe /s %systemdrive%\install\odbc.reg" /f

    REG ADD %KEY%\010 /VE /D "Faxclient 12" /f
    REG ADD %KEY%\010 /V 1 /D "%systemdrive%\install\faxclient.msi /QN" /f

    REG ADD %KEY%\015 /VE /D "Adobe Reader 7" /f
    REG ADD %KEY%\015 /V 1 /D "%systemdrive%\install\Adobe\ar.msi /QN" /f

    REG ADD %KEY%\020 /VE /D "Office 2003 std." /f
    REG ADD %KEY%\020 /V 1 /D "\\serverris\Office2003\STD11.MSI /QB" /f

    REG ADD %KEY%\025 /VE /D "Clearing .db File Association" /f
    REG ADD %KEY%\025 /V 1 /D "regedit.exe /s %systemdrive%\install\removeDB.reg" /f

    REG ADD %KEY%\030 /VE /D "Mapping Progress Install Drives" /f
    REG ADD %KEY%\030 /V 1 /D "%systemdrive%\install\MapProgress.cmd" /f

    REG ADD %KEY%\035 /VE /D "Installing Progress 91D" /f
    REG ADD %KEY%\035 /V 1 /D "r:\setup.exe -s -f1q:\setup.iss" /f

    REG ADD %KEY%\040 /VE /D "Installing Progress Service pack 5" /f
    REG ADD %KEY%\040 /V 1 /D "t:\setup.exe -s -f1s:\setup.iss" /f

    REG ADD %KEY%\045 /VE /D "Installing Ensign Live" /f
    REG ADD %KEY%\045 /V 1 /D "%systemdrive%\install\EnsignVBS\CopyLive.vbs" /f

    REG ADD %KEY%\050 /VE /D "Copying Directories" /f
    REG ADD %KEY%\050 /V 1 /D "%systemdrive%\install\EnsignVBS\Copy2folders.vbs" /f

    REG ADD %KEY%\055 /VE /D "Configuring Progress for Ensign" /f
    REG ADD %KEY%\055 /V 1 /D "%systemdrive%\install\EnsignVBS\Copy1-3.vbs" /f

    REG ADD %KEY%\055 /VE /D "Copying Files" /f
    REG ADD %KEY%\055 /V 1 /D "%systemdrive%\install\EnsignVBS\Copy4Files.vbs" /f

    REG ADD %KEY%\060 /VE /D "Cleaning Up and Rebooting" /f
    REG ADD %KEY%\060 /V 1 /D "%systemdrive%\install\Commands\cleanup.cmd" /f



    EXIT

    There are no problems at all until the mapping drives key is added. From there each command doesn't wait long enough for the previous install or directory move to happen. I'm not really sure the way around this problem. Possibly setting a restart after every command, but I don't think the restart will wait for the install to finish.

    Steve

  5. Oh what fun this is!

    I've managed to edit my .sif file so the admin logs on fine and executes the script. The problem now is that the script doesn't take effect until the next reboot. So if I could issue a reboot command as soon as the pc logs on and increase the number of auto logons to 2, then it should all work!

    test.sif

    ;SetupMgrTag
    [Data]
    AutoPartition=1
    MsDosInitiated="1"
    UnattendedInstall="Yes"
    floppyless="1"
    OriSrc = "\\%SERVERNAME%\RemInst\%INSTALLPATH%\%MACHINETYPE%"
    OriTyp="4"
    LocalSourceOnCD=1

    [SetupData]
    OsLoadOptions="/noguiboot /fastdetect"
    SetupSourceDevice = "\Device\LanmanRedirector\%SERVERNAME%\RemInst\%INSTALLPATH%"

    [Unattended]
    UnattendMode=FullUnattended
    OemSkipEula=Yes
    OemPreinstall=yes
    TargetPath=\WINDOWS
    FileSystem=LeaveAlone
    NtUpgrade=No
    OverwriteOemFilesOnUpgrade=No
    OemPnPDriversPath="Drivers\000_chipset\IntelINF;Drivers\001_network\Marvell;Drivers\002_graphics\Intel;Drivers\003_audio;Drivers\004_SATA"
    DriverSigningPolicy=Ignore
    ExtendOEMPartition = 0
    InstallFilesPath = "\\%SERVERNAME%\RemInst\%INSTALLPATH%\%MACHINETYPE%"
    LegacyNIC = 1

    [GuiUnattended]
    AdminPassword="xxxx"
    EncryptedAdminPassword=NO
    AutoLogon=Yes
    AutoLogonCount=1
    OEMSkipRegional=1
    TimeZone=%TIMEZONE%
    OemSkipWelcome=1

    [UserData]
    ProductKey=xxxx
    FullName="Steve McCall"
    OrgName="xxxx"
    ComputerName=%MACHINENAME%

    [Display]
    BitsPerPel=32
    Xresolution=1024
    YResolution=768
    Vrefresh=60

    [RegionalSettings]
    LanguageGroup=1
    SystemLocale=00000809
    UserLocale=00000809
    InputLocale=0809:00000809

    [SetupMgr]
    DistFolder=C:\windist
    DistShare=windist

    [GuiRunOnce]
    Command0=%systemdrive%\install\%BUILDTYPE%.cmd

    [Identification]
    JoinDomain=%MACHINEDOMAIN%
    DoOldStyleDomainJoin=Yes

    [Networking]
    InstallDefaultComponents=Yes
    ProcessPageSections=Yes

    [RemoteInstall]
    Repartition=Yes
    UseWholeDisk = Yes

    [OSChooser]
    Description="NEW TEST"
    Help="NEW TEST"
    LaunchFile="%INSTALLPATH%\%MACHINETYPE%\templates\startrom.com"
    ImageType=Flat

    Could I enter command1= reboot or something?

    Steve

  6. Well, I just tried putting the login details in runonceex.cmd and running it from cmdlines.txt but the result was even worse!!! This time it gets stuck at the welcome screen, asking me to setup the internet connection etc.

    It then logs me in automatically to windows but nothing happens. I have to restart before the application installatino script runs.

    Is there anyway I can write a command within cmdlines.txt that uses the %BUILDTYPE% variable and would activate the correct installation script at the t-12 mark.

    Steve

  7. Ok,

    So when everything was working, cmdline.txt looked like this...

    [COMMANDS]
    "RunOnceEx.cmd"

    Which then ran RunOnceEx.cmd

    cmdow @ /HID
    @echo off

    SET KEY=HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnceEx
    SET KEY2="HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon"

    REG ADD %KEY2% /V DefaultPassword /D "bogbrain" /f
    REG ADD %KEY2% /V DefaultUsername /D "Administrator" /f
    REG ADD %KEY2% /V DefaultDomainName /D "Claimtec" /f
    REG ADD %KEY2% /V AutoLogonCount /t REG_DWORD /d 1 /f
    REG ADD %KEY2% /V AutoAdminLogon /D "1" /f
    REG ADD %KEY2% /V ForceAutoLogon /D "1" /f


    REG ADD %KEY% /V TITLE /D "Installing Applications" /f


    REG ADD %KEY%\010 /VE /D "Faxclient 12" /f
    REG ADD %KEY%\010 /V 1 /D "%systemdrive%\install\faxclient.msi /QN" /f

    REG ADD %KEY%\015 /VE /D "Adobe Reader 7" /f
    REG ADD %KEY%\015 /V 1 /D "%systemdrive%\install\Adobe\ar.msi /QN" /f

    REG ADD %KEY%\020 /VE /D "Claimtec ULR 8.1.1" /f
    REG ADD %KEY%\020 /V 1 /D "%systemdrive%\install\ClaimTec8.1.1.msi /QN" /f

    REG ADD %KEY%\025 /VE /D "Office 2003 std." /f
    REG ADD %KEY%\025 /V 1 /D "\\serverris\Office2003\STD11.MSI /QB" /f

    REG ADD %KEY%\030 /VE /D "Cleaning Up and Rebooting" /f
    REG ADD %KEY%\030 /V 1 /D "%systemdrive%\install\cleanup.cmd" /f



    EXIT

    Which worked fine.

    Now should I put the contents of Login.cmd directly into cmdlines.txt without any changes or should I leave cmdlines.txt to link to RunOnceEx.cmd and put the contents of Login.cmd into RunOnceEx.cmd?

    Am I able to have commands in both RunOnce (within the .sif file) and RunOnceEx?

    Am I right in thinking that if I use cmdlines.txt to run RunOnceEx that the login details will be entered early enough for them to work and RunOnce (within .sif file) will run once the computer logs on?

    Steve

  8. Well basically the two scripts do not run automatically. I need to manually log on before they are executed. The first time I log on, the script (e.g. claims.cmd) runs and adds the keys into the registry. The pc then restarts and DOES autologin this time, the apps are then installed.

    The problem seems to be the order in which everything happens.

    When I had one RunOnceEx.cmd file run by cmdlines.txt (which I believe is run at T-12) everything was installed fine.

    I think the problem is that the keys might be added to the registry too late in the installation for them to be used in the first post-install boot.

    I'm sorry, I know that doesn't really explain it very well.

    Steve

  9. Ok,

    Almost perfect! So close! At the moment the gui section of the install completes. The computer restarts and doesn't autologin. Once I manually logon as administrator the relevant cmd file for the build type runs and the computer restarts. Then the computer logs on automatically (although not as a domain admin, just a local admin) and everything installs fine. All the code I use is shown below...

    .sif template

    [data]
    AutoPartition=1
    floppyless = "1"
    msdosinitiated = "1"
    OriSrc = "\\%SERVERNAME%\RemInst\%INSTALLPATH%\%MACHINETYPE%"
    OriTyp = "4"
    LocalSourceOnCD = 1

    [SetupData]
    OsLoadOptions = "/noguiboot /fastdetect"
    SetupSourceDevice = "\Device\LanmanRedirector\%SERVERNAME%\RemInst\%INSTALLPATH%"

    [Unattended]
    UnattendMode=FullUnattended
    OemSkipEula = yes
    OemPreinstall = yes
    OemSkipWelcome = 1
    TargetPath = \WINDOWS
    FileSystem = LeaveAlone
    NtUpgrade=No
    OverwriteOemFilesOnUpgrade=No
    OemPnPDriversPath="Drivers\000_chipset\IntelINF;Drivers\001_network\Marvell;Drivers\002_graphics\Intel;Drivers\003_audio;Drivers\004_SATA"
    DriverSigningPolicy=Ignore


    ExtendOEMPartition = 0


    InstallFilesPath = "\\%SERVERNAME%\RemInst\%INSTALLPATH%\%MACHINETYPE%"
    LegacyNIC = 1

    [UserData]
    ProductKey=xxxx
    FullName = "xxxx"
    OrgName = "%ORGNAME%"
    ComputerName = %MACHINENAME%

    [GuiUnattended]
    AdminPassword=xxxx
    EncryptedAdminPassword=no
    AutoAdminLogon=yes
    AutoAdminLogon=1
    ForceAutoLogon=1
    OemSkipRegional = 1
    TimeZone = %TIMEZONE%
    OemSkipWelcome = 1

    [GuiRunOnce]
    %systemdrive%\install\Login.cmd
    %systemdrive%\install\%BUILDTYPE%.cmd

    [Display]
    BitsPerPel = 32
    XResolution = 1024
    YResolution = 768
    VRefresh = 60

    [RegionalSettings]
    LanguageGroup=1
    SystemLocale=00000809
    UserLocale=00000809
    InputLocale=0809:00000809

    [SetupMgr]
    DistFolder=C:\windist
    DistShare=windist

    [Networking]
    InstallDefaultComponents=Yes
    ProcessPageSections=No

    [Identification]
    DomainAdmin = xxxx
    DomainAdminPassword = xxxx
    JoinDomain = xxxx
    DoOldStyleDomainJoin = Yes

    [RemoteInstall]
    Repartition = Yes
    UseWholeDisk = Yes


    [OSChooser]
    Description = "Gigabyte - GA-81945GMF v5 RunOnceEx.cmd"
    Help = "This will install Windows XP Pro SP2 Pro in a standard configuration. Installs LAN, Chipset, SATA and GFX drivers. Includes GuiRunOnce Office Std"
    LaunchFile = "%INSTALLPATH%\%MACHINETYPE%\templates\startrom.com"
    ImageType = "Flat"

    Login.cmd

    cmdow @ /HID
    @echo off

    SET KEY2="HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon"

    REG ADD %KEY2% /V DefaultPassword /D "xxxx" /f
    REG ADD %KEY2% /V DefaultUsername /D "xxxx" /f
    REG ADD %KEY2% /V AutoLogonCount /t REG_DWORD /d 1 /f
    REG ADD %KEY2% /V AutoAdminLogon /D "1" /f
    REG ADD %KEY2% /V ForceAutoLogon /D "1" /f

    shutdown.exe -r -f -t 10 -c "Windows XP will now restart in 10 seconds..."

    EXIT

    Claimtec.cmd

    cmdow @ /HID
    @echo off

    SET KEY=HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnceEx

    REG ADD %KEY% /V TITLE /D "Installing Claimtec Applications" /f


    REG ADD %KEY%\010 /VE /D "Faxclient 12" /f
    REG ADD %KEY%\010 /V 1 /D "%systemdrive%\install\faxclient.msi /QN" /f

    REG ADD %KEY%\015 /VE /D "Adobe Reader 7" /f
    REG ADD %KEY%\015 /V 1 /D "%systemdrive%\install\Adobe\ar.msi /QN" /f

    REG ADD %KEY%\020 /VE /D "Claimtec ULR 8.1.1" /f
    REG ADD %KEY%\020 /V 1 /D "%systemdrive%\install\ClaimTec.msi /QN" /f

    REG ADD %KEY%\025 /VE /D "Office 2003 std." /f
    REG ADD %KEY%\025 /V 1 /D "\\xxxx\Office2003\STD11.MSI /QB" /f

    REG ADD %KEY%\030 /VE /D "Cleaning Up and Rebooting" /f
    REG ADD %KEY%\030 /V 1 /D "%systemdrive%\install\cleanup.cmd" /f



    EXIT

    Originally login.cmd and claimtec.cmd were one file but I tried splitting them to get it to work. Would it work better if somehow coded the login script directly into the .sif template?

    Steve

  10. Well personally I agree. From my limited experience It does seem that using the AD's deployment procedure would be a lot easier considering most of the software that has to be installed uses .msi. I have implemented a few registry key changes using AD. Unfortunately my boss has explicitly stated for me not to use this function as he has had lots of problems with software rollbacks in the past. I'm not about to argue with someone who constructed the network, so it has to be this way.

    I've decided to use a RunOnceEx.cmd and it works fine at the moment. But what I'd now like to know is it possible to use the same image and install different software. Below is the code I have so far...

    cmdow @ /HID
    @echo off

    SET KEY=HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnceEx

    REG ADD %KEY% /V TITLE /D "Installing Applications" /f

    REG ADD %KEY%\010 /VE /D "Faxclient 12" /f
    REG ADD %KEY%\010 /V 1 /D "%systemdrive%\install\faxclient.msi /QN" /f

    REG ADD %KEY%\015 /VE /D "Adobe Reader 7" /f
    REG ADD %KEY%\015 /V 1 /D "%systemdrive%\install\Adobe\ar.msi /QN" /f

    REG ADD %KEY%\020 /VE /D "xxxx ULR 8.1.1" /f
    REG ADD %KEY%\020 /V 1 /D "\\xxxx\xxxx\Deployment\ULR Release Builds\ULR XP 8.1.1\ClaimTec 8.1.1.msi /QN" /f

    REG ADD %KEY%\025 /VE /D "Office 2003 std." /f
    REG ADD %KEY%\025 /V 1 /D "\\xxxx\Office2003\STD11.MSI /QB" /f

    REG ADD %KEY%\030 /VE /D "Cleaning Up and Rebooting" /f
    REG ADD %KEY%\030 /V 1 /D "%systemdrive%\install\cleanup.cmd" /f

    Some of the software (Faxclient, Adobe) needs to be on every machine but there will be different versions of office and other software for other builds of machine. Is there a way I can select between different RunOnceEx files based on which build I am creating. Would it be possible to create a variable entered during the initial setup screen that can be select a different runonceex.cmd. Or is there a much easier way of doing it?

    Thanks

    Steve

    EXIT

  11. Hi, I'd like to be able to automatically add a used to a computer as an administrator at their first login after checking the user is a member of the active directory. I'm not really sure about how to go about it. I'm assuming I'll have to write a script that will identify the user in the AD then add it to the local machine

    Any help would really be appreciated.

    Thanks

    Steve

  12. All of this sort of begs the question as to why group policy, SMS, or something else isn't being utilized for deployment of .msi based installs.

    Well speaking from my point of view, our company does not as yet have much redundancy (although it's changing) and is currently changing quite a lot. My boss wants me to experiement with the different solutions to deployment as well as MS Update management (to name but a few things.) I think he likes the idea of a script for each type of machine. I am using GPO to change the general settings of the computers however (odbc, firewall RD etc)

    Steve

  13. I'm not entirely sure what the command line options are for Adobe Reader's exe file. But if you run it manually you can snag the resulting .msi file (and the accompanting data files). Then you would just use standard msiexec commands: msiexec /i adobereader.msi /qn

    If you don't mind taking the easy way out, you could always download one of several switchless silent installers for Adobe Reader. I maintain one as well as RyanVM and I'm sure a few others.

    Great, that will work I think.

    Thanks

    Steve

  14. OK,

    I've tried this

    Option Explicit

    Dim WshShell, Command

    Set WshShell = WScript.CreateObject("WScript.Shell")

    Command = "%systemdrive%\install\AdbeRdr70_enu_full.exe /param1 /param2"

    WshShell.Run Command, 0, True

    Command = "%systemdrive%\install\faxclient.msi /param1 /param2"

    WshShell.Run Command, 0, True

    It starts to install adobe but still wants me to press next etc (i.e. not silent) and then gets stuck before installing the faxclient and doesn't get any further. And I still can't get it to auto logon.

    Steve

  15. If you're a systems admin you seriously owe it to yourself to get even just mildly aquainted with VBscript and Windows Script Host. It's really not all that difficult to pick up, there are tons and tons of free resources out there to learn from, and in the end it will make your life much easier. Once you have the basics down it can really become downright addictive having the ability to automate so many things.

    If you ever need some examples of VBscript that would be applicable to unattended installations, take a peek at my ScriptPack (link in the signature).

    Yeah, I am starting to learn it. I've only just started my first job as a lowly tech support / developer so I'm at the bottom of the ladder. I've got a good grasp of php, html, java etc so it shouldn't be too difficult to learn.

    Steve

×
×
  • Create New...