opsi-client-agent install confusion

Antworten
blwallace
Beiträge: 6
Registriert: 28 Mär 2013, 17:43

opsi-client-agent install confusion

Beitrag von blwallace »

I'm new to opsi and am in evaluation page. I'm able to get a pxe boot, unattended Windows7 install using an unattend.xml file. I'd like to have my Windows7 install have the opsi-client-agent. I'm confused on how the opsi-client-agent gets installed.

Section 9.2.7 of the manual opsi version 4.0.3 says:
Installation of OS and opsi-client-agent
One feature of the unattended installation is the possibility to initiate additional installations after the main installation is finished. This mechanism is used to install the opsi-client-agent, which implements the automatized software distribution system. An entry in the registry marks the machine as being still in the reinstallation-mode

Section 7.3.1 of the manual opsi version 4.0.3 says:
Installation
In case of automatic OS-Installation with opsi (not image based), the opsi-client-agent will be installed automatically. You may set the action request uninstall to uninstall the opsi-client-agent. For a subsequent installation on an existing Windows system or for repair purposes see the getting started manual. Section 7.7.

Since I'm doing a pxe, unattended installation does this mean section 7.3.1 applies? If so, this is not happening for me and I don't know how to fix it. If section 9.2.7 is correct, I can work through that part of the unattended process. I just want to know.

Thanks,

Bart
Benutzeravatar
d.oertel
uib-Team
Beiträge: 3327
Registriert: 04 Jun 2008, 14:27

Re: opsi-client-agent install confusion

Beitrag von d.oertel »

Hi,

did you changed the unattend.xml file that comes with opsi ?
If yes, there is a good chance that the integration of the opsi-client-installation in the unattended windows installation is killed by a change of the unattend.xml. Switch back to the original opsi unattend.xml and test if the opsi-client-agent is installed now. If everything works, you may add changes to the unattend.xml step by step.

does this help ?

regards
d.oertel


Vielen Dank für die Nutzung von opsi. Im Forum ist unser Support begrenzt.

Für den professionellen Einsatz und individuelle Beratung empfehlen wir einen Support-Vertrag und eine Schulung.
Gerne informieren wir Sie zu unserem Angebot.

uib GmbH
Telefon: +49 6131 27561 0
E-Mail: sales@uib.de


blwallace
Beiträge: 6
Registriert: 28 Mär 2013, 17:43

Re: opsi-client-agent install confusion

Beitrag von blwallace »

Yes, it does. Thank you. I believe the automatic term in section 7.3.1 is unclear, or perhaps not properly explainded. There is a process through the unattend file to which the client is installed. This automatically happens with proper modification of the included template file. I'll run your suggestion tomorrow.
blwallace
Beiträge: 6
Registriert: 28 Mär 2013, 17:43

Re: opsi-client-agent install confusion

Beitrag von blwallace »

Ok, the template unattend.xml file is working. I've modified it to use English language, but that is as far as I can get. My attempts to create a modified partition table seems to negate the opsi-client-agent install. I'm hoping you can point me to documentation on how to properly modify the unattend.xml file. I see variables used by (I think this is true) the setup.py script, but I don't know how to modify them. I originally used my unattend.xml file generated from Windows System Image Manager, but that didn't get the client installed, which prompted my posting here. I'm hoping you can point me to the proper manual on how to modify the unattend.xml file or how to use on that is generated using WSIM.
blwallace
Beiträge: 6
Registriert: 28 Mär 2013, 17:43

Re: opsi-client-agent install confusion

Beitrag von blwallace »

Here's how I understand the unattended Windows 7 install process to work:
  • The Getting Started Manual walks through creating a customized WinPE environment
    The customization of the WinPE includes the startnet.cmd line
    Once the ISO directory is copied to the OPSI server, PXE can boot the workstation with the customized WinPE
    WinPE runs hardware scan to determine (among many things) the number of drives on the system
    Setup.py script runs during netboot, reads the ../custom/unattend.xml and creates an unattend.txt file on the fly using variables
    The variables used in the unattend.txt file are determined by the configuration of the OS Netboot Product in opsi-configed
    These variables are such things as
    • WinPE partition size
      Windows boot partition
      Product key
      etc.
    Within the unattend.txt file is the command cmd.exe /c #@winpe_partition_letter*#:\opsi\postinst.cmd
    #@winpe_partition_letter*# is a variable defined in Netboot Product in opsi-configed
    postinst.cmd installs the opsi-client-agent
Is this correct?

My original attempt at using a WISM generated unattend.xml file works, but does not run the opsi-client-agent install. Now that I understand better the relationship between unattend.xml, setup.py and postinst.cmd I'm hoping to get this to work. My WISM unattend.xml file has partition information that setup.py does not use due to the missing variable calls in the xml file.
My DiskConfiguration is:
<DiskConfiguration>
<Disk wcm:action="add">
<CreatePartitions>
<CreatePartition wcm:action="add">
<Order>1</Order>
<Size>300</Size>
<Type>Primary</Type>
</CreatePartition>
<CreatePartition wcm:action="add">
<Order>2</Order>
<Type>Primary</Type>
<Extend>true</Extend>
</CreatePartition>
</CreatePartitions>
<ModifyPartitions>
<ModifyPartition wcm:action="add">
<Active>true</Active>
<Format>NTFS</Format>
<Label>System</Label>
<Order>1</Order>
<PartitionID>1</PartitionID>
</ModifyPartition>
<ModifyPartition wcm:action="add">
<Format>NTFS</Format>
<Label>Windows</Label>
<PartitionID>2</PartitionID>
<Order>2</Order>
</ModifyPartition>
</ModifyPartitions>
<DiskID>0</DiskID>
<WillWipeDisk>true</WillWipeDisk>
</Disk>
<WillShowUI>OnError</WillShowUI>
</DiskConfiguration>

