[SOLVED] Opsi Client Agent Silent Installation

Marco Tizzano
Beiträge: 7
Registriert: 13 Jan 2017, 08:57

[SOLVED] Opsi Client Agent Silent Installation

Beitrag von Marco Tizzano »

Hi all,

We are testing OPSI solution in our lab environment in order to understand all the features of this very useful solution. My question is if is possible to install the Opsi Client Agent in silent mode with no user interaction. All installation parameters could be provided in automatic mode.
Our goal is to install the Opsi Client Agent on remote Client over internet Connection, user could only click on the Opsi Client installation package and it install itself

Hope someone can respond my question.
Thanks in advance
Marco
Zuletzt geändert von Marco Tizzano am 19 Jan 2017, 14:17, insgesamt 1-mal geändert.
Benutzeravatar
ngbr
Ex-uib-Team
Beiträge: 130
Registriert: 27 Sep 2010, 11:41

Re: Opsi Client Agent Silent Installation

Beitrag von ngbr »

Hi Marco Tizzano,

you need to edit the cfg file

Code: Alles auswählen

/var/lib/opsi/depot/opsi-client-agent/files/opsi/cfg/config.ini  
settings are fairly obvious ..

Edit: if you want to hide the password, you could put the string encoded by 'base64' into the 'hidden' option instead of using the plain text.
---
hoping to help :)

if your problem was solved, pls mark this thread as 'SOLVED'. thank you .

-- no PN support --

Andre
Marco Tizzano
Beiträge: 7
Registriert: 13 Jan 2017, 08:57

Re: Opsi Client Agent Silent Installation

Beitrag von Marco Tizzano »

Hi ngbr,

thanks for your reply, I'm a beginner about software distribution and Opsi solution. Could you specify which parameters I need to define in config.ini configuration file?

Thanks
Marco
Benutzeravatar
ngbr
Ex-uib-Team
Beiträge: 130
Registriert: 27 Sep 2010, 11:41

Re: Opsi Client Agent Silent Installation

Beitrag von ngbr »

Hi Marco Tizzano,

you're welcome. the default shold look like this :

Code: Alles auswählen

[installation]
service_user=adminuser
service_password=none
service_hidden_password=
I found the section in our doc which talks about it. in http://download.uib.de/opsi4.0/doc/html ... anual.html search for 'base64' pls. you'll get to know how to handle this section.

finally, pay attention to how silent_setup.cmd handles the /noreboot switch: it doesn't (yet). best is to call

Code: Alles auswählen

service_setup.cmd /u /noreboot 
(unless you want to reboot) .
---
hoping to help :)

if your problem was solved, pls mark this thread as 'SOLVED'. thank you .

-- no PN support --

Andre
Marco Tizzano
Beiträge: 7
Registriert: 13 Jan 2017, 08:57

Re: Opsi Client Agent Silent Installation

Beitrag von Marco Tizzano »

In config.ini file I have configured the following parameters:
service_user
service_hidden_password

At the moment /noreboot is not configured, at the moment is not a problem if, by default, silent installation automatic reboot the client.
So I'm trying to install the Agent executing silent_setup.cmd but when I execute the command nothing happen.
What could be the problem?

regards
Marco
Benutzeravatar
ngbr
Ex-uib-Team
Beiträge: 130
Registriert: 27 Sep 2010, 11:41

Re: Opsi Client Agent Silent Installation

Beitrag von ngbr »

Hi Marco,

just to make sure:

> you are an admin user on a windows machine
> you connected \\opsiserver\opsi_depot to a drive letter (assuming: Z:\)
> you cd into the Z:\opsi-client-agent directory
> you call service_setup.cmd

you should see a warning asking you to press any key to start .

another way would be to deploy via CLI from the server itself. this would be done from within this very same directory.
search the opsi-manual for 'opsi-deploy-client-agent' pls.
---
hoping to help :)

if your problem was solved, pls mark this thread as 'SOLVED'. thank you .

-- no PN support --

Andre
Marco Tizzano
Beiträge: 7
Registriert: 13 Jan 2017, 08:57

Re: Opsi Client Agent Silent Installation

Beitrag von Marco Tizzano »

Hi ngbr,

All requirements you listed are ok, silent_setup.cmd runs only if, previously its execution, opsi.org folder is already deleted. In this case the unattended installation works fine, otherwise if I don't delete the folder the silent_setup.cmd not run.

