Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error when installing GUI-domain on Qubes 4.2 #8285

Closed
Morribyte opened this issue Jun 21, 2023 · 2 comments · Fixed by QubesOS/qubes-salt#2
Closed

Error when installing GUI-domain on Qubes 4.2 #8285

Morribyte opened this issue Jun 21, 2023 · 2 comments · Fixed by QubesOS/qubes-salt#2
Labels
affects-4.2 This issue affects Qubes OS 4.2. C: gui-domain diagnosed Technical diagnosis has been performed (see issue comments). P: default Priority: default. Default priority for new issues, to be replaced given sufficient information. pr submitted A pull request has been submitted for this issue. r4.1-fc37-stable r4.2-host-stable r4.2-vm-fc37-stable T: bug Type: bug report. A problem or defect resulting in unintended behavior in something that exists.
Milestone

Comments

@Morribyte
Copy link

Morribyte commented Jun 21, 2023

Hello everyone, this is my first report for Qubes so if I miss out on some key information, please do let me know and I'll do my best to fix it. I am also unsure if this is a bug report or user error, so I opted to put it into the bug reports just in case. Thanks for the help.

Qubes Release: 4.2 rc 1

Brief summary:

I want to have a GUI domain for enhanced isolation. I installed 4.2 and tried to enable the gui domain by running through all of the commands in the documentation as laid out for the hybrid GUI section but it errors out and says "Dom0 configuration failed, not continuing" along with an error log that is provided below.

I have ran through all of the troubleshooting I could find, including from #8154 : making sure that Fedora-37 was set as my default-mgmt-dvm as well as ensuring it was up to date.. Nothing fixes it.

I also double-checked the versions of salt packages on Fedora-37 and it shows a version greater than in the page linked on #8152 (#3472 in Qubes-OS's repository)

