Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 13 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -184,6 +184,19 @@ For a quick fix the below command will install the latest keyrings

```pacman -Sy archlinux-keyring```

## GPG verification errors pacstrap

This can occur if the **timezone selected** is incorrect and/or hardware clock in motherboard settings is not accurate (fails during verification of packages at first base-strap). Ie. when CMOS battery is dead and power cut-off happens this can reset other settings such as Clock, Sata Mode, Fast Boot, etc...

For **offline installs** can set manually via:

```
timedatectl status
timedatectl set-time "YYYY-MM-DD HH:MM:SS"
```

Or in motherboard settings directly ! If you have internet and picked your timezone properly in the menu, NTP handles this by default.

## How to dual boot with Windows

To install Arch Linux alongside an existing Windows installation using `archinstall`, follow these steps:
Expand Down
4 changes: 2 additions & 2 deletions archinstall/lib/args.py
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ class ArchConfig:
packages: list[str] = field(default_factory=list)
parallel_downloads: int = 0
swap: bool = True
timezone: str = 'UTC'
timezone: str | None = None
services: list[str] = field(default_factory=list)
custom_commands: list[str] = field(default_factory=list)

Expand Down Expand Up @@ -213,7 +213,7 @@ def from_config(cls, args_config: dict[str, Any], args: Arguments) -> 'ArchConfi

arch_config.swap = args_config.get('swap', True)

if timezone := args_config.get('timezone', 'UTC'):
if timezone := args_config.get('timezone', None):
arch_config.timezone = timezone

if services := args_config.get('services', []):
Expand Down
10 changes: 8 additions & 2 deletions archinstall/lib/global_menu.py
Original file line number Diff line number Diff line change
Expand Up @@ -150,9 +150,10 @@ def _get_menu_options(self) -> list[MenuItem]:
MenuItem(
text=tr('Timezone'),
action=ask_for_a_timezone,
value='UTC',
value=None,
preview_action=self._prev_tz,
key='timezone',
mandatory=True,
),
MenuItem(
text=tr('Automatic time sync (NTP)'),
Expand Down Expand Up @@ -330,7 +331,12 @@ def _prev_applications(self, item: MenuItem) -> str | None:

def _prev_tz(self, item: MenuItem) -> str | None:
if item.value:
return f'{tr("Timezone")}: {item.value}'
output = f'{tr("Timezone")}: {item.value}'
return output
else:
# Show RTC time when no timezone is selected yet
if rtc_time := SysInfo.hw_clock():
return f'RTC time: {rtc_time}'
return None

def _prev_ntp(self, item: MenuItem) -> str | None:
Expand Down
11 changes: 11 additions & 0 deletions archinstall/lib/hardware.py
Original file line number Diff line number Diff line change
Expand Up @@ -143,6 +143,13 @@ class _SysInfo:
def __init__(self) -> None:
pass

def hw_clock(self) -> str:
"""
Returns the RTC (hardware clock) time from timedatectl
"""
time = SysCommand('timedatectl show --property=RTCTimeUSec --value').decode().strip()
return time

@cached_property
def cpu_info(self) -> dict[str, str]:
"""
Expand Down Expand Up @@ -207,6 +214,10 @@ def has_wifi() -> bool:
def has_uefi() -> bool:
return os.path.isdir('/sys/firmware/efi')

@staticmethod
def hw_clock() -> str:
return _sys_info.hw_clock()

@staticmethod
def _graphics_devices() -> dict[str, str]:
cards: dict[str, str] = {}
Expand Down