I want to set up a script that automatically changes the timezone on a machine (running Ubuntu 11.10 (Oneiric Ocelot)) and also sets the right values to the debconf database. I've tried the following, but it does not work (at the end, the current timezone remains unchanged, and if I manually run the dpkg-reconfigure tzdata command, the selected values are indeed the old ones): #!/bin/sh -e echo "tzdata tzdata/Areas select Europe" |...
Originally asked by Carlos Campderrós on Stack Exchange (superuser) (CC BY-SA 4.0).