You might have experienced on this bug, if you have configured installation server and yum server in the same machine with the same path (i.e., /var/ftp/pub).
Let us discuss the scenario in detail to solve this out.
1. Create / for 10GB, so you can create yum server by using ftp service with the default path specified /var/ftp/pub.
2. Copy all rpm content from DVD/CDs to some other path /rhel5/rpms (say).
3. Configure nfs server for the specified path /rhel5/rpms
4. Restart the specified services.
5. Use /var/ftp/pub path whenever yum server needs to be used.
6. Use /rhel5/rpms path whenever installation server is required.
Note: It is obvious that the pure replica of all rpms is indespensable in this case to solve this python bug in round about way. There is no alternate solution to fix this up.