and not as in the template file
<DiskConfiguration>
<WillShowUI>OnError</WillShowUI>
<Disk wcm:action="add">
<DiskID>0</DiskID>
<WillWipeDisk>false</WillWipeDisk>
<!--
<CreatePartitions>
<CreatePartition wcm:action="add">
<Order>1</Order>
<Type>Primary</Type>
<Size>20000</Size>
</CreatePartition>
</CreatePartitions>
-->
<ModifyPartitions>
#@modify_partitions*#
</ModifyPartitions>
</Disk>
</DiskConfiguration>

Looking at setup.py, I see the variable winpePartitionLetter = "X".
The template unattend.xml file has in the FirstLogonCommands:
<FirstLogonCommands>
<SynchronousCommand wcm:action="add">
<Description>Opsi tasks</Description>
<Order>1</Order>
<CommandLine>cmd.exe /c #@winpe_partition_letter*#:\opsi\postinst.cmd</CommandLine>
</SynchronousCommand>
</FirstLogonCommands>

I'm going to try my WISM unattend.xml file with the following:
<FirstLogonCommands>
<SynchronousCommand wcm:action="add">
<Description>Opsi tasks</Description>
<Order>1</Order>
<CommandLine>cmd.exe /c X:\opsi\postinst.cmd</CommandLine>
</SynchronousCommand>
</FirstLogonCommands>
and see if it will work and post my results.
Benutzeravatar
d.oertel
uib-Team
Beiträge: 3327
Registriert: 04 Jun 2008, 14:27

Re: opsi-client-agent install confusion

Beitrag von d.oertel »

Hi,

you are nearly right:
you boot via PXE the linux bootimage. Inside of this bootimage we run the setup.py.
The setup.py does the Hardware inventory (in order to find the needed drivers), collect all information that is specific for the client and use this information to patch the unattend.xml. This patched unattend.xml is copied to gether with the winpe and the collected drivers to the disk. After reboot the winpe is started which starts the windows setup with the patched unattend.xml.

see also:
http://download.uib.de/opsi_stable/doc/ ... unattended

regards
d.oertel


Vielen Dank für die Nutzung von opsi. Im Forum ist unser Support begrenzt.

Für den professionellen Einsatz und individuelle Beratung empfehlen wir einen Support-Vertrag und eine Schulung.
Gerne informieren wir Sie zu unserem Angebot.

uib GmbH
Telefon: +49 6131 27561 0
E-Mail: sales@uib.de


blwallace
Beiträge: 6
Registriert: 28 Mär 2013, 17:43

Re: opsi-client-agent install confusion

Beitrag von blwallace »

I tried my modified unattend.xml using the line:
<CommandLine>cmd.exe /c X:\opsi\postinst.cmd</CommandLine>
to no avail.

I'm still confused on how the opsi-client-agent gets installed. I thought is was through the postinst.cmd but I'm unable to get this to run (see above). I've stopped the startnet.cmd file and looked at the WinPE image. I see my unattend.xml file as well as a 50_opsi-client-agent.cmd file in c:\opsi\postinst.d and other important files. But I also see variables in these files that I can't track down.

I'm curious to know if using a unattend.xml file generated from WISM can work in this way. My end goal is to be able to use WISM to create a very unique unattend.xml file to use with OPSI and a PXE boot process. However, I seem to be limited to creating unattend.xml parameters within opsi-configed.

The manual you linked is still unclear to me how the client is installed. Again, I thought is was through the unattend.xml file <FirstLogonCommands> section. The only command in that section is to run postinst.cmd, but from where? I don't understand the location of #@winpe_partition_letter*#.
Benutzeravatar
d.oertel
uib-Team
Beiträge: 3327
Registriert: 04 Jun 2008, 14:27

Re: opsi-client-agent install confusion

Beitrag von d.oertel »

Hi,

patterns like '#@winpe_partition_letter*#' are placeholders that are replaced by the running bootimage.
The Microsoft GUI tools to create a unattend.xml are well known to create broken unattend.xml.

So again the hint: start with the opsi unattend.xml and add your changes step by step.

regards
d.oertel


Vielen Dank für die Nutzung von opsi. Im Forum ist unser Support begrenzt.

Für den professionellen Einsatz und individuelle Beratung empfehlen wir einen Support-Vertrag und eine Schulung.
Gerne informieren wir Sie zu unserem Angebot.

uib GmbH
Telefon: +49 6131 27561 0
E-Mail: sales@uib.de


PeterZ
Beiträge: 18
Registriert: 06 Jun 2013, 15:19

Re: opsi-client-agent install confusion

Beitrag von PeterZ »

blwallace hat geschrieben: I'd like to have my Windows7 install have the opsi-client-agent. I'm confused on how the opsi-client-agent gets installed.
Hi Bart,

have you fixed the client-manager issue?

Peter
Benutzeravatar
wolfbardo
uib-Team
Beiträge: 1412
Registriert: 01 Jul 2008, 12:10

Re: opsi-client-agent install confusion

Beitrag von wolfbardo »

d.oertel hat geschrieben:Hi,

So again the hint: start with the opsi unattend.xml and add your changes step by step.
regards,

Bardo Wolf


Vielen Dank für die Nutzung von opsi. Im Forum ist unser Support begrenzt.

Für den professionellen Einsatz und individuelle Beratung empfehlen wir einen Support-Vertrag und eine Schulung.
Gerne informieren wir Sie zu unserem Angebot.

uib GmbH
Telefon: +49 6131 27561 0
E-Mail: sales@uib.de


Antworten