Steps to reproduce:

  1. Install Qubes 4.2 from USB drive with all default settings
  2. When getting into Qubes, run updater
  3. After updates, open Qubes Global Settings and enable all testing updates as well as community templates, official testing templates, and community testing templates
  4. Install Fedora-37 via qvm-template install command
  5. Restart PC and then update Fedora-37
  6. Go into Qubes Template Switcher and change default-mgmt-dvm to Fedora-37 as quoted here [Issue installing GUI domain #8154 ]
  7. Restart PC again just because I'm paranoid and want to make sure everything is good to go
  8. Open up a terminal in dom0
  9. Follow instructions for setting up sys-gui under the hybrid GUI (sys-gui) setup header as per the official documentation https://www.qubes-os.org/doc/gui-domain/
  10. Wait for the output after the third command (sudo qubesctl --all state.highstate)
  11. Fedora-37-xfce installs as expected, starts up, shuts down
  12. Command fails with the log shown in the actual behavior section
  13. Updated Fedora-37-xfce in case it was an outdated package problem
  14. Ran sudo qubesctl --all state.highstate again after updating, resulted in same error as outlined in Actual behavior

Expected behavior:

The process completes without any errors, resulting in a log that, at the end, reads as follows:

Summary for local
------------
Succeeded: 8
Failed:    0
------------

Actual behavior:

The process completes with 2 errors, resulting in an error log that reads as follows:

[qubes-user@dom0 ~]$ sudo qubesctl --all state.highstate
/usr/lib/python3.11/site-packages/_distutils_hack/__init__.py:33: UserWarning: Setuptools is replacing distutils.
  warnings.warn("Setuptools is replacing distutils.")
/usr/lib/python3.11/site-packages/_distutils_hack/__init__.py:33: UserWarning: Setuptools is replacing distutils.
  warnings.warn("Setuptools is replacing distutils.")
[ERROR   ] An exception occurred in this state: Traceback (most recent call last):
  File "/usr/lib/python3.11/site-packages/salt/state.py", line 2276, in call
    ret = self.states[cdata["full"]](
          ^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/salt/loader/lazy.py", line 149, in __call__
    return self.loader.run(run_func, *args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/salt/loader/lazy.py", line 1228, in run
    return self._last_context.run(self._run_as, _func_or_method, *args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/salt/loader/lazy.py", line 1243, in _run_as
    return _func_or_method(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/salt/loader/lazy.py", line 1276, in wrapper
    return f(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/salt/states/file.py", line 6431, in append
    if __salt__["file.search"](
       ^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/salt/loader/lazy.py", line 149, in __call__
    return self.loader.run(run_func, *args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/salt/loader/lazy.py", line 1228, in run
    return self._last_context.run(self._run_as, _func_or_method, *args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/salt/loader/lazy.py", line 1243, in _run_as
    return _func_or_method(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/salt/modules/file.py", line 3141, in search
    return replace(
           ^^^^^^^^
  File "/usr/lib/python3.11/site-packages/salt/modules/file.py", line 2516, in replace
    flags_num = _get_flags(flags)
                ^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/salt/modules/file.py", line 1643, in _get_flags
    _flag = getattr(re, str(flag).upper())
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
AttributeError: module 're' has no attribute 'RE.MULTILINE'

[ERROR   ] An exception occurred in this state: Traceback (most recent call last):
  File "/usr/lib/python3.11/site-packages/salt/state.py", line 2276, in call
    ret = self.states[cdata["full"]](
          ^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/salt/loader/lazy.py", line 149, in __call__
    return self.loader.run(run_func, *args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/salt/loader/lazy.py", line 1228, in run
    return self._last_context.run(self._run_as, _func_or_method, *args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/salt/loader/lazy.py", line 1243, in _run_as
    return _func_or_method(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/salt/loader/lazy.py", line 1276, in wrapper
    return f(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/salt/states/file.py", line 6431, in append
    if __salt__["file.search"](
       ^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/salt/loader/lazy.py", line 149, in __call__
    return self.loader.run(run_func, *args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/salt/loader/lazy.py", line 1228, in run
    return self._last_context.run(self._run_as, _func_or_method, *args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/salt/loader/lazy.py", line 1243, in _run_as
    return _func_or_method(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/salt/modules/file.py", line 3141, in search
    return replace(
           ^^^^^^^^
  File "/usr/lib/python3.11/site-packages/salt/modules/file.py", line 2516, in replace
    flags_num = _get_flags(flags)
                ^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.11/site-packages/salt/modules/file.py", line 1643, in _get_flags
    _flag = getattr(re, str(flag).upper())
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
AttributeError: module 're' has no attribute 'RE.MULTILINE'

local:
----------
          ID: fedora-37-xfce
    Function: qvm.template_installed
      Result: True
     Comment: Template fedora-37-xfce version 4.2.0 already installed
     Started: 09:26:11.731892
    Duration: 285.706 ms
     Changes:   
----------
          ID: dummy-psu-sender
    Function: pkg.installed
      Result: True
     Comment: All specified packages are already installed
     Started: 09:26:13.046397
    Duration: 411.643 ms
     Changes:   
----------
          ID: dummy-backlight-dom0
    Function: pkg.installed
      Result: True
     Comment: All specified packages are already installed
     Started: 09:26:13.458157
    Duration: 15.386 ms
     Changes:   
----------
          ID: /usr/share/xsessions/sys-gui.desktop
    Function: file.managed
      Result: True
     Comment: File /usr/share/xsessions/sys-gui.desktop is in the correct state
     Started: 09:26:13.475125
    Duration: 35.21 ms
     Changes:   
----------
          ID: sys-gui
    Function: qvm.exists
      Result: True
     Comment: /usr/bin/qvm-check sys-gui None
     Started: 09:26:13.510425
    Duration: 241.39 ms
     Changes:   
----------
          ID: sys-gui-rpc
    Function: file.managed
        Name: /etc/qubes/policy.d/50-gui-sys-gui.policy
      Result: True
     Comment: File /etc/qubes/policy.d/50-gui-sys-gui.policy is in the correct state
     Started: 09:26:13.752448
    Duration: 3.433 ms
     Changes:   
----------
          ID: sys-gui-admin-local-rwx
    Function: file.append
        Name: /etc/qubes/policy.d/include/admin-local-rwx
      Result: False
     Comment: An exception occurred in this state: Traceback (most recent call last):
                File "/usr/lib/python3.11/site-packages/salt/state.py", line 2276, in call
                  ret = self.states[cdata["full"]](
                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^
                File "/usr/lib/python3.11/site-packages/salt/loader/lazy.py", line 149, in __call__
                  return self.loader.run(run_func, *args, **kwargs)
                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
                File "/usr/lib/python3.11/site-packages/salt/loader/lazy.py", line 1228, in run
                  return self._last_context.run(self._run_as, _func_or_method, *args, **kwargs)
                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
                File "/usr/lib/python3.11/site-packages/salt/loader/lazy.py", line 1243, in _run_as
                  return _func_or_method(*args, **kwargs)
                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
                File "/usr/lib/python3.11/site-packages/salt/loader/lazy.py", line 1276, in wrapper
                  return f(*args, **kwargs)
                         ^^^^^^^^^^^^^^^^^^
                File "/usr/lib/python3.11/site-packages/salt/states/file.py", line 6431, in append
                  if __salt__["file.search"](
                     ^^^^^^^^^^^^^^^^^^^^^^^^
                File "/usr/lib/python3.11/site-packages/salt/loader/lazy.py", line 149, in __call__
                  return self.loader.run(run_func, *args, **kwargs)
                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
                File "/usr/lib/python3.11/site-packages/salt/loader/lazy.py", line 1228, in run
                  return self._last_context.run(self._run_as, _func_or_method, *args, **kwargs)
                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
                File "/usr/lib/python3.11/site-packages/salt/loader/lazy.py", line 1243, in _run_as
                  return _func_or_method(*args, **kwargs)
                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
                File "/usr/lib/python3.11/site-packages/salt/modules/file.py", line 3141, in search
                  return replace(
                         ^^^^^^^^
                File "/usr/lib/python3.11/site-packages/salt/modules/file.py", line 2516, in replace
                  flags_num = _get_flags(flags)
                              ^^^^^^^^^^^^^^^^^
                File "/usr/lib/python3.11/site-packages/salt/modules/file.py", line 1643, in _get_flags
                  _flag = getattr(re, str(flag).upper())
                          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
              AttributeError: module 're' has no attribute 'RE.MULTILINE'
     Started: 09:26:13.756003
    Duration: 10.277 ms
     Changes:   
----------
          ID: sys-gui-admin-global-rwx
    Function: file.append
        Name: /etc/qubes/policy.d/include/admin-global-rwx
      Result: False
     Comment: An exception occurred in this state: Traceback (most recent call last):
                File "/usr/lib/python3.11/site-packages/salt/state.py", line 2276, in call
                  ret = self.states[cdata["full"]](
                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^
                File "/usr/lib/python3.11/site-packages/salt/loader/lazy.py", line 149, in __call__
                  return self.loader.run(run_func, *args, **kwargs)
                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
                File "/usr/lib/python3.11/site-packages/salt/loader/lazy.py", line 1228, in run
                  return self._last_context.run(self._run_as, _func_or_method, *args, **kwargs)
                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
                File "/usr/lib/python3.11/site-packages/salt/loader/lazy.py", line 1243, in _run_as
                  return _func_or_method(*args, **kwargs)
                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
                File "/usr/lib/python3.11/site-packages/salt/loader/lazy.py", line 1276, in wrapper
                  return f(*args, **kwargs)
                         ^^^^^^^^^^^^^^^^^^
                File "/usr/lib/python3.11/site-packages/salt/states/file.py", line 6431, in append
                  if __salt__["file.search"](
                     ^^^^^^^^^^^^^^^^^^^^^^^^
                File "/usr/lib/python3.11/site-packages/salt/loader/lazy.py", line 149, in __call__
                  return self.loader.run(run_func, *args, **kwargs)
                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
                File "/usr/lib/python3.11/site-packages/salt/loader/lazy.py", line 1228, in run
                  return self._last_context.run(self._run_as, _func_or_method, *args, **kwargs)
                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
                File "/usr/lib/python3.11/site-packages/salt/loader/lazy.py", line 1243, in _run_as
                  return _func_or_method(*args, **kwargs)
                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
                File "/usr/lib/python3.11/site-packages/salt/modules/file.py", line 3141, in search
                  return replace(
                         ^^^^^^^^
                File "/usr/lib/python3.11/site-packages/salt/modules/file.py", line 2516, in replace
                  flags_num = _get_flags(flags)
                              ^^^^^^^^^^^^^^^^^
                File "/usr/lib/python3.11/site-packages/salt/modules/file.py", line 1643, in _get_flags
                  _flag = getattr(re, str(flag).upper())
                          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
              AttributeError: module 're' has no attribute 'RE.MULTILINE'
     Started: 09:26:13.766440
    Duration: 1.677 ms
     Changes:   

Summary for local
------------
Succeeded: 6
Failed:    2
------------
Total states run:     8
Total run time:   1.005 s
@Morribyte Morribyte added P: default Priority: default. Default priority for new issues, to be replaced given sufficient information. T: bug Type: bug report. A problem or defect resulting in unintended behavior in something that exists. labels Jun 21, 2023
@andrewdavidwong andrewdavidwong added C: gui-domain needs diagnosis Requires technical diagnosis from developer. Replace with "diagnosed" or remove if otherwise closed. labels Jun 21, 2023
@andrewdavidwong andrewdavidwong added this to the Release 4.2 milestone Jun 21, 2023
@andrewdavidwong andrewdavidwong added diagnosed Technical diagnosis has been performed (see issue comments). pr submitted A pull request has been submitted for this issue. and removed needs diagnosis Requires technical diagnosis from developer. Replace with "diagnosed" or remove if otherwise closed. labels Jun 23, 2023
@qubesos-bot
Copy link

Automated announcement from builder-github

The component salt (including package salt) has been pushed to the r4.2 testing repository for the Fedora template.
To test this update, please install it with the following command:

sudo dnf update --enablerepo=qubes-vm-r4.2-current-testing

Changes included in this update

@qubesos-bot
Copy link

Automated announcement from builder-github

The component salt (including package salt) has been pushed to the r4.2 stable repository for the Fedora template.
To install this update, please use the standard update command:

sudo dnf update

Changes included in this update

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
affects-4.2 This issue affects Qubes OS 4.2. C: gui-domain diagnosed Technical diagnosis has been performed (see issue comments). P: default Priority: default. Default priority for new issues, to be replaced given sufficient information. pr submitted A pull request has been submitted for this issue. r4.1-fc37-stable r4.2-host-stable r4.2-vm-fc37-stable T: bug Type: bug report. A problem or defect resulting in unintended behavior in something that exists.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants