Snapin Hash does not exist



  • Re: Snapin Hash does not exist

    Running latest server 1.3.0-RC-10 with client 0.11.5.

    ------------------------------------------------------------------------------
    ---------------------------------SnapinClient---------------------------------
    ------------------------------------------------------------------------------
     16.09.2016 11:47 Client-Info Client Version: 0.11.5
     16.09.2016 11:47 Client-Info Client OS:      Windows
     16.09.2016 11:47 Client-Info Server Version: 1.3.0-RC-10
     16.09.2016 11:47 Middleware::Response Success
     16.09.2016 11:47 SnapinClient Snapin Found:
     16.09.2016 11:47 SnapinClient     ID: 2
     16.09.2016 11:47 SnapinClient     Name: mkdir
     16.09.2016 11:47 SnapinClient     Created: 2016-09-16 11:47:01
     16.09.2016 11:47 SnapinClient     Action: 
     16.09.2016 11:47 SnapinClient     Pack: False
     16.09.2016 11:47 SnapinClient     Hide: False
     16.09.2016 11:47 SnapinClient     Server: 
     16.09.2016 11:47 SnapinClient     TimeOut: 0
     16.09.2016 11:47 SnapinClient     RunWith: cmd.exe
     16.09.2016 11:47 SnapinClient     RunWithArgs: /c
     16.09.2016 11:47 SnapinClient     Args: 
     16.09.2016 11:47 SnapinClient     File: mkdir.bat
     16.09.2016 11:47 SnapinClient ERROR: Snapin hash does not exist
    

    Inside the DB the entry for the mkdir snapin looks like this:

    | 32 | mkdir |  | mkdir.bat | | 2016-02-15 14:14:27 | fog |  | cmd.exe | /c |  | 0 | 1 | 1 | 0 | 0 | 0 | 0 | cf83e1357eefb8bdf1542850d66d8007d620e4050b5715dc83f4a921d36ce9ce47d0d13c5d85f2b0ff8318d2877eec2f63b931bd47417a81a538327af927da3e | 0 |
    

    When I check the hash by typing x.x.x.x/fog/status/getsnapinhash.php?filepath=/opt/fog/snapins/mkdir.bat I get

    685f2f6208816e8a9220eabda08ba47c5d9d7e5796cd7a8927f01718fbc71931f9dce8446cc44be0e890d98bd3b917061ae9c1657a92cc03e5b2cbe5e16a188e|42 
    

    hash and size don’t match.

    I checked time on client an server, reset encryption data.

    Creating a new snapin first shows me the correct hash and size. After updating the new snapin size is zero and hash see above…



  • @Tom-Elliott

    Snapins are not replicated to the nodes.

    I used the lftp command from the fogsnapinreport.log but removed some inverted comma and backslash in some parts. After adding password and IP-Address manually the files uploaded to the nodes.

    original from fogsnapingreport.log:

    lftp -e 'set ftp:list-options -a;set net:max-retries 10;set net:timeout 30; ' ' mirror -c '-R -i [FILENAME]' --ignore-time -vvv --exclude 'dev/' --exclude 'ssl/' --exclude 'CA/' --delete-first ''\''/opt/fog/snapins'\''' '/opt/fog/snapins'; exit' -u 'fog',[Protected] '[IP_ADDR]'
    

    modified ftp command:

    lftp -e 'set ftp:list-options -a;set net:max-retries 10;set net:timeout 30; ' ' mirror -c -R -i [FILENAME] --ignore-time -vvv --exclude 'dev/' --exclude 'ssl/' --exclude 'CA/' --delete-first '/opt/fog/snapins' '/opt/fog/snapins'; exit' -u 'fog', [PASSWORD] '[IP_ADDR]'
    

    The restarted FOGSnapinReplicator showed a new logfile where all snapins match:

           ___           ___           ___
           /\  \         /\  \         /\  \
          /::\  \       /::\  \       /::\  \
         /:/\:\  \     /:/\:\  \     /:/\:\  \
        /::\-\:\  \   /:/  \:\  \   /:/  \:\  \
       /:/\:\ \:\__\ /:/__/ \:\__\ /:/__/_\:\__\
       \/__\:\ \/__/ \:\  \ /:/  / \:\  /\ \/__/
            \:\__\    \:\  /:/  /   \:\ \:\__\
             \/__/     \:\/:/  /     \:\/:/  /
                        \::/  /       \::/  /
                         \/__/         \/__/
    
      ###########################################
      #     Free Computer Imaging Solution      #
      #     Credits:                            #
      #     http://fogproject.org/credits       #
      #     GNU GPL Version 3                   #
      ###########################################
    
    [09-20-16 5:06:11 pm] Interface Ready with IP Address: X.X.X.X
    [09-20-16 5:06:11 pm] Interface Ready with IP Address: XXX
    [09-20-16 5:06:11 pm]  * Starting SnapinReplicator Service
    [09-20-16 5:06:11 pm]  * Checking for new items every 600 seconds
    [09-20-16 5:06:12 pm]  * Starting service loop
    [09-20-16 5:06:12 pm]  * Starting Snapin Replication.
    [09-20-16 5:06:12 pm]  * We are group ID: #1
    [09-20-16 5:06:12 pm]  | We are group name: default
    [09-20-16 5:06:12 pm]  * We have node ID: #1
    [09-20-16 5:06:12 pm]  | We are node name: fog
    [09-20-16 5:06:12 pm]  * Not syncing Snapin between group(s)
    [09-20-16 5:06:12 pm]  | Snapin Name: bios_upgrade
    [09-20-16 5:06:12 pm]  | I am the only member
    [09-20-16 5:06:12 pm]  * Not syncing Snapin between group(s)
    [09-20-16 5:06:12 pm]  | Snapin Name: delete fog.log
    [09-20-16 5:06:12 pm]  | I am the only member
    [09-20-16 5:06:12 pm]  * Not syncing Snapin between group(s)
    [09-20-16 5:06:12 pm]  | Snapin Name: gpupdate
    [09-20-16 5:06:12 pm]  | I am the only member
    [09-20-16 5:06:12 pm]  * Not syncing Snapin between group(s)
    [09-20-16 5:06:12 pm]  | Snapin Name: InstallBuildUp19
    [09-20-16 5:06:12 pm]  | I am the only member
    [09-20-16 5:06:12 pm]  * Found Snapin to transfer to 3 node(s)
    [09-20-16 5:06:12 pm]  | Snapin name: bios_upgrade
    [09-20-16 5:06:12 pm]  | Local File: /opt/fog/snapins/bios_a24.exe
    [09-20-16 5:06:12 pm]  | Remote File: /opt/fog/snapins/bios_a24.exe
    [09-20-16 5:06:12 pm]  | Local File size: 8542768
    
    [09-20-16 5:06:12 pm]  | Remote File size: 8542768
    [09-20-16 5:06:12 pm]  | Files match
    [09-20-16 5:06:12 pm]  | Local File: /opt/fog/snapins/bios_a24.exe
    [09-20-16 5:06:12 pm]  | Remote File: /opt/fog/snapins/bios_a24.exe
    [09-20-16 5:06:13 pm]  | Local File size: 8542768
    
    [09-20-16 5:06:13 pm]  | Remote File size: 8542768
    [09-20-16 5:06:13 pm]  | Files match
    [09-20-16 5:06:13 pm]  * Found Snapin to transfer to 3 node(s)
    [09-20-16 5:06:13 pm]  | Snapin name: delete fog.log
    [09-20-16 5:06:13 pm]  | Local File: /opt/fog/snapins/del_fog_log.bat
    [09-20-16 5:06:13 pm]  | Remote File: /opt/fog/snapins/del_fog_log.bat
    [09-20-16 5:06:13 pm]  | Local File size: 16
    
    [09-20-16 5:06:13 pm]  | Remote File size: 16
    [09-20-16 5:06:13 pm]  | Files match
    [09-20-16 5:06:13 pm]  | Local File: /opt/fog/snapins/del_fog_log.bat
    [09-20-16 5:06:13 pm]  | Remote File: /opt/fog/snapins/del_fog_log.bat
    [09-20-16 5:06:13 pm]  | Local File size: 16
    
    [09-20-16 5:06:13 pm]  | Remote File size: 16
    [09-20-16 5:06:13 pm]  | Files match
    [09-20-16 5:06:13 pm]  * Found Snapin to transfer to 3 node(s)
    [09-20-16 5:06:13 pm]  | Snapin name: gpupdate
    [09-20-16 5:06:14 pm]  | Local File: /opt/fog/snapins/gpupdate_force.bat
    [09-20-16 5:06:14 pm]  | Remote File: /opt/fog/snapins/gpupdate_force.bat
    [09-20-16 5:06:14 pm]  | Local File size: 52
    
    [09-20-16 5:06:14 pm]  | Remote File size: 52
    [09-20-16 5:06:14 pm]  | Files match
    [09-20-16 5:06:14 pm]  | Local File: /opt/fog/snapins/gpupdate_force.bat
    [09-20-16 5:06:14 pm]  | Remote File: /opt/fog/snapins/gpupdate_force.bat
    [09-20-16 5:06:14 pm]  | Local File size: 52
    
    [09-20-16 5:06:14 pm]  | Remote File size: 52
    [09-20-16 5:06:14 pm]  | Files match
    [09-20-16 5:06:14 pm]  * Found Snapin to transfer to 3 node(s)
    [09-20-16 5:06:14 pm]  | Snapin name: InstallBuildUp19
    [09-20-16 5:06:15 pm]  | Local File: /opt/fog/snapins/BuildupLokal.64bit.msi
    [09-20-16 5:06:15 pm]  | Remote File: /opt/fog/snapins/BuildupLokal.64bit.msi
    [09-20-16 5:06:15 pm]  | Local File size: 69743616
    
    [09-20-16 5:06:15 pm]  | Remote File size: 69743616
    [09-20-16 5:06:15 pm]  | Files match
    [09-20-16 5:06:15 pm]  | Local File: /opt/fog/snapins/BuildupLokal.64bit.msi
    [09-20-16 5:06:15 pm]  | Remote File: /opt/fog/snapins/BuildupLokal.64bit.msi
    [09-20-16 5:06:15 pm]  | Local File size: 69743616
    
    [09-20-16 5:06:15 pm]  | Remote File size: 69743616
    [09-20-16 5:06:15 pm]  | Files match
    


  • This post is deleted!


  • @Tom-Elliott

    Yes we are running the Location Plugin.

    Upgraded to 1.3.0-RC11 (Version 50)

    The snapins work only from the master node.
    Master node won’t replicate new created snapins to the slave nodes.

    [09-20-16 11:52:03 am] 
            ___           ___           ___      
           /\  \         /\  \         /\  \     
          /::\  \       /::\  \       /::\  \    
         /:/\:\  \     /:/\:\  \     /:/\:\  \   
        /::\-\:\  \   /:/  \:\  \   /:/  \:\  \  
       /:/\:\ \:\__\ /:/__/ \:\__\ /:/__/_\:\__\ 
       \/__\:\ \/__/ \:\  \ /:/  / \:\  /\ \/__/ 
            \:\__\    \:\  /:/  /   \:\ \:\__\   
             \/__/     \:\/:/  /     \:\/:/  /   
                        \::/  /       \::/  /    
                         \/__/         \/__/     
    
      ###########################################
      #     Free Computer Imaging Solution      #
      #     Credits:                            #
      #     http://fogproject.org/credits       #
      #     GNU GPL Version 3                   #
      ###########################################
    
    [09-20-16 11:52:03 am] Interface Ready with IP Address: X.X.X.X
    [09-20-16 11:52:03 am] Interface Ready with IP Address: XXX
    [09-20-16 11:52:03 am]  * Starting SnapinReplicator Service
    [09-20-16 11:52:03 am]  * Checking for new items every 600 seconds
    [09-20-16 11:52:03 am]  * Starting service loop
    [09-20-16 11:52:03 am]  * Starting Snapin Replication.
    [09-20-16 11:52:03 am]  * We are group ID: #1
    [09-20-16 11:52:03 am]  | We are group name: default
    [09-20-16 11:52:03 am]  * We have node ID: #1
    [09-20-16 11:52:03 am]  | We are node name: fog
    [09-20-16 11:52:03 am]  * Not syncing Snapin between group(s)
    [09-20-16 11:52:03 am]  | Snapin Name: bios_upgrade
    [09-20-16 11:52:03 am]  | I am the only member
    [09-20-16 11:52:03 am]  * Not syncing Snapin between group(s)
    [09-20-16 11:52:03 am]  | Snapin Name: delete fog.log
    [09-20-16 11:52:03 am]  | I am the only member
    [09-20-16 11:52:03 am]  * Not syncing Snapin between group(s)
    [09-20-16 11:52:03 am]  | Snapin Name: gpupdate
    [09-20-16 11:52:03 am]  | I am the only member
    [09-20-16 11:52:03 am]  * Found Snapin to transfer to 3 node(s)
    [09-20-16 11:52:03 am]  | Snapin name: bios_upgrade
    [09-20-16 11:52:03 am]  | Local File: /opt/fog/snapins/bios_a24.exe
    [09-20-16 11:52:03 am]  | Remote File: /opt/fog/snapins/bios_a24.exe
    [09-20-16 11:52:03 am]  | Local File size: 8542768
    
    [09-20-16 11:52:03 am]  | Remote File size: 0
    [09-20-16 11:52:03 am]  | Files do not match
    [09-20-16 11:52:03 am]  * Deleting remote file: /opt/fog/snapins/bios_a24.exe
    [09-20-16 11:52:03 am]  * Starting Sync Actions
    [09-20-16 11:52:03 am]  | CMD:
    			lftp -e 'set ftp:list-options -a;set net:max-retries 10;set net:timeout 30; '' mirror -c '-R -i bios_a24.exe' --ignore-time -vvv --exclude 'dev/' --exclude 'ssl/' --exclude 'CA/' --delete-first '/opt/fog/snapins' '/opt/fog/snapins'; exit' -u 'fog',[Protected] 'X.X.X.X'
    lftp: invalid option -- i
    Try `lftp --help' for more information
    [09-20-16 11:52:03 am]  * Started sync for Snapin bios_upgrade
    [09-20-16 11:52:04 am]  | Local File: /opt/fog/snapins/bios_a24.exe
    [09-20-16 11:52:04 am]  | Remote File: /opt/fog/snapins/bios_a24.exe
    [09-20-16 11:52:04 am]  | Local File size: 8542768
    
    [09-20-16 11:52:04 am]  | Remote File size: 0
    [09-20-16 11:52:04 am]  | Files do not match
    [09-20-16 11:52:04 am]  * Deleting remote file: /opt/fog/snapins/bios_a24.exe
    [09-20-16 11:52:04 am]  | CMD:
    			lftp -e 'set ftp:list-options -a;set net:max-retries 10;set net:timeout 30; '' mirror -c '-R -i bios_a24.exe' --ignore-time -vvv --exclude 'dev/' --exclude 'ssl/' --exclude 'CA/' --delete-first ''\''/opt/fog/snapins'\''' '/opt/fog/snapins'; exit' -u 'fog',[Protected] 'X.X.X.X'
    sh: 1: Syntax error: Unterminated quoted string
    [09-20-16 11:52:04 am]  * Started sync for Snapin bios_upgrade
    [09-20-16 11:52:04 am]  * Found Snapin to transfer to 3 node(s)
    [09-20-16 11:52:04 am]  | Snapin name: delete fog.log
    [09-20-16 11:52:04 am]  | Local File: /opt/fog/snapins/del_fog_log.bat
    [09-20-16 11:52:04 am]  | Remote File: /opt/fog/snapins/del_fog_log.bat
    [09-20-16 11:52:04 am]  | Local File size: 16
    
    [09-20-16 11:52:04 am]  | Remote File size: 0
    [09-20-16 11:52:04 am]  | Files do not match
    [09-20-16 11:52:04 am]  * Deleting remote file: /opt/fog/snapins/del_fog_log.bat
    [09-20-16 11:52:04 am]  * Starting Sync Actions
    [09-20-16 11:52:04 am]  | CMD:
    			lftp -e 'set ftp:list-options -a;set net:max-retries 10;set net:timeout 30; '' mirror -c '-R -i del_fog_log.bat' --ignore-time -vvv --exclude 'dev/' --exclude 'ssl/' --exclude 'CA/' --delete-first '/opt/fog/snapins' '/opt/fog/snapins'; exit' -u 'fog',[Protected] 'X.X.X.X'
    lftp: invalid option -- i
    Try `lftp --help' for more information
    [09-20-16 11:52:04 am]  * Started sync for Snapin delete fog.log
    [09-20-16 11:52:05 am]  | Local File: /opt/fog/snapins/del_fog_log.bat
    [09-20-16 11:52:05 am]  | Remote File: /opt/fog/snapins/del_fog_log.bat
    [09-20-16 11:52:05 am]  | Local File size: 16
    
    [09-20-16 11:52:05 am]  | Remote File size: 0
    [09-20-16 11:52:05 am]  | Files do not match
    [09-20-16 11:52:05 am]  * Deleting remote file: /opt/fog/snapins/del_fog_log.bat
    [09-20-16 11:52:05 am]  | CMD:
    			lftp -e 'set ftp:list-options -a;set net:max-retries 10;set net:timeout 30; '' mirror -c '-R -i del_fog_log.bat' --ignore-time -vvv --exclude 'dev/' --exclude 'ssl/' --exclude 'CA/' --delete-first ''\''/opt/fog/snapins'\''' '/opt/fog/snapins'; exit' -u 'fog',[Protected] 'X.X.X.X'
    sh: 1: Syntax error: Unterminated quoted string
    [09-20-16 11:52:05 am]  * Started sync for Snapin delete fog.log
    [09-20-16 11:52:05 am]  * Found Snapin to transfer to 3 node(s)
    [09-20-16 11:52:05 am]  | Snapin name: gpupdate
    [09-20-16 11:52:05 am]  | Local File: /opt/fog/snapins/gpupdate_force.bat
    [09-20-16 11:52:05 am]  | Remote File: /opt/fog/snapins/gpupdate_force.bat
    [09-20-16 11:52:05 am]  | Local File size: 52
    
    [09-20-16 11:52:05 am]  | Remote File size: 0
    [09-20-16 11:52:05 am]  | Files do not match
    [09-20-16 11:52:05 am]  * Deleting remote file: /opt/fog/snapins/gpupdate_force.bat
    [09-20-16 11:52:05 am]  * Starting Sync Actions
    [09-20-16 11:52:05 am]  | CMD:
    			lftp -e 'set ftp:list-options -a;set net:max-retries 10;set net:timeout 30; '' mirror -c '-R -i gpupdate_force.bat' --ignore-time -vvv --exclude 'dev/' --exclude 'ssl/' --exclude 'CA/' --delete-first '/opt/fog/snapins' '/opt/fog/snapins'; exit' -u 'fog',[Protected] 'X.X.X.X'
    lftp: invalid option -- i
    Try `lftp --help' for more information
    [09-20-16 11:52:05 am]  * Started sync for Snapin gpupdate
    [09-20-16 11:52:06 am]  | Local File: /opt/fog/snapins/gpupdate_force.bat
    [09-20-16 11:52:06 am]  | Remote File: /opt/fog/snapins/gpupdate_force.bat
    [09-20-16 11:52:06 am]  | Local File size: 52
    
    [09-20-16 11:52:06 am]  | Remote File size: 0
    [09-20-16 11:52:06 am]  | Files do not match
    [09-20-16 11:52:06 am]  * Deleting remote file: /opt/fog/snapins/gpupdate_force.bat
    [09-20-16 11:52:06 am]  | CMD:
    			lftp -e 'set ftp:list-options -a;set net:max-retries 10;set net:timeout 30; '' mirror -c '-R -i gpupdate_force.bat' --ignore-time -vvv --exclude 'dev/' --exclude 'ssl/' --exclude 'CA/' --delete-first ''\''/opt/fog/snapins'\''' '/opt/fog/snapins'; exit' -u 'fog',[Protected] 'X.X.X.X'
    sh: 1: Syntax error: Unterminated quoted string
    [09-20-16 11:52:06 am]  * Started sync for Snapin gpupdate
    
    

  • Senior Developer

    @Greg-Plamondon Thanks for the TV session.

    I found exactly what the issue is/was and it IS fixed for RC-11 for sure now.

    @mp12 Just for sanity reasons you’re running the Location Plugin?

    This issue was because of an oversite in logic check.

    The Storage Node and Groups are defined by location plugin, but the hashing checks were performed only in the case the node and group were not pre-defined. Basically I forgot to close the if at the right spot.

    Sorry, I’m trying for all I’m worth.


  • Testers

    Strange thing on my end is the storage node is coming up with a totally different hash value:
    0_1474053582886_upload-2eaa3b0d-4006-432f-bdc0-c23b85b34a7e


  • Testers

    I am having the same issue after upgrading.
    I am on 1.3.0-RC-10 5955



  • @Tom-Elliott

    Running Version 1.3.0-RC-10
    SVN Revision: 5955


  • Senior Developer

    @mp12 what’s the svn version showing?



  • I removed all my snapins.

    Created a new one see below. The hash was set after I created the snapin. Tried to deploy but getting the same error.
    Snapins also won’t replicate to the nodes.

    |  73 | gpupdate | | gpupdate_force.bat | | 2016-09-16 14:12:25 | fog | | cmd.exe | /c | | 0 | 1 | 1 | 0 | 0 | 0 | 0 | 6f84fb8dcae1e0a22915bb47f8a54140ab557893543f973fb1a265b84fd05d24e5c683243382fa2e57297d231e7ac229135df2d291842ff14eec43af0ca1f7cd | 52 |
    


  • @Tom-Elliott

    hash is blanked. After deploying the snapin it is not updated.


  • Senior Developer

    What I mean will not update the hash is it sets it to the hash of a blank file.


  • Senior Developer

    @mp12 Updating the snapin will not update the hash. If you blank the hash again, then get the host to try running it, then check the hash was it updated?



  • @Tom-Elliott

    first I tried pushing the snapin without updating hash

    when I update the hash (update snapin) it just switches to

    cf83e1357eefb8bdf1542850d66d8007d620e4050b5715dc83f4a921d36ce9ce47d0d13c5d85f2b0ff8318d2877eec2f63b931bd47417a81a538327af927da3e
    

    Size of file is still zero.


  • Senior Developer

    @mp12 did the hash get updated for that snapin?



  • @Tom-Elliott

    Query OK, 1 row affected (0.00 sec)
    Rows matched: 1  Changed: 1  Warnings: 0
    

    Done.

    hash is recessed.

    Tried to rerun the snapin. Same error.


  • Senior Developer

    Please run:

    mysql -u root If you have a mysql password run: mysql -u root -p then enter your password.

    When in the mysql shell please run:

    UPDATE snapins SET sHash='' WHERE sID=32;


Log in to reply
 

435
Online

38955
Users

10706
Topics

101580
Posts

Looks like your connection to FOG Project was lost, please wait while we try to reconnect.