The record US government shutdown is close to ending as moderate Senate Democrats back a deal to reopen agencies and fund key departments for a year. The bill restores pay for furloughed workers and withheld payments to states. A Senate vote is planned Sunday, though House approval remains uncertain amid disputes over Obamacare subsidies and funding duration.