This is an expected behavior?

thanks
Marco
uncle_scrooge
Beiträge: 650
Registriert: 21 Feb 2012, 12:03
Wohnort: Mainz

Re: Opsi Client Agent Silent Installation

Beitrag von uncle_scrooge »

>>This is an expected behavior?
No.

As you can see, the script checks for the existence of c:\opsi.org\tmp and skips the creation if found:
:startwork
if exist c:\opsi.org\tmp goto :startwinst
mkdir c:\opsi.org\tmp
mkdir c:\opsi.org\log
:startwinst

So, please remove the first line (@echo off) from the script.
Start it again with c:\opsi.org in place and post the output.

Thanks.
Marco Tizzano
Beiträge: 7
Registriert: 13 Jan 2017, 08:57

Re: Opsi Client Agent Silent Installation

Beitrag von Marco Tizzano »

Hi and thanks for your quick response.

Follows the output of the script as required:

Code: Alles auswählen

C:\Users\user01\Desktop\opsi-client-agent>set script_drive=o:

C:\Users\user01\Desktop\opsi-client-agent>if not C: == \\ (
set script_drive=C:
 goto :mapped
)

C:\Users\user01\Desktop\opsi-client-agent>if ! == /u! goto startwork

C:\Users\user01\Desktop\opsi-client-agent>if ! == /u! goto startwork

C:\Users\user01\Desktop\opsi-client-agent>echo .
.

C:\Users\user01\Desktop\opsi-client-agent>echo   Aktueller PC: WIN-HSK4HJ70KB
K
  Aktueller PC: WIN-HSK4HJ70KBK

C:\Users\user01\Desktop\opsi-client-agent>echo   You are at PC: WIN-HSK4HJ70K
BK
  You are at PC: WIN-HSK4HJ70KBK

C:\Users\user01\Desktop\opsi-client-agent>echo .
.

C:\Users\user01\Desktop\opsi-client-agent>echo   !!!!!!!!!!!!!!!!!!!!!!!!!!!!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
  !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

C:\Users\user01\Desktop\opsi-client-agent>echo   !!
                                          !!
  !!                                                                    !!

C:\Users\user01\Desktop\opsi-client-agent>echo   !!           Zum Starten der
 opsi-client-agent Installation           !!
  !!           Zum Starten der opsi-client-agent Installation           !!

C:\Users\user01\Desktop\opsi-client-agent>echo   !!             druecken Sie
bitte eine beliebige Taste                !!
  !!             druecken Sie bitte eine beliebige Taste                !!

C:\Users\user01\Desktop\opsi-client-agent>echo   !!        Zum Abbrechen schl
iessen Sie einfach dieses Fenster         !!
  !!        Zum Abbrechen schliessen Sie einfach dieses Fenster         !!

C:\Users\user01\Desktop\opsi-client-agent>echo   !!
                                          !!
  !!                                                                    !!

C:\Users\user01\Desktop\opsi-client-agent>echo   !!          To start the ins
tallation of the opsi-client-agent        !!
  !!          To start the installation of the opsi-client-agent        !!

C:\Users\user01\Desktop\opsi-client-agent>echo   !!                        ju
st press any key                          !!
  !!                        just press any key                          !!

C:\Users\user01\Desktop\opsi-client-agent>echo   !!                 To cancel
 just close this window                   !!
  !!                 To cancel just close this window                   !!

C:\Users\user01\Desktop\opsi-client-agent>echo   !!
                                          !!
  !!                                                                    !!

C:\Users\user01\Desktop\opsi-client-agent>echo   !!!!!!!!!!!!!!!!!!!!!!!!!!!!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
  !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

C:\Users\user01\Desktop\opsi-client-agent>echo .
.

C:\Users\user01\Desktop\opsi-client-agent>pause
Press any key to continue . . .
Thanks
Marco
uncle_scrooge
Beiträge: 650
Registriert: 21 Feb 2012, 12:03
Wohnort: Mainz

Re: Opsi Client Agent Silent Installation

Beitrag von uncle_scrooge »

?
>>Press any key to continue . . .
What happens if you press a key?

If you want to omit the 'Press any key' call the script this way: service_setup.cmd /u

Thanks.
Antworten