unofficial mirror of help-guix@gnu.org 
 help / color / mirror / Atom feed
From: coralgoat--- via <help-guix@gnu.org>
To: SeerLite <seerlite@nixnet.email>
Cc: Help Guix <help-guix@gnu.org>
Subject: Re: Stuck at scheme prompt when booting
Date: Tue, 15 Feb 2022 21:46:15 +0100 (CET)	[thread overview]
Message-ID: <Mvz7fvQ--3-2@tuta.io> (raw)
In-Reply-To: <ffa3b5bd-4c01-9523-b955-a75aafa1fadf@nixnet.email>

Thank you for letting me know Guix uses cryptsetup for drive encryption.

I booted the Guix install ISO then I did this:
decrypted the drive
mounted the drive at /mnt/guix
ran `chattr -i mnt/guix/etc/resolv.conf`
rebooted the system
Now I am able to boot successfully.

Feb 12, 2022, 23:11 by seerlite@nixnet.email:

> On 2/12/22 15:15, coralgoat--- via wrote:
>
>> I could try booting an operating system in memory and then use a disk
>> encryption program to decrypt the hard drive with my passphrase and
>> then run `chattr -i /etc/resolv.conf`.  What disk encryption program
>> should I use to decrypt the hard disk?
>>
>
> Guix uses dm-crypt so you should be able to use the cryptsetup tool available in most distributions by default:
>
>  cryptsetup open /dev/sda2 guix
>
> The above command creates decrypted representation of the /dev/sda2 partition at /dev/mapper/guix. You can mount this file like any other partition. This should be enough to access the contents of the system in case the boot process completely breaks.
>
> However in this case Ricardo's advice may be enough to get it to work from within Guix itself. I explained the above for future reference or in case it doesn't work.
>
>> I resolved the domain name resolution errors by doing 2
>> things:
>> 1) editing /etc/resolv.conf changing it to a single line that set a
>>  specific nameserver
>> 2) I ran this command `chattr +i /etc/resolv.conf`
>>
>
> If you want to avoid getting /etc/resolv.conf modified, instead of adding the immutable attribute to the file (AKA changing the "state" of the file) you should configure the responsible service so it doesn't modify it in the first place.
> This is especially important in a declarative system like Guix, where the operating-system and its services should function no matter the *state* of the files in it. Almost every system-level setting can be configured with Guix's configuration system. And using it prevents broken configurations like these from making the system completely unbootable, as you would be able to boot to a previous generation from the boot menu.
>
> I'm assuming you're using a configuration based on the official example, so the service that modifies this file should be NetworkManager coming from %desktop-services. To disable its modification to /etc/resolv.conf you can set the `dns` field to "none" in its `network-manager-configuration`. You can modify it by using `modify-services` on %desktop-services.
>
> See these manual pages for the usage of modify-services and also documentation of network-manager-configuration:
> * https://guix.gnu.org/manual/en/html_node/Service-Reference.html
> * https://guix.gnu.org/manual/en/html_node/Networking-Services.html
>
>
> SeerLite
>


      reply	other threads:[~2022-02-15 20:46 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-02-09 16:00 Stuck at scheme prompt when booting coralgoat--- via
     [not found] ` <MvUCoKH--7-2@tuta.io-MveXQCV----2>
2022-02-12 19:15   ` coralgoat--- via
2022-02-12 22:08     ` Ricardo Wurmus
2022-02-15 20:38       ` coralgoat--- via
2022-02-15 20:51         ` Ricardo Wurmus
2022-02-15 21:53           ` coralgoat--- via
2022-02-12 23:11     ` SeerLite
2022-02-15 20:46       ` coralgoat--- via [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://guix.gnu.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=Mvz7fvQ--3-2@tuta.io \
    --to=help-guix@gnu.org \
    --cc=coralgoat@tuta.io \
    --cc=seerlite@nixnet.email \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).