• Recent
  • Unsolved
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Register
  • Login
  • Recent
  • Unsolved
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Register
  • Login

Snapins batch based are not working propperly when $ in path

Scheduled Pinned Locked Moved Solved
FOG Problems
5
7
1.3k
Loading More Posts
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • X
    x23piracy
    last edited by x23piracy May 18, 2016, 4:23 AM May 18, 2016, 10:22 AM

    Hi,

    i found out that snapins based on batch files does not work propperly when using unc paths that contain a dollar $.
    When using the same batch with an unc path without the $ everything is working fine.

    Little example:

    Not working

    @echo off
    cscript \\vs-ha-backup\install$\MSOffice\Office365\2003kill.vbs All /Q /NoCancel /BYPASS 1
    cscript \\vs-ha-backup\install$\MSOffice\Office365\2007kill.vbs All /Q /NoCancel /BYPASS 1
    cscript \\vs-ha-backup\install$\MSOffice\Office365\2010kill.vbs All /Q /NoCancel /BYPASS 1
    cscript \\vs-ha-backup\install$\MSOffice\Office365\2013kill.vbs All /Q /NoCancel /BYPASS 1
    cscript \\vs-ha-backup\install$\MSOffice\Office365\2016kill.vbs All /Q /NoCancel /BYPASS 1
    cscript \\vs-ha-backup\install$\MSOffice\Office365\2013_2016c2r.vbs All /Q /NoCancel /BYPASS 1
    \\vs-ha-backup\install$\MSOffice\Office365\setup.exe /configure \\vs-ha-backup\install$\MSOffice\Office365\proplus.xml
    EXIT
    

    Working

    @echo off
    cscript \\it4005\install\Office365\2003kill.vbs All /Q /NoCancel /BYPASS 1
    cscript \\it4005\install\Office365\2007kill.vbs All /Q /NoCancel /BYPASS 1
    cscript \\it4005\install\Office365\2010kill.vbs All /Q /NoCancel /BYPASS 1
    cscript \\it4005\install\Office365\2013kill.vbs All /Q /NoCancel /BYPASS 1
    cscript \\it4005\install\Office365\2016kill.vbs All /Q /NoCancel /BYPASS 1
    cscript \\it4005\install\Office365\2013_2016c2r.vbs All /Q /NoCancel /BYPASS 1
    \\it4005\install\Office365\setup.exe /configure \\it4005\install\Office365\proplus.xml
    EXIT
    

    Could that be fixed please?

    Regards X23

    ║▌║█║▌│║▌║▌█

    1 Reply Last reply Reply Quote 0
    • S
      Sebastian Roth Moderator
      last edited by Sebastian Roth May 18, 2016, 12:41 PM May 18, 2016, 6:40 PM

      Are you able to run the batch file with $ UNC path by hand? Which error do you get when running this as snapin?

      Web GUI issue? Please check apache error (debian/ubuntu: /var/log/apache2/error.log, centos/fedora/rhel: /var/log/httpd/error_log) and php-fpm log (/var/log/php*-fpm.log)

      Please support FOG if you like it: https://wiki.fogproject.org/wiki/index.php/Support_FOG

      1 Reply Last reply Reply Quote 0
      • J
        Joe Schmitt Senior Developer
        last edited by Joe Schmitt May 18, 2016, 4:12 PM May 18, 2016, 10:09 PM

        If you are able to run those scripts manually (with $ UNC paths), than would be a restriction of running as SYSTEM. There is nothing the client can do about this.

        Please help us build the FOG community with everyone involved. It's not just about coding - way more we need people to test things, update documentation and most importantly work on uniting the community of people enjoying and working on FOG! Get in contact with me (chat bubble in the top right corner) if you want to join in.

        1 Reply Last reply Reply Quote 1
        • W
          Wayne Workman
          last edited by Wayne Workman May 18, 2016, 5:14 PM May 18, 2016, 11:14 PM

          I ran a default profile deploying script via snapins today from a share with a dollar sign at the end and it worked fine. Given I’m probably a few versions behind at work.

          Please help us build the FOG community with everyone involved. It's not just about coding - way more we need people to test things, update documentation and most importantly work on uniting the community of people enjoying and working on FOG!
          Daily Clean Installation Results:
          https://fogtesting.fogproject.us/
          FOG Reporting:
          https://fog-external-reporting-results.fogproject.us/

          X 1 Reply Last reply May 19, 2016, 8:21 AM Reply Quote 0
          • X
            x23piracy @Wayne Workman
            last edited by x23piracy May 19, 2016, 2:25 AM May 19, 2016, 8:21 AM

            @Wayne-Workman here are my logs for the presented batch files, the one with $ making problems and the one without $ working:

            With $ dollar:

             19.05.2016 09:43 Middleware::Communication URL: http://fog/fog/management/index.php?sub=requestClientInfo&mac=F4:CE:46:2F:EE:FE||00:00:00:00:00:00:00:E0&newService&json
             19.05.2016 09:43 Middleware::Response Success
             19.05.2016 09:43 Middleware::Communication URL: http://fog/fog/service/getversion.php?clientver&newService&json
             19.05.2016 09:43 Middleware::Communication URL: http://fog/fog/service/getversion.php?newService&json
            
             19.05.2016 09:43 Service Creating user agent cache
             19.05.2016 09:43 Middleware::Response Success
             19.05.2016 09:43 Middleware::Response Success
            
            ------------------------------------------------------------------------------
            ---------------------------------ClientUpdater--------------------------------
            ------------------------------------------------------------------------------
             19.05.2016 09:43 Client-Info Client Version: 0.10.6
             19.05.2016 09:43 Client-Info Client OS:      Windows
             19.05.2016 09:43 Client-Info Server Version: 7709
             19.05.2016 09:43 Middleware::Response Success
            ------------------------------------------------------------------------------
            
            
            ------------------------------------------------------------------------------
            ----------------------------------TaskReboot----------------------------------
            ------------------------------------------------------------------------------
             19.05.2016 09:43 Client-Info Client Version: 0.10.6
             19.05.2016 09:43 Client-Info Client OS:      Windows
             19.05.2016 09:43 Client-Info Server Version: 7709
             19.05.2016 09:43 Middleware::Response Success
            ------------------------------------------------------------------------------
            
            
            ------------------------------------------------------------------------------
            --------------------------------HostnameChanger-------------------------------
            ------------------------------------------------------------------------------
             19.05.2016 09:43 Client-Info Client Version: 0.10.6
             19.05.2016 09:43 Client-Info Client OS:      Windows
             19.05.2016 09:43 Client-Info Server Version: 7709
             19.05.2016 09:43 Middleware::Response Success
             19.05.2016 09:43 HostnameChanger Checking Product Key Activation
             19.05.2016 09:43 HostnameChanger Already activated with correct key
             19.05.2016 09:43 HostnameChanger Users still logged in and enforce is disabled, delaying any further actions
            ------------------------------------------------------------------------------
            
            
            ------------------------------------------------------------------------------
            ---------------------------------SnapinClient---------------------------------
            ------------------------------------------------------------------------------
             19.05.2016 09:43 Client-Info Client Version: 0.10.6
             19.05.2016 09:43 Client-Info Client OS:      Windows
             19.05.2016 09:43 Client-Info Server Version: 7709
             19.05.2016 09:43 Middleware::Response Success
             19.05.2016 09:43 SnapinClient Snapin Found:
             19.05.2016 09:43 SnapinClient     ID: 23
             19.05.2016 09:43 SnapinClient     RunWith: cmd.exe
             19.05.2016 09:43 SnapinClient     RunWithArgs: /c
             19.05.2016 09:43 SnapinClient     Name: Office 365 ProPlus Backup
             19.05.2016 09:43 SnapinClient     File: proplus.cmd
             19.05.2016 09:43 SnapinClient     Created: 2016-05-19 09:42:53
             19.05.2016 09:43 SnapinClient     Args: 
             19.05.2016 09:43 SnapinClient     Action: 
             19.05.2016 09:43 Middleware::Communication Download: http://fog/fog/service/snapins.file.php?mac=F4:CE:46:2F:EE:FE||00:00:00:00:00:00:00:E0&taskid=23
             19.05.2016 09:43 SnapinClient C:\Program Files (x86)\FOG\tmp\proplus.cmd
             19.05.2016 09:43 Bus {
              "self": true,
              "channel": "Notification",
              "data": "{\r\n  \"title\": \"Installing Office 365 ProPlus Backup\",\r\n  \"message\": \"Please do not shutdown until this is completed\",\r\n  \"subjectID\": \"snapin-Office 365 ProPlus Backup\"\r\n}"
            }
             19.05.2016 09:43 Bus Emmiting message on channel: Notification
             19.05.2016 09:43 SnapinClient Starting snapin...
             19.05.2016 09:44 SnapinClient Snapin finished
             19.05.2016 09:44 SnapinClient Return Code: 5
             19.05.2016 09:44 Bus {
              "self": true,
              "channel": "Notification",
              "data": "{\r\n  \"title\": \"Office 365 ProPlus Backup Installed\",\r\n  \"message\": \"Installation has finished and is now ready for use\",\r\n  \"subjectID\": \"snapin-Office 365 ProPlus Backup\"\r\n}"
            }
             19.05.2016 09:44 Bus Emmiting message on channel: Notification
             19.05.2016 09:44 Middleware::Communication URL: http://fog/fog/service/snapins.checkin.php?taskid=23&exitcode=5&mac=F4:CE:46:2F:EE:FE||00:00:00:00:00:00:00:E0&newService&json
             19.05.2016 09:44 Middleware::Communication ERROR: Could not contact FOG server
             19.05.2016 09:44 Middleware::Communication ERROR: Der Remoteserver hat einen Fehler zurückgegeben: (500) Interner Serverfehler.
            ------------------------------------------------------------------------------
            
            
            ------------------------------------------------------------------------------
            --------------------------------PrinterManager--------------------------------
            ------------------------------------------------------------------------------
             19.05.2016 09:44 Client-Info Client Version: 0.10.6
             19.05.2016 09:44 Client-Info Client OS:      Windows
             19.05.2016 09:44 Client-Info Server Version: 7709
             19.05.2016 09:44 Middleware::Response Success
             19.05.2016 09:44 PrinterManager Adding printers
             19.05.2016 09:44 PrinterManager IT already exists
             19.05.2016 09:44 PrinterManager IT2 already exists
            ------------------------------------------------------------------------------
            
            
            ------------------------------------------------------------------------------
            -----------------------------------GreenFOG-----------------------------------
            ------------------------------------------------------------------------------
             19.05.2016 09:44 Client-Info Client Version: 0.10.6
             19.05.2016 09:44 Client-Info Client OS:      Windows
             19.05.2016 09:44 Client-Info Server Version: 7709
             19.05.2016 09:44 Middleware::Response No actions
            ------------------------------------------------------------------------------
            
            
            ------------------------------------------------------------------------------
            ----------------------------------UserTracker---------------------------------
            ------------------------------------------------------------------------------
             19.05.2016 09:44 Client-Info Client Version: 0.10.6
             19.05.2016 09:44 Client-Info Client OS:      Windows
             19.05.2016 09:44 Client-Info Server Version: 7709
             19.05.2016 09:44 Middleware::Response Success
            ------------------------------------------------------------------------------
            
             19.05.2016 09:44 Middleware::Communication URL: http://fog/fog/management/index.php?sub=requestClientInfo&configure&newService&json
             19.05.2016 09:44 Middleware::Response Success
             19.05.2016 09:44 Service Sleeping for 125 seconds
            

            And the one without $:

             19.05.2016 09:54 Middleware::Communication URL: http://fog/fog/management/index.php?sub=requestClientInfo&mac=F4:CE:46:2F:EE:FE||00:00:00:00:00:00:00:E0&newService&json
             19.05.2016 09:54 Middleware::Response Success
             19.05.2016 09:54 Middleware::Communication URL: http://fog/fog/service/getversion.php?clientver&newService&json
             19.05.2016 09:54 Middleware::Communication URL: http://fog/fog/service/getversion.php?newService&json
            
             19.05.2016 09:54 Service Creating user agent cache
             19.05.2016 09:54 Middleware::Response Success
             19.05.2016 09:54 Middleware::Response Success
            
            ------------------------------------------------------------------------------
            ---------------------------------ClientUpdater--------------------------------
            ------------------------------------------------------------------------------
             19.05.2016 09:54 Client-Info Client Version: 0.10.6
             19.05.2016 09:54 Client-Info Client OS:      Windows
             19.05.2016 09:54 Client-Info Server Version: 7709
             19.05.2016 09:54 Middleware::Response Success
            ------------------------------------------------------------------------------
            
            
            ------------------------------------------------------------------------------
            ----------------------------------TaskReboot----------------------------------
            ------------------------------------------------------------------------------
             19.05.2016 09:54 Client-Info Client Version: 0.10.6
             19.05.2016 09:54 Client-Info Client OS:      Windows
             19.05.2016 09:54 Client-Info Server Version: 7709
             19.05.2016 09:54 Middleware::Response Success
            ------------------------------------------------------------------------------
            
            
            ------------------------------------------------------------------------------
            --------------------------------HostnameChanger-------------------------------
            ------------------------------------------------------------------------------
             19.05.2016 09:54 Client-Info Client Version: 0.10.6
             19.05.2016 09:54 Client-Info Client OS:      Windows
             19.05.2016 09:54 Client-Info Server Version: 7709
             19.05.2016 09:54 Middleware::Response Success
             19.05.2016 09:54 HostnameChanger Checking Product Key Activation
             19.05.2016 09:54 HostnameChanger Already activated with correct key
             19.05.2016 09:54 HostnameChanger Users still logged in and enforce is disabled, delaying any further actions
            ------------------------------------------------------------------------------
            
            
            ------------------------------------------------------------------------------
            ---------------------------------SnapinClient---------------------------------
            ------------------------------------------------------------------------------
             19.05.2016 09:54 Client-Info Client Version: 0.10.6
             19.05.2016 09:54 Client-Info Client OS:      Windows
             19.05.2016 09:54 Client-Info Server Version: 7709
             19.05.2016 09:54 Middleware::Response Success
             19.05.2016 09:54 SnapinClient Snapin Found:
             19.05.2016 09:54 SnapinClient     ID: 26
             19.05.2016 09:54 SnapinClient     RunWith: cmd.exe
             19.05.2016 09:54 SnapinClient     RunWithArgs: /c
             19.05.2016 09:54 SnapinClient     Name: Office 365 ProPlus IT4005
             19.05.2016 09:54 SnapinClient     File: proplus.cmd
             19.05.2016 09:54 SnapinClient     Created: 2016-05-19 09:53:10
             19.05.2016 09:54 SnapinClient     Args: 
             19.05.2016 09:54 SnapinClient     Action: 
             19.05.2016 09:54 Middleware::Communication Download: http://fog/fog/service/snapins.file.php?mac=F4:CE:46:2F:EE:FE||00:00:00:00:00:00:00:E0&taskid=26
             19.05.2016 09:54 SnapinClient C:\Program Files (x86)\FOG\tmp\proplus.cmd
             19.05.2016 09:54 Bus {
              "self": true,
              "channel": "Notification",
              "data": "{\r\n  \"title\": \"Installing Office 365 ProPlus IT4005\",\r\n  \"message\": \"Please do not shutdown until this is completed\",\r\n  \"subjectID\": \"snapin-Office 365 ProPlus IT4005\"\r\n}"
            }
             19.05.2016 09:54 Bus Emmiting message on channel: Notification
             19.05.2016 09:54 SnapinClient Starting snapin...
             19.05.2016 10:06 SnapinClient Snapin finished
             19.05.2016 10:06 SnapinClient Return Code: 0
             19.05.2016 10:06 Bus {
              "self": true,
              "channel": "Notification",
              "data": "{\r\n  \"title\": \"Office 365 ProPlus IT4005 Installed\",\r\n  \"message\": \"Installation has finished and is now ready for use\",\r\n  \"subjectID\": \"snapin-Office 365 ProPlus IT4005\"\r\n}"
            }
             19.05.2016 10:06 Bus Emmiting message on channel: Notification
             19.05.2016 10:06 Middleware::Communication URL: http://fog/fog/service/snapins.checkin.php?taskid=26&exitcode=0&mac=F4:CE:46:2F:EE:FE||00:00:00:00:00:00:00:E0&newService&json
             19.05.2016 10:06 Middleware::Communication ERROR: Could not contact FOG server
             19.05.2016 10:06 Middleware::Communication ERROR: Der Remoteserver hat einen Fehler zurückgegeben: (500) Interner Serverfehler.
            ------------------------------------------------------------------------------
            
            
            ------------------------------------------------------------------------------
            --------------------------------PrinterManager--------------------------------
            ------------------------------------------------------------------------------
             19.05.2016 10:06 Client-Info Client Version: 0.10.6
             19.05.2016 10:06 Client-Info Client OS:      Windows
             19.05.2016 10:06 Client-Info Server Version: 7709
             19.05.2016 10:06 Middleware::Response Success
             19.05.2016 10:06 PrinterManager Adding printers
             19.05.2016 10:06 PrinterManager IT already exists
             19.05.2016 10:06 PrinterManager IT2 already exists
            ------------------------------------------------------------------------------
            
            
            ------------------------------------------------------------------------------
            -----------------------------------GreenFOG-----------------------------------
            ------------------------------------------------------------------------------
             19.05.2016 10:06 Client-Info Client Version: 0.10.6
             19.05.2016 10:06 Client-Info Client OS:      Windows
             19.05.2016 10:06 Client-Info Server Version: 7709
             19.05.2016 10:06 Middleware::Response No actions
            ------------------------------------------------------------------------------
            
            
            ------------------------------------------------------------------------------
            ----------------------------------UserTracker---------------------------------
            ------------------------------------------------------------------------------
             19.05.2016 10:06 Client-Info Client Version: 0.10.6
             19.05.2016 10:06 Client-Info Client OS:      Windows
             19.05.2016 10:06 Client-Info Server Version: 7709
             19.05.2016 10:06 Middleware::Response Success
            ------------------------------------------------------------------------------
            
             19.05.2016 10:06 Middleware::Communication URL: http://fog/fog/management/index.php?sub=requestClientInfo&configure&newService&json
             19.05.2016 10:06 Middleware::Response Success
             19.05.2016 10:06 Service Sleeping for 79 seconds
            

            When trying to install snaping with $ in batch i get error code 5
            the share on it4005 is accessible by everyone an the share on vs-ha-backup by authenticated users (domain) under which context is the snapin running? While trying to install the snapin iam logged on as domain admin.

            ║▌║█║▌│║▌║▌█

            Q 1 Reply Last reply May 19, 2016, 8:29 AM Reply Quote 0
            • Q
              Quazz Moderator @x23piracy
              last edited by Quazz May 19, 2016, 2:31 AM May 19, 2016, 8:29 AM

              @x23piracy Hi, error code 5 is a windows error that means Access denied, so there’s some permission/rights issue somewhere, either on your share (which is likely since it’s a hidden share) or with the account executing it (which is SYSTEM so unlikely)

              If you manually enter \vs-ha-backup\install$\MSOffice\Office365\setup.exe for instance, does it open the file? (do this on a clean system)

              x23piracyX 1 Reply Last reply May 19, 2016, 9:34 AM Reply Quote 0
              • x23piracyX
                x23piracy @Quazz
                last edited by May 19, 2016, 9:34 AM

                @Quazz Hi, thank you i could fix the problem it was really an access problem, right for everyone was missing, i broke the share and inherited everyone for only that folder and now it works. Great 🙂

                ║▌║█║▌│║▌║▌█

                1 Reply Last reply Reply Quote 1
                • 1 / 1
                1 / 1
                • First post
                  5/7
                  Last post

                194

                Online

                12.0k

                Users

                17.3k

                Topics

                155.2k

                Posts
                Copyright © 2012-2024 FOG Project