Select Your Language

Infrastructure and Management

Cloud Computing

Storage

Runtimes

Integration and Automation

  • Comments
  • Satellite: How a stuck task can be removed. Always open a support case. (solution)

    Posted on

    On my home lab RH Satellite 6 I had a minor issue at first, Kickstart 7.6 stopped to sync.

    This week I decided to drop RHEL 7.6 content, and now the sync issue became a major issue. The task to remove the repository failed due to the old locks.

    I opened a support case and recorded the commands performed by the Red Hat Engineer Amar, Huchchanavar who solved the issue.

    to avoid support issues: open a support ticket, and ask whether the actions below are save to perform.

    At the WebUI
    Set

    dynflow_allow_dangerous_actions
    to
    Yes
    (only during the fixing session)

    On the CLI

    hammer  ping
    
    sudo su - postgres -c "psql -d foreman -c 'select label,count(label),state,result from foreman_tasks_tasks where state > '\''stopped'\'' group by label,state,result ORDER BY label;'"
    
    foreman-maintain service status
    
    foreman-maintain service stop
    
    foreman-maintain service start
    
    sudo su - postgres -c "psql -d foreman -c 'select label,count(label),state,result from foreman_tasks_tasks where state > '\''stopped'\'' group by label,state,result ORDER BY label;'"
    
    foreman-rake foreman_tasks:cleanup TASK_SEARCH='result == pending' STATES='stopped' VERBOSE=true NOOP=true
    
    foreman-rake foreman_tasks:cleanup TASK_SEARCH='result == pending' STATES='stopped' VERBOSE=true
    
    katello-service  restart
    
    hammer ping
    

    At the WebUI
    Return the value of

    dynflow_allow_dangerous_actions
    back to
    No

    RJ Hinton has a great addition to avoid other issues

    • reposyncs do not have download-policy immediate set:
      'YOUR_VALID_ORG_GOES_HERE' is a fake label to make it generic, which you have to change to make it work for your situation.

    hammer repository list --organization-label='YOUR_VALID_ORG_GOES_HERE'|\ awk '{print $1}' | egrep -v '\||ID' | \ less | \ perl -ne 'print;chomp;system("hammer repository update --download-policy immediate --id $_")'
    *Errors to ignore:*
    Could not update the repository:
    Validation failed: Download policy Cannot set attribute download_policy 
    

    for content type file

    • The task history is too long
      foreman-rake foreman_tasks:cleanup TASK_SEARCH='label ~ *' AFTER='100s' VERBOSE=true

    by

    points

    Responses

    Red Hat

    Quick Links

    Help

    Site Info

    Related Sites

    © 2025 Red Hat, Inc.