more flexible timeout in upgrade.mas