Post-install snapin failed
-
Hi,
we run two batch scripts after deployment of windows OS.
First one works great, just a copy of a file to EFI partition:@ECHO ON mountvol s: /s s: cd EFI/grub2win copy c:\grub\linux\grub.cfg s:\EFI\grub2win mountvol s: /d
second one is always with error (sometimes I see it with exit code -1 sometimes with 1)
We use bcdedit to import a store with list of bootloaders. When I run it locally like an Admin it works great.
The quesiton is how to run this snapin with Admin privilege? I think this is the problem.@ECHO ON bcdedit /import C:\Grub\Linux\file_bcd
the imported file is saved in the image in C:\Grub\Linux\file_bcd
-
@marted The fog-client software runs as SYSTEM account. Probably best to try manually using Sysinternal PsExec:
C:\Windows\system32>whoami ...\Administrator C:\Windows\system32>PsExec.exe -S cmd.exe ... C:\Windows\system32>whoami NT AUTHORITY\SYSTEM C:\Windows\system32>bcdedit ... ...
-
@Sebastian-Roth how to specify which snapin run first and which second. What I did I put on the second one I want to be executed, a timeout of 60 sec. Is there a different way to say which script run first and which second?
-
@marted Just from the top if my head, I think snapins are executed in order by names. So name the one you want to run first
01_snapinname
and the one later02_snapinname
. -
@Sebastian-Roth, I still have some problems with executing a batch command like admin in a script.
When I execute locally the command it works very well but in snapin it doesn’t work. Even we tried to make an EMCO package with admin rights. Now we dont see any error codes and it says installed but the file is not imported.
Very simple command but still not working in snapin@ECHO ON bcdedit /import C:\Grub\Linux\file_bcd
-
@marted Have you used PsExec as mentioned below to test as SYSTEM account?
-
@Sebastian-Roth I’ll try in few minutes
-
@Sebastian-Roth I didnt answer because now we have a problem with the client on the cloned host and cannot check the package works or not. The problem started few days ago ONLY with new cloned hosts. On all new cloned hosts we have the same error message in the fog.log file.
2020-02-18 11:06 Client-Info Client OS: Windows 2020-02-18 11:06 Client-Info Server Version: 1.5.7 2020-02-18 11:06 Middleware::Response ERROR: Unable to get subsection 2020-02-18 11:06 Middleware::Response ERROR: La référence d'objet n'est pas définie à une instance d'un objet. ------------------------------------------------------------------------------ --------------------------------HostnameChanger------------------------------- ------------------------------------------------------------------------------ 2020-02-18 11:06 Client-Info Client Version: 0.11.16 2020-02-18 11:06 Client-Info Client OS: Windows 2020-02-18 11:06 Client-Info Server Version: 1.5.7 2020-02-18 11:06 Middleware::Response ERROR: Unable to get subsection 2020-02-18 11:06 Middleware::Response ERROR: La référence d'objet n'est pas définie à une instance d'un objet. ------------------------------------------------------------------------------ ---------------------------------SnapinClient--------------------------------- ------------------------------------------------------------------------------ 2020-02-18 11:06 Client-Info Client Version: 0.11.16 2020-02-18 11:06 Client-Info Client OS: Windows 2020-02-18 11:06 Client-Info Server Version: 1.5.7 2020-02-18 11:06 Middleware::Response ERROR: Unable to get subsection 2020-02-18 11:06 Middleware::Response ERROR: La référence d'objet n'est pas définie à une instance d'un objet. ------------------------------------------------------------------------------ --------------------------------PrinterManager-------------------------------- ------------------------------------------------------------------------------ 2020-02-18 11:06 Client-Info Client Version: 0.11.16 2020-02-18 11:06 Client-Info Client OS: Windows 2020-02-18 11:06 Client-Info Server Version: 1.5.7 2020-02-18 11:06 Middleware::Response ERROR: Unable to get subsection 2020-02-18 11:06 Middleware::Response ERROR: La référence d'objet n'est pas définie à une instance d'un objet. ------------------------------------------------------------------------------ --------------------------------PowerManagement------------------------------- ------------------------------------------------------------------------------ 2020-02-18 11:06 Client-Info Client Version: 0.11.16 2020-02-18 11:06 Client-Info Client OS: Windows 2020-02-18 11:06 Client-Info Server Version: 1.5.7 2020-02-18 11:06 Middleware::Response ERROR: Unable to get subsection 2020-02-18 11:06 Middleware::Response ERROR: La référence d'objet n'est pas définie à une instance d'un objet. ------------------------------------------------------------------------------ ----------------------------------UserTracker--------------------------------- ------------------------------------------------------------------------------ 2020-02-18 11:06 Client-Info Client Version: 0.11.16 2020-02-18 11:06 Client-Info Client OS: Windows 2020-02-18 11:06 Client-Info Server Version: 1.5.7 2020-02-18 11:06 Middleware::Response ERROR: Unable to get subsection 2020-02-18 11:06 Middleware::Response ERROR: La référence d'objet n'est pas définie à une instance d'un objet. 2020-02-18 11:06 Service Sleeping for 63 seconds 2020-02-18 11:07 Middleware::Communication URL: http://192.168.149.43/fog/management/index.php?sub=requestClientInfo&configure&newService&json 2020-02-18 11:07 Middleware::Response Success 2020-02-18 11:07 Middleware::Communication URL: http://192.168.149.43/fog/management/index.php?sub=requestClientInfo&mac=0A:00:27:00:00:17|40:B0:34:F7:EF:D8|A0:AF:BD:82:49:FC|A0:AF:BD:82:49:FD|A2:AF:BD:82:49:FC|A0:AF:BD:82:4A:00&newService&json 2020-02-18 11:07 Middleware::Communication ERROR: Could not contact FOG server 2020-02-18 11:07 Middleware::Communication ERROR: Le serveur distant a retourné une erreur : (500) Erreur interne du serveur. 2020-02-18 11:07 Middleware::Response Success 2020-02-18 11:07 Middleware::Communication URL: http://192.168.149.43/fog/service/getversion.php?clientver&newService&json 2020-02-18 11:07 Middleware::Communication URL: http://192.168.149.43/fog/service/getversion.php?newService&json 2020-02-18 11:07 Service Creating user agent cache 2020-02-18 11:07 Middleware::Response ERROR: Unable to get subsection 2020-02-18 11:07 Middleware::Response ERROR: La référence d'objet n'est pas définie à une instance d'un objet. 2020-02-18 11:07 Middleware::Response ERROR: Unable to get subsection 2020-02-18 11:07 Middleware::Response ERROR: La référence d'objet n'est pas définie à une instance d'un objet. 2020-02-18 11:07 Middleware::Response ERROR: Unable to get subsection 2020-02-18 11:07 Middleware::Response ERROR: La référence d'objet n'est pas définie à une instance d'un objet. ------------------------------------------------------------------------------ ---------------------------------ClientUpdater-------------------------------- ------------------------------------------------------------------------------ 2020-02-18 11:07 Client-Info Client Version: 0.11.16 2020-02-18 11:07 Client-Info Client OS: Windows 2020-02-18 11:07 Client-Info Server Version: 1.5.7 2020-02-18 11:07 Middleware::Response Success ------------------------------------------------------------------------------ ------------------------------------------------------------------------------ ----------------------------------TaskReboot---------------------------------- ------------------------------------------------------------------------------ 2020-02-18 11:07 Client-Info Client Version: 0.11.16 2020-02-18 11:07 Client-Info Client OS: Windows 2020-02-18 11:07 Client-Info Server Version: 1.5.7 2020-02-18 11:07 Middleware::Response ERROR: Unable to get subsection 2020-02-18 11:07 Middleware::Response ERROR: La référence d'objet n'est pas définie à une instance d'un objet. ------------------------------------------------------------------------------ --------------------------------HostnameChanger------------------------------- ------------------------------------------------------------------------------ 2020-02-18 11:07 Client-Info Client Version: 0.11.16 2020-02-18 11:07 Client-Info Client OS: Windows 2020-02-18 11:07 Client-Info Server Version: 1.5.7 2020-02-18 11:07 Middleware::Response ERROR: Unable to get subsection 2020-02-18 11:07 Middleware::Response ERROR: La référence d'objet n'est pas définie à une instance d'un objet. ------------------------------------------------------------------------------ ---------------------------------SnapinClient--------------------------------- ------------------------------------------------------------------------------ 2020-02-18 11:07 Client-Info Client Version: 0.11.16 2020-02-18 11:07 Client-Info Client OS: Windows 2020-02-18 11:07 Client-Info Server Version: 1.5.7 2020-02-18 11:07 Middleware::Response ERROR: Unable to get subsection 2020-02-18 11:07 Middleware::Response ERROR: La référence d'objet n'est pas définie à une instance d'un objet. ------------------------------------------------------------------------------ --------------------------------PrinterManager-------------------------------- ------------------------------------------------------------------------------ 2020-02-18 11:07 Client-Info Client Version: 0.11.16 2020-02-18 11:07 Client-Info Client OS: Windows 2020-02-18 11:07 Client-Info Server Version: 1.5.7 2020-02-18 11:07 Middleware::Response ERROR: Unable to get subsection 2020-02-18 11:07 Middleware::Response ERROR: La référence d'objet n'est pas définie à une instance d'un objet. ------------------------------------------------------------------------------ --------------------------------PowerManagement------------------------------- ------------------------------------------------------------------------------ 2020-02-18 11:07 Client-Info Client Version: 0.11.16 2020-02-18 11:07 Client-Info Client OS: Windows 2020-02-18 11:07 Client-Info Server Version: 1.5.7 2020-02-18 11:07 Middleware::Response ERROR: Unable to get subsection 2020-02-18 11:07 Middleware::Response ERROR: La référence d'objet n'est pas définie à une instance d'un objet.
I wanted also to try to upgrade to 11.18 the client to see maybe this will solve the problem but honestly I couldn’t find how to upgrade the client to 11.18 . I downloaded the file from your official page release, uncompressed and nothing. Don’t know which file to pick up and how to upgrade the client to all hosts
-
I found the smart installer for 11.19 Now it works on http. We will try to activate https on our server and activate https on the client