waiting for this script so long, thx verymuch, but i found a small bug, if you don't put an empty ReaddIdTable file in \etc, it will cause error... maybe need to add a line in your script to check the file is there.
Code:
if { ! [file exists etc/ReaddIdTable] } { set newid [open etc/ReaddIdTable a] ; close $newid }