Snapin Hash Issue
- FOG Version: 1.4.0-RC-7
- OS: Ubuntu 16.04
- Service Version:
Snapin Hash issue. Updating a snapin and it looks like it’s not rehashing on upload. Created a new snapin and uploaded and same thing. It keeps its old hash no matter what I do. I also reset encryption though it would not matter. I also deleted the snapin and still does it after uploading again.
5/31/2017 10:51 AM Client-Info Client Version: 0.11.12 5/31/2017 10:51 AM Client-Info Client OS: Windows 5/31/2017 10:51 AM Client-Info Server Version: 1.4.0-RC-7 5/31/2017 10:51 AM Middleware::Response Success 5/31/2017 10:51 AM SnapinClient Running snapin Windows_10_and_Office_Activate 5/31/2017 10:51 AM Middleware::Communication Download: http://fogserver/fog/service/snapins.file.php?mac=02:50:41:00:00:01|3C:52:82:40:06:A4|00:28:F8:67:1F:E3|00:28:F8:67:1F:E2|00:28:F8:67:1F:E6||00:00:00:00:00:00:00:E0|00:00:00:00:00:00:00:E0|00:00:00:00:00:00:00:E0&taskid=132865 5/31/2017 10:51 AM SnapinClient C:\Program Files (x86)\FOG\tmp\Activate10.bat 5/31/2017 10:51 AM SnapinClient ERROR: Hash does not match 5/31/2017 10:51 AM SnapinClient ERROR: --> Ideal: 6ADEE03D4378F3489F282FD10387FDAA743C9B054A305F4AB260BE6BC009A080CCF8C71C64445887B7C2CA454E02638AA8D83868FC61F32DA0D4D4FC661653DD 5/31/2017 10:51 AM SnapinClient ERROR: --> Actual: BFBA49E97B70CC6E124CAD15C3775245230B9BCEE4E7641566AC88B812D2822C39C58A3797A2FDE9B5E4721D24DF20A9D66490236688FBD39E7DCE154C51C365 5/31/2017 10:51 AM Middleware::Communication URL: http://fogserver/fog/service/snapins.checkin.php?taskid=132865&exitcode=-1&mac=02:50:41:00:00:01|3C:52:82:40:06:A4|00:28:F8:67:1F:E3|00:28:F8:67:1F:E2|00:28:F8:67:1F:E6||00:00:00:00:00:00:00:E0|00:00:00:00:00:00:00:E0|00:00:00:00:00:00:00:E0&newService&json
But if we use any snapin from out master FOG the hash fails. In the temp folder it downloads 1KB
If the file on the server is whole, but not being downloaded to clients - this has to be some sort of network or security problem. It could be a content filter, a firewall, antivirus, anti-malware. You know your environment better than us - spend time thinking about what could possibly block the download.
What gets me is if we use snapins that were created for a FOG node we gave to a vendor for imaging they work. But if we use any snapin from out master FOG the hash fails. In the temp folder it downloads 1KB
Tested today. It is only Windows 10. Any snapin works for Windows 7. So what else can I test as to why Windows 10 is messing with the FOG client.
Already updated the other day no affect. This might be a Win 10 thing. I am going to test that theory tomorrow.
@Wayne-Workman We ran through manual hashes and the fog server hash is correct. I haven’t seen a client hash fail except under relatively certain circumstances.
I’m just guessing, but maybe antivirus is quarantining/removing the file before it is able to be checked. Maybe there’s a content blocker not allowing the file to pass to the client?
Let’s re-evaluate where the issue is not.
It’s not the client. Why? Others are not complaining. Joe tests the client functionality throughly. The client’s code for this hasn’t changed in a while.
It’s not the fog server’s Code. Why? Others are not complaining. The fog community uses snapins heavily.
What’s left? Your server, it’s configuration, it’s environment.
Knowing that, we should start digging into what’s different about your server.
First, I would suggest upgrading to 1.4.1. Second, I’d start looking through /var/log/apache2/error_log after uploading a new snapin. I’d look for botched symlinks, misnamed directories, bad permissions, and incorrect configurations.
@UWPVIOLATOR I’m sorry I’m not 100% on the way the client does the hashing. I know we do test things, but it would seem maybe it can’t write to the same point on the client machine and is coming up with a sha512 hash of 0 byte file? (No I don’t expect you to have the answer).
In the GUI it looks hashed right but on the FOG log of the client. The Actual Hash is BFBA49E97B70CC6E124CAD15C3775245230B9BCEE4E7641566AC88B812D2822C39C58A3797A2FDE9B5E4721D24DF20A9D66490236688FBD39E7DCE154C51C365
That comes up for all snapins now that we reset and rehashed all snapins.
So all hashes are coming back as 6ADEE03D4…?
@UWPVIOLATOR Who own’s the /opt/fog/snapins directory?
This was a brand new file and snapin. All it is, is a batfile that says REM This is nothing
Uploaded the snapin. FOG Say it is a93f93076abc51757f22fc9776c5f12fe67b68c25fc3358d244ee75ff83be23a29c19e690d9b6875c7834640c0ba109ad8becf3a1c0df247b488caca98375945
Here is what happens when pushing it out.
------------------------------------------------------------------------------ ---------------------------------SnapinClient--------------------------------- ------------------------------------------------------------------------------ 6/5/2017 12:30 PM Client-Info Client Version: 0.11.12 6/5/2017 12:30 PM Client-Info Client OS: Windows 6/5/2017 12:30 PM Client-Info Server Version: 1.4.1 6/5/2017 12:30 PM Middleware::Response Success 6/5/2017 12:30 PM SnapinClient Running snapin Test 2 6/5/2017 12:30 PM Middleware::Communication Download: http://fogserver/fog/service/snapins.file.php?mac=02:50:41:00:00:01|3C:52:82:4D:86:83|00:28:F8:66:06:A8|02:28:F8:66:06:A7|00:28:F8:66:06:A7|00:28:F8:66:06:AB||00:00:00:00:00:00:00:E0|00:00:00:00:00:00:00:E0&taskid=133051 6/5/2017 12:30 PM SnapinClient C:\Program Files (x86)\FOG\tmp\Test.bat 6/5/2017 12:30 PM SnapinClient ERROR: Hash does not match 6/5/2017 12:30 PM SnapinClient ERROR: --> Ideal: A93F93076ABC51757F22FC9776C5F12FE67B68C25FC3358D244EE75FF83BE23A29C19E690D9B6875C7834640C0BA109AD8BECF3A1C0DF247B488CACA98375945 6/5/2017 12:30 PM SnapinClient ERROR: --> Actual: BFBA49E97B70CC6E124CAD15C3775245230B9BCEE4E7641566AC88B812D2822C39C58A3797A2FDE9B5E4721D24DF20A9D66490236688FBD39E7DCE154C51C365
Super small .bat files
I have reuploaded, deleted and recreated and it still is not hashing correctly.
@UWPVIOLATOR How big is the file?
Smaller files should not have this problem.
Is it possible /tmp is set to noexec?
@Wayne-Workman Still have not done your update snapins set sHash = null;
but I created a new snapin and its always the same Hash regardless of what is uploaded.
Hash log says it checking and looks like this.
[06-05-17 12:19:23 pm] * Trying Snapin hash for: Windows_10_and_Office_Activate, ID: 275 [06-05-17 12:19:23 pm] | Snapin hash already set [06-05-17 12:19:23 pm] * Trying Snapin hash for: Windows_7_and_Office_Activate, ID: 71 [06-05-17 12:19:23 pm] | Snapin hash already set```
@Wayne-Workman I lied its now doing it again.
UWPVIOLATOR last edited by UWPVIOLATOR
@Wayne-Workman Updating to latest version resolved this issue. Thank you
If you set that column to null, the
FOGSnapinHashservice will re-hash everything. You can export the database before you do this for safety.
update snapins set sHash = null;Also, you should update. This problem could be one something that’s fixed in the latest stable release of FOG, 1.4.1.