Skip to content

Instantly share code, notes, and snippets.

@mpkocher
Last active October 2, 2019 15:02
Show Gist options
  • Save mpkocher/a4d74b791a1ef52c35bca7e61540bb2d to your computer and use it in GitHub Desktop.
Save mpkocher/a4d74b791a1ef52c35bca7e61540bb2d to your computer and use it in GitHub Desktop.
TechSupport Manual Submission of Failed Job Example

Manual creation of sending TS

  1. Get Failed Job By Id
  2. Use pbservice to create a TS failed job request
  3. Manually download the TGZ file from the Job UI page or curl
  4. Manulally send TGZ file using `tech-support-uploader'

From SL beta.

mkocher@login14-biofx01:~$  pbservice get-job 79177


*JOB SUMMARY* 
            id: 79177
          uuid: 4ba0641c-c6f9-42ce-b70c-4d3813389aae
          name: Bauhaus2_Job_RP55-09_Nominal
         state: FAILED
    project id: 1
     jobTypeId: pbsmrtpipe
     is active: true
     createdAt: 2018-01-04T01:59:36.412Z
     updatedAt: 2018-01-04T02:38:19.441Z
      run time: 2324 sec
    SL version: 5.1.0.21036
    created by: none
       comment: Description for job Pbsmrtpipe
          path: /pbi/dept/secondary/siv/smrtlink/smrtlink-beta/smrtsuite_166987/userdata/jobs_root/079/079177
      
Failed to run job Pbsmrtpipe job /pbi/dept/secondary/siv/smrtlink/smrtlink-beta/smrtsuite_166987/userdata/jobs_root/079/079177 failed with exit code 1. Cmd List(bash, /pbi/dept/secondary/siv/smrtlink/smrtlink-beta/smrtsuite_166987/userdata/jobs_root/079/079177/pbscala-job.sh) failed with exit code 1

Create a Failed Job Request

mkocher@login14-biofx01:~$ pbservice ts-failed-job 79177 --comment "Explicit failed job test from mk"
Attempting to send tech support failed job bundle
Tech support job bundle sent.
Job = 79177; name = Bauhaus2_Job_RP55-09_Nominal
User = mkocher
Comments: Explicit failed job test from mk

Note, if the system was not configured with an Eve URL, the original creation of the TS Failed job TGZ might fail. Offline or dark-site feature request was never requested

Double check new TS failed job was created

mkocher@login14-biofx01:~$ pbservice get-jobs --job-type tech-support-job
ID    State      Name                    UUID                                 CreatedBy
79421 SUCCESSFUL tech-support-job        c83a234e-5c4a-4ffc-b18c-9eff129364fc          
65580 SUCCESSFUL Tech Support Job bundle 490f3793-84a8-4c77-b78c-0e673a08db21 bgalvin  
61210 SUCCESSFUL Tech Support Job bundle 8e859cb0-1ad9-4067-9940-2fc1fb61908e          
61209 SUCCESSFUL Tech Support Job bundle f2a0cfca-ec8b-4a35-a2e8-76f700dc0c5a          
61208 SUCCESSFUL Tech Support Job bundle a4fae679-5f62-4d50-a78c-5202a998f324          
61207 SUCCESSFUL Tech Support Job bundle 17327d04-73a7-4c6b-8026-e64a749fdaa3          
61206 SUCCESSFUL Tech Support Job bundle ef498b7f-520b-46ac-9041-a210b788f3ad          
61066 SUCCESSFUL Tech Support Job bundle 140b1351-e9c9-4e52-9830-b65f00759082 admin    
61064 SUCCESSFUL Tech Support Job bundle 46899f48-0e9e-455f-bc0b-71836635665a admin    

Summary of 79421 which will have the TS TGZ bundle for the Failed analysis Job 79177

mkocher@login14-biofx01:~$ pbservice get-job 79421


*JOB SUMMARY* 
            id: 79421
          uuid: c83a234e-5c4a-4ffc-b18c-9eff129364fc
          name: tech-support-job
         state: SUCCESSFUL
    project id: 1
     jobTypeId: tech-support-job
     is active: true
     createdAt: 2018-01-08T20:59:08.417Z
     updatedAt: 2018-01-08T20:59:29.699Z
      run time: 22 sec
    SL version: 5.1.0.21036
    created by: none
       comment: Description for job PacBio TechSupport Failed Job
          path: /pbi/dept/secondary/siv/smrtlink/smrtlink-beta/smrtsuite_166987/userdata/jobs_root/079/079421

Download file from the SL UI or raw call to curl.

https://smrtlink-beta.nanofluidics.com:8243/sl/#/analysis/job/79421;show=all

Or

wget --no-check-certificate https://smrtlink-beta.nanofluidics.com:8243/SMRTLink/1.0.0/secondary-analysis/datastore-files/d1c8ae91-055b-494d-9016-7a51d47da5b7/download -O ts.tgz

Now, Manually upload

mkocher@login14-biofx01:~$ tech-support-uploader ts.tgz --url "https://smrtlink-eve-staging.pacbcloud.com:8083" 
Create System Event 31464fe9-e7e2-4ee1-b320-b3eb4328c598
Successfully completed running tech_support_uploader 0.1.0 (smrtflow 0.11.1+21036.d127d87) in 2 sec.

To be clear, if the TS tgz file is manually emailed to TS, you should import them manually using the tech-support-uploader internally. This makes the TS tgz bundle indistinguishable from a TS tgz bundle that was imported into Eve from SL and all results should show up in elasticsearch.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment