removing file by inode

Arne Ludwig arne at citde.net
Thu Mar 23 10:46:41 EST 2006


Good answer. :)  I seriously doubt it is possible except for the
trivial solution:

def remove_a_file(inode):
     os.system ("find / -inum %d | xargs rm -f" % (inode))

PS. Don't blame me if this function destroys your hard disk. I wrote it
off the top of my head.




More information about the Python-list mailing list