From f7e92bebae02b3f263a17e8565a502cfd13658b5 Mon Sep 17 00:00:00 2001 From: Franco Fichtner Date: Tue, 25 Apr 2017 18:24:07 +0200 Subject: [PATCH] system: crash report, sometimes even Etc/UTC is gone In those cases the next firmware update with a base set helps, or running this manually: # opnsense-update -fb --- src/etc/inc/system.inc | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/etc/inc/system.inc b/src/etc/inc/system.inc index 50ce75297..42ce2658e 100644 --- a/src/etc/inc/system.inc +++ b/src/etc/inc/system.inc @@ -1380,7 +1380,9 @@ function system_timezone_configure($verbose = false) } /* apply timezone */ - copy(sprintf('/usr/share/zoneinfo/%s', $timezone), '/etc/localtime'); + if (file_exists(sprintf('/usr/share/zoneinfo/%s', $timezone))) { + copy(sprintf('/usr/share/zoneinfo/%s', $timezone), '/etc/localtime'); + } if ($verbose) { echo "done.\n";