I had run in to a situation where my Satellite had several hundred-thousand previously run scheduled jobs sitting in the history... I could delete them 25 at a time... and if I did "Select All" it would puke. So - I created the following #!/usr/bin/env python import xmlrpclib import time SATELLITE_URL = "http://rhnsat01.company.com/rpc/api" SATELLITE_LOGIN = "satadmin" SATELLITE_PASSWORD = "notMyPassword" client = xmlrpclib.Server(SATELLITE_URL, verbose=0) delete = 1 key = client.auth.login(SATELLITE_LOGIN, SATELLITE_PASSWORD) ############################### # CHANGE THINGS AFTER THIS LINE # ## Delete all Failed Actions x = "Deleting all Failed Actions" print(x) failed_list = client.schedule.listFailedActions(key) action_ids=[] for action in failed_list: action_ids.append(action['id']) archive_result=client.schedule.archiveActions(key,action_ids) ## Archive all Completed Actions ## Generate a...
Linux: The whole world made it for you... This blog is a collection of things I come across either at home or at work as a Linux Administrator. I have worked as an Admin working with Solaris, SAN, Backups and Linux at the Enterprise level for over 16 years.