For update, try 'yum clean all; yum update -y'.
If trouble in yum process, maybe something wrong with yum database. So, try:
'rm' -f /var/lib/rpm/__db*
rpm --rebuilddb
package-cleanup --cleandupes
package-cleanup --problems
yum clean all
yum update -y
If update successfull, run 'sh /script/cleanup'.