RPM_FILE=/path/to/file.rpm # View scripts rpm -qp --scripts $RPM_FILE # List files in rpm rpm -qlp $RPM_FILE # Extract files from RPM rpm2cpio .$RPM_FILE | cpio -idmv ./file/to/extract