use DB_File; tie my %hash, "DB_File", "file.db", O_RDWR|O_CREAT, 0666; # now use hash as normal