tie %cfg, 'Config::IniFiles', ( -file => $CFG_FILE); $cfg{$section} = "new section name"; tied( %cfg )->WriteConfig($CFG_FILE) or die "